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

    https://github.com/apache/brooklyn-server/pull/356#discussion_r80962988
  
    --- Diff: 
software/base/src/main/java/org/apache/brooklyn/entity/software/base/SoftwareProcessImpl.java
 ---
    @@ -440,12 +441,20 @@ public void rebind() {
             //Only if the expected state is ON_FIRE then the entity has 
permanently failed.
             Transition expectedState = getAttribute(SERVICE_STATE_EXPECTED);
             if (expectedState == null || expectedState.getState() != 
Lifecycle.RUNNING) {
    +            //FIXME does not set on fire root application
    +            if (expectedState.getState() == Lifecycle.STARTING || 
expectedState.getState() == Lifecycle.STOPPING) {
    +                setAttribute(SERVICE_STATE_EXPECTED, new 
Lifecycle.Transition(Lifecycle.ON_FIRE, new Date()));
    +                setAttribute(SERVICE_STATE_ACTUAL, Lifecycle.ON_FIRE);
    +            }
                 LOG.warn("On rebind of {}, not calling software process rebind 
hooks because expected state is {}", this, expectedState);
                 return;
             }
     
             Lifecycle actualState = getAttribute(SERVICE_STATE_ACTUAL);
             if (actualState == null || actualState != Lifecycle.RUNNING) {
    +            if (expectedState.getState() == Lifecycle.STARTING || 
expectedState.getState() == Lifecycle.STOPPING) {
    +                setAttribute(SERVICE_STATE_ACTUAL, Lifecycle.ON_FIRE);
    +            }
    --- End diff --
    
    This is fixed in a separate commit, so the comment will not show as 
outdated.


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to