@digitalocean/dots - v1.0.1
    Preparing search index...

    Interface PoolsRequestBuilder

    Builds and executes requests for operations under /v2/databases/{database_cluster_uuid}/pools

    interface PoolsRequestBuilder {
        byPool_name(pool_name: string): WithPool_nameItemRequestBuilder;
        get(
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<undefined | Connection_pools>;
        post(
            body: Connection_pool,
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<undefined | PoolsPostResponse>;
        toGetRequestInformation(
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        toPostRequestInformation(
            body: Connection_pool,
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        withUrl(rawUrl: string): PoolsRequestBuilder;
    }

    Hierarchy

    Index

    Methods

    • To list all of the connection pools available to a PostgreSQL database cluster, send a GET request to /v2/databases/$DATABASE_ID/pools.The result will be a JSON object with a pools key. This will be set to an array of connection pool objects.

      Parameters

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<undefined | Connection_pools>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    post

    • post(
          body: Connection_pool,
          requestConfiguration?: RequestConfiguration<object>,
      ): Promise<undefined | PoolsPostResponse>

      For PostgreSQL database clusters, connection pools can be used to allow adatabase to share its idle connections. The popular PostgreSQL connectionpooling utility PgBouncer is used to provide this service. See here for more informationabout how and why to use PgBouncer connection pooling includingdetails about the available transaction modes.To add a new connection pool to a PostgreSQL database cluster, send a POSTrequest to /v2/databases/$DATABASE_ID/pools specifying a name for the pool,the user to connect with, the database to connect to, as well as its desiredsize and transaction mode.

      Parameters

      • body: Connection_pool

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<undefined | PoolsPostResponse>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    • To list all of the connection pools available to a PostgreSQL database cluster, send a GET request to /v2/databases/$DATABASE_ID/pools.The result will be a JSON object with a pools key. This will be set to an array of connection pool objects.

      Parameters

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation

    • For PostgreSQL database clusters, connection pools can be used to allow adatabase to share its idle connections. The popular PostgreSQL connectionpooling utility PgBouncer is used to provide this service. See here for more informationabout how and why to use PgBouncer connection pooling includingdetails about the available transaction modes.To add a new connection pool to a PostgreSQL database cluster, send a POSTrequest to /v2/databases/$DATABASE_ID/pools specifying a name for the pool,the user to connect with, the database to connect to, as well as its desiredsize and transaction mode.

      Parameters

      • body: Connection_pool

        The request body

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation

    • Parameters

      • rawUrl: string

      Returns PoolsRequestBuilder