ConnectionPoolOptions

public struct ConnectionPoolOptions

Options for ConectionPool configuration.

  • The initial number of connections in the pool.

    Declaration

    Swift

    public let initialCapacity: Int
  • The maximum number of connections in the pool. The pool is allowed to grow from initialCapacity up to this limit. If not specified, or maxCapacity <= initialCapacity, the pool cannot grow.

    Declaration

    Swift

    public let maxCapacity: Int
  • Initialize an instance of ConnectionPoolOptions.

    Declaration

    Swift

    public init(initialCapacity: Int, maxCapacity: Int = 0)

    Parameters

    initialCapacity

    The initial number of connections in the pool.

    maxCapacity

    The maximum number of connections in the pool

    timeout

    Maximum wait (in milliseconds) to receive a connection before returning nil.