/[projects]/CircuitBreaker/src/dk/thoerup/circuitbreaker/CircuitBreaker.java
ViewVC logotype

Diff of /CircuitBreaker/src/dk/thoerup/circuitbreaker/CircuitBreaker.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1160 by torben, Fri Oct 1 11:40:30 2010 UTC revision 1161 by torben, Mon Oct 4 17:36:43 2010 UTC
# Line 106  public class CircuitBreaker{ Line 106  public class CircuitBreaker{
106                          open.trip();                          open.trip();
107                          currentState = open;                          currentState = open;
108                                    
109                          notifier.sendNotification(name, event);                          notifier.sendNotification(this, event);
110                  }                  }
111          }                }      
112      }      }
# Line 115  public class CircuitBreaker{ Line 115  public class CircuitBreaker{
115          synchronized(this) {          synchronized(this) {
116                  if (currentState != halfOpen) { // TODO:Is this conditional necessary ??                  if (currentState != halfOpen) { // TODO:Is this conditional necessary ??
117                          currentState = halfOpen;                          currentState = halfOpen;
118                          notifier.sendNotification(name, Notifier.Event.BreakerAttemptReset);                          notifier.sendNotification(this, Notifier.Event.BreakerAttemptReset);
119                  }                  }
120          }          }
121                    
# Line 125  public class CircuitBreaker{ Line 125  public class CircuitBreaker{
125          synchronized(this) {          synchronized(this) {
126                  if (currentState != closed) { // TODO: Is this conditional necessary ??                  if (currentState != closed) { // TODO: Is this conditional necessary ??
127                          internalReset();                          internalReset();
128                          notifier.sendNotification(name, Notifier.Event.BreakerReset);                          notifier.sendNotification(this, Notifier.Event.BreakerReset);
129                  }                  }
130          }          }
131      }      }

Legend:
Removed from v.1160  
changed lines
  Added in v.1161

  ViewVC Help
Powered by ViewVC 1.1.20