Skip to content

Commit c0b78c7

Browse files
committed
updated T calculation
1 parent 3a3ee8e commit c0b78c7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/bigchaindb/builders/BigchainDbConfigBuilder.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ public void processConnectionFailure(Connection nodeToConnect) {
268268
//calculate time to retry for new connection
269269
long timeToRetryConnection = BigChainDBGlobals.DELAY * (long) Math.pow(2, conn.getRetryCount());
270270
//set whichever is smaller (this makes sure that timeToRetryConnection is always smaller than half of timeout
271-
long timeToRetryCap = BigChainDBGlobals.calculateTimeTillTimeout()/2;
271+
long timeToRetryCap = BigChainDBGlobals.getTimeout()/2;
272272
timeToRetryConnection = timeToRetryConnection < timeToRetryCap ? timeToRetryConnection : timeToRetryCap;
273273

274274
conn.setTimeToRetryForConnection(System.currentTimeMillis() + timeToRetryConnection);

0 commit comments

Comments
 (0)