Navigation Menu

Skip to content

Commit

Permalink
make it possible to determine if the symmetric engine is starting by …
Browse files Browse the repository at this point in the history
…exposing a starting property.
  • Loading branch information
knaas committed Mar 15, 2008
1 parent 69db60f commit 450e7c8
Showing 1 changed file with 14 additions and 1 deletion.
Expand Up @@ -76,6 +76,8 @@ public class SymmetricEngine {

private boolean started = false;

private boolean starting = false;

private IDbDialect dbDialect;

private Properties properties;
Expand Down Expand Up @@ -200,7 +202,8 @@ public String getEngineName() {
* Must be called to start symmetric.
*/
public synchronized void start() {
if (!started) {
if (!starting) {
starting = true;
bootstrapService.init();
Node node = nodeService.findIdentity();
if (node != null) {
Expand Down Expand Up @@ -310,6 +313,15 @@ public boolean isStarted() {
return started;
}

/**
* Check to see if this node is starting.
* @return true if the node is starting
*/

public boolean isStarting() {
return starting;
}

/**
* Expose access to the Spring context. This is for advanced use only.
* @return
Expand All @@ -331,4 +343,5 @@ public static SymmetricEngine findEngineByName(String name) {




}

0 comments on commit 450e7c8

Please sign in to comment.