private long getRetryCountLimit() { HazelcastProperties hazelcastProperties = client.getProperties(); int waitTime = hazelcastProperties.getSeconds(INVOCATION_TIMEOUT_SECONDS); long retryTimeoutInSeconds = waitTime > 0 ? waitTime : Integer.parseInt(INVOCATION_TIMEOUT_SECONDS.getDefaultValue()); return retryTimeoutInSeconds / ClientInvocation.RETRY_WAIT_TIME_IN_SECONDS; }
protected ClientInvocation( HazelcastClientInstanceImpl client, ClientMessage clientMessage, int partitionId, Address address, Connection connection) { this.lifecycleService = client.getLifecycleService(); this.invocationService = client.getInvocationService(); this.executionService = client.getClientExecutionService(); this.clientMessage = clientMessage; this.partitionId = partitionId; this.address = address; this.connection = connection; HazelcastProperties hazelcastProperties = client.getProperties(); long waitTime = hazelcastProperties.getMillis(INVOCATION_TIMEOUT_SECONDS); long waitTimeResolved = waitTime > 0 ? waitTime : Integer.parseInt(INVOCATION_TIMEOUT_SECONDS.getDefaultValue()); retryTimeoutPointInMillis = System.currentTimeMillis() + waitTimeResolved; logger = ((ClientInvocationServiceSupport) invocationService).invocationLogger; clientInvocationFuture = new ClientInvocationFuture(this, client, clientMessage, logger); }