brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From neykov <...@git.apache.org>
Subject [GitHub] incubator-brooklyn pull request: Riak uses ulimit configuration re...
Date Mon, 15 Jun 2015 21:17:26 GMT
Github user neykov commented on a diff in the pull request:

    https://github.com/apache/incubator-brooklyn/pull/691#discussion_r32467955
  
    --- Diff: software/nosql/src/main/java/brooklyn/entity/nosql/riak/RiakNodeSshDriver.java
---
    @@ -594,4 +595,16 @@ private void addRiakOnPath(ScriptHelper scriptHelper) {
     //        log.warn("riak command not found on PATH. Altering future commands' environment
variables from {} to {}", getShellEnvironment(), newPathVariable);
             scriptHelper.environmentVariablesReset(newPathVariable);
         }
    +
    +    @Override
    +    public Integer getNumberOfOpenFiles() {
    +        Integer defaultNumberOfFiles = RiakNode.RIAK_NUM_OPEN_FILES.getConfigKey().getDefaultValue();
    +        Integer numberOfFiles = entity.getConfig(RiakNode.RIAK_NUM_OPEN_FILES);
    +        if (numberOfFiles.compareTo(defaultNumberOfFiles) < 0) {
    +            log.warn("Specified number of open files : {} : less than the required minimum.
Using defaults : {}.", numberOfFiles, defaultNumberOfFiles);
    +            entity.setAttribute(RiakNode.RIAK_NUM_OPEN_FILES, defaultNumberOfFiles);
    --- End diff --
    
    Warning the user is a good idea, but I think it's surprising if the value he sets is not
applied. He must have a good reason to change the default value.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message