private void validateBuilder(final Builder builder) {
            if (builder.maxConnectionPoolSize < 1)
                throw new IllegalArgumentException("maxConnectionPoolSize must be greater than zero");

            if (builder.maxWaitForConnection < 1)
                throw new IllegalArgumentException("maxWaitForConnection must be greater than zero");

            if (builder.maxWaitForClose < 1)
                throw new IllegalArgumentException("maxWaitForClose must be greater than zero");

            if (builder.maxResponseContentLength < 0)
                throw new IllegalArgumentException("maxResponseContentLength must be greater than or equal to zero");

            if (builder.reconnectInterval < 1)
                throw new IllegalArgumentException("reconnectInterval must be greater than zero");

            if (builder.resultIterationBatchSize < 1)
                throw new IllegalArgumentException("resultIterationBatchSize must be greater than zero");

            if (builder.nioPoolSize < 1)
                throw new IllegalArgumentException("nioPoolSize must be greater than zero");

            if (builder.workerPoolSize < 1)
                throw new IllegalArgumentException("workerPoolSize must be greater than zero");

            if (builder.connectionSetupTimeoutMillis < 1)
                throw new IllegalArgumentException("connectionSetupTimeoutMillis must be greater than zero");

            // zero value will disable idle connection detection
            // non-zero will be converted to seconds so any value between 1 and 999 is invalid as it will be less than 1 second
            if (builder.idleConnectionTimeoutMillis != 0 && builder.idleConnectionTimeoutMillis < 1000)
                throw new IllegalArgumentException("idleConnectionTimeoutMillis must be zero or greater than or equal to 1000");

        }
Thread pool for background work related to the {@link Connection} and {@link ConnectionPool}.
gremlin-driver/src/main/java/org/apache/tinkerpop/gremlin/driver/Cluster.java