Skip to content
Permalink
Browse files
rename property
  • Loading branch information
eolivelli committed Jun 24, 2018
1 parent aec1347 commit 633db98c4f0b35f532dbee4f16575449ced9f2cb
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
@@ -52,7 +52,7 @@ public class CuratorZookeeperClient implements Closeable
private final ConnectionState state;
private final AtomicReference<RetryPolicy> retryPolicy = new AtomicReference<RetryPolicy>();
private final int connectionTimeoutMs;
private final int defaultWaitForShutdownTimeoutMs;
private final int waitForShutdownTimeoutMs;
private final AtomicBoolean started = new AtomicBoolean(false);
private final AtomicReference<TracerDriver> tracer = new AtomicReference<TracerDriver>(new DefaultTracerDriver());
private final ConnectionHandlingPolicy connectionHandlingPolicy;
@@ -146,7 +146,7 @@ public CuratorZookeeperClient(ZookeeperFactory zookeeperFactory, EnsembleProvide
ensembleProvider = Preconditions.checkNotNull(ensembleProvider, "ensembleProvider cannot be null");

this.connectionTimeoutMs = connectionTimeoutMs;
this.defaultWaitForShutdownTimeoutMs = defaultWaitForShutdownTimeoutMs;
this.waitForShutdownTimeoutMs = defaultWaitForShutdownTimeoutMs;
state = new ConnectionState(zookeeperFactory, ensembleProvider, sessionTimeoutMs, connectionTimeoutMs, watcher, tracer, canBeReadOnly, connectionHandlingPolicy);
setRetryPolicy(retryPolicy);
}
@@ -240,13 +240,13 @@ public void start() throws Exception
/**
* Close the client.
*
* Same as {@link #close(int) } using the default timeout set at construction time.
* Same as {@link #close(int) } using the timeout set at construction time.
*
* @see #close(int)
*/
@Override
public void close() {
close(defaultWaitForShutdownTimeoutMs);
close(waitForShutdownTimeoutMs);
}

/**
@@ -148,7 +148,7 @@ public static byte[] getLocalAddress()
private ConnectionHandlingPolicy connectionHandlingPolicy = new StandardConnectionHandlingPolicy();
private SchemaSet schemaSet = SchemaSet.getDefaultSchemaSet();
private boolean zk34CompatibilityMode = isZK34();
private int defaultWaitForShutdownTimeoutMs = 0;
private int waitForShutdownTimeoutMs = 0;
/**
* Apply the current values and build a new CuratorFramework
*
@@ -412,7 +412,7 @@ public Builder zk34CompatibilityMode(boolean mode)
*/
public Builder defaultWaitForShutdownTimeoutMs(int defaultWaitForShutdownTimeoutMs)
{
this.defaultWaitForShutdownTimeoutMs = defaultWaitForShutdownTimeoutMs;
this.waitForShutdownTimeoutMs = defaultWaitForShutdownTimeoutMs;
return this;
}

@@ -509,9 +509,9 @@ public int getConnectionTimeoutMs()
return connectionTimeoutMs;
}

public int getDefaultWaitForShutdownTimeoutMs()
public int getWaitForShutdownTimeoutMs()
{
return defaultWaitForShutdownTimeoutMs;
return waitForShutdownTimeoutMs;
}

public int getMaxCloseWaitMs()
@@ -122,7 +122,7 @@ public CuratorFrameworkImpl(CuratorFrameworkFactory.Builder builder)
builder.getEnsembleProvider(),
builder.getSessionTimeoutMs(),
builder.getConnectionTimeoutMs(),
builder.getDefaultWaitForShutdownTimeoutMs(),
builder.getWaitForShutdownTimeoutMs(),
new Watcher()
{
@Override

0 comments on commit 633db98

Please sign in to comment.