Github user tbouron commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/819#discussion_r138584725
  
    --- Diff: 
core/src/main/java/org/apache/brooklyn/core/entity/BrooklynConfigKeys.java ---
    @@ -180,23 +194,59 @@
          * component is up, but this entity does not care about the dependent 
component's actual config values.
          */
     
    -    public static final ConfigKey<Boolean> PROVISION_LATCH = 
newBooleanConfigKey("provision.latch", "Latch for blocking location provision 
until ready");
    -    public static final ConfigKey<Boolean> START_LATCH = 
newBooleanConfigKey("start.latch", "Latch for blocking start until ready");
    +    public static final ConfigKey<Boolean> PROVISION_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("provision.latch")
    +            .description("Latch for blocking machine provisioning; if 
non-null will wait for this to resolve (normal use is with 
'$brooklyn:attributeWhenReady')")
    +            .build();
    +    public static final ConfigKey<Boolean> START_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("start.latch")
    +            .description("Latch for blocking start (done post-provisioning 
for software processes); if non-null will wait for this to resolve (normal use 
is with '$brooklyn:attributeWhenReady')")
    +            .build();
     
         @Beta // on stop DSLs time out after a minute and unblock; may be 
easier to fix after https://github.com/apache/brooklyn-server/pull/390
    -    public static final ConfigKey<Boolean> STOP_LATCH = 
newBooleanConfigKey("stop.latch", "Latch for blocking stop until a condition is 
met; will block for at most 1 minute and then time out");
    +    public static final ConfigKey<Boolean> STOP_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("stop.latch")
    +            .description("Latch for blocking stop; if non-null will wait 
for at most 1 minute for this to resolve (normal use is with 
'$brooklyn:attributeWhenReady')")
    +            .build();
     
    -    public static final ConfigKey<Boolean> SETUP_LATCH = 
newBooleanConfigKey("setup.latch", "Latch for blocking setup until ready");
    -    public static final ConfigKey<Boolean> PRE_INSTALL_RESOURCES_LATCH = 
newBooleanConfigKey("resources.preInstall.latch", "Latch for blocking 
pre-install resources until ready");
    -    public static final ConfigKey<Boolean> INSTALL_RESOURCES_LATCH = 
newBooleanConfigKey("resources.install.latch", "Latch for blocking install 
resources until ready");
    -    public static final ConfigKey<Boolean> INSTALL_LATCH = 
newBooleanConfigKey("install.latch", "Latch for blocking install until ready");
    -    public static final ConfigKey<Boolean> RUNTIME_RESOURCES_LATCH = 
newBooleanConfigKey("resources.runtime.latch", "Latch for blocking runtime 
resources until ready");
    -    public static final ConfigKey<Boolean> CUSTOMIZE_LATCH = 
newBooleanConfigKey("customize.latch", "Latch for blocking customize until 
ready");
    -    public static final ConfigKey<Boolean> CUSTOMIZE_RESOURCES_LATCH = 
newBooleanConfigKey("resources.customize.latch", "Latch for blocking customize 
resources until ready");
    -    public static final ConfigKey<Boolean> LAUNCH_LATCH = 
newBooleanConfigKey("launch.latch", "Latch for blocking launch until ready");
    +    public static final ConfigKey<Boolean> SETUP_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("setup.latch")
    +            .description("Latch for blocking setup; if non-null will wait 
for this to resolve (normal use is with '$brooklyn:attributeWhenReady')")
    +            .build();
    +    
    +    public static final ConfigKey<Boolean> PRE_INSTALL_RESOURCES_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("resources.preInstall.latch")
    +            .description("Latch for blocking files being copied before the 
pre-install; if non-null will wait for this to resolve (normal use is with 
'$brooklyn:attributeWhenReady')")
    +            .build();
    +    public static final ConfigKey<Boolean> INSTALL_RESOURCES_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("resources.install.latch")
    +            .description("Latch for blocking files being copied before the 
install; if non-null will wait for this to resolve (normal use is with 
'$brooklyn:attributeWhenReady')")
    +            .build();
    +    public static final ConfigKey<Boolean> INSTALL_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("install.latch")
    +            .description("Latch for blocking install; if non-null will 
wait for this to resolve (normal use is with '$brooklyn:attributeWhenReady')")
    +            .build();
    +    public static final ConfigKey<Boolean> CUSTOMIZE_RESOURCES_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("resources.customize.latch")
    +            .description("Latch for blocking files being copied before 
customize; if non-null will wait for this to resolve (normal use is with 
'$brooklyn:attributeWhenReady')")
    +            .build();
    +    public static final ConfigKey<Boolean> CUSTOMIZE_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("customize.latch")
    +            .description("Latch for blocking customize; if non-null will 
wait for this to resolve (normal use is with '$brooklyn:attributeWhenReady')")
    +            .build();
    +    public static final ConfigKey<Boolean> RUNTIME_RESOURCES_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("resources.runtime.latch")
    +            .description("Latch for blocking files being copied before the 
launch; if non-null will wait for this to resolve (normal use is with 
'$brooklyn:attributeWhenReady')")
    +            .build();
    +    public static final ConfigKey<Boolean> LAUNCH_LATCH = 
ConfigKeys.builder(Boolean.class)
    +            .name("launch.latch")
    +            .description("Latch for blocking luanch; if non-null will wait 
for this to resolve (normal use is with '$brooklyn:attributeWhenReady')")
    +            .build();
     
         public static final ConfigKey<Duration> START_TIMEOUT = newConfigKey(
    -            "start.timeout", "Time to wait for process and for SERVICE_UP 
before failing (in seconds, default 2m)", Duration.seconds(120));
    +            "start.timeout", 
    +            "Time to wait, after launching, for SERVICE_UP before failing 
(default to '2m')", 
    --- End diff --
    
    Not sure the default needs to be written in the description. Would be hard 
to maintain and the CLI / UI have access to this info anyway.


---

Reply via email to