1. Packages
  2. Bytepluscc Provider
  3. API Docs
  4. rdspostgresql
  5. DbEndpoint
Viewing docs for bytepluscc v0.0.21
published on Thursday, Apr 2, 2026 by Byteplus
bytepluscc logo
Viewing docs for bytepluscc v0.0.21
published on Thursday, Apr 2, 2026 by Byteplus

    The connection endpoint is a network proxy service positioned between the database and the application, handling all requests from the application to the database. It features high availability, high performance, maintainability, and ease of use, and supports advanced functions such as read/write splitting and load balancing. The PostgreSQL cloud database provides two types of endpoints: default endpoint and custom read-only endpoint.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as bytepluscc from "@byteplus/pulumi-bytepluscc";
    
    const rdsPostgresqlDbEndpointDemo = new bytepluscc.rdspostgresql.DbEndpoint("RdsPostgresqlDbEndpointDemo", {
        endpointName: "ccapi-test-1",
        endpointType: "Custom",
        instanceId: "postgres-9dxxxxxd",
        nodes: "Primary",
        readWriteMode: "ReadWrite",
    });
    
    import pulumi
    import pulumi_bytepluscc as bytepluscc
    
    rds_postgresql_db_endpoint_demo = bytepluscc.rdspostgresql.DbEndpoint("RdsPostgresqlDbEndpointDemo",
        endpoint_name="ccapi-test-1",
        endpoint_type="Custom",
        instance_id="postgres-9dxxxxxd",
        nodes="Primary",
        read_write_mode="ReadWrite")
    
    package main
    
    import (
    	"github.com/byteplus-sdk/pulumi-bytepluscc/sdk/go/bytepluscc/rdspostgresql"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := rdspostgresql.NewDbEndpoint(ctx, "RdsPostgresqlDbEndpointDemo", &rdspostgresql.DbEndpointArgs{
    			EndpointName:  pulumi.String("ccapi-test-1"),
    			EndpointType:  pulumi.String("Custom"),
    			InstanceId:    pulumi.String("postgres-9dxxxxxd"),
    			Nodes:         pulumi.String("Primary"),
    			ReadWriteMode: pulumi.String("ReadWrite"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Bytepluscc = Byteplus.Pulumi.Bytepluscc;
    
    return await Deployment.RunAsync(() => 
    {
        var rdsPostgresqlDbEndpointDemo = new Bytepluscc.Rdspostgresql.DbEndpoint("RdsPostgresqlDbEndpointDemo", new()
        {
            EndpointName = "ccapi-test-1",
            EndpointType = "Custom",
            InstanceId = "postgres-9dxxxxxd",
            Nodes = "Primary",
            ReadWriteMode = "ReadWrite",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.byteplus.bytepluscc.rdspostgresql.DbEndpoint;
    import com.byteplus.bytepluscc.rdspostgresql.DbEndpointArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var rdsPostgresqlDbEndpointDemo = new DbEndpoint("rdsPostgresqlDbEndpointDemo", DbEndpointArgs.builder()
                .endpointName("ccapi-test-1")
                .endpointType("Custom")
                .instanceId("postgres-9dxxxxxd")
                .nodes("Primary")
                .readWriteMode("ReadWrite")
                .build());
    
        }
    }
    
    resources:
      rdsPostgresqlDbEndpointDemo:
        type: bytepluscc:rdspostgresql:DbEndpoint
        name: RdsPostgresqlDbEndpointDemo
        properties:
          endpointName: ccapi-test-1
          endpointType: Custom
          instanceId: postgres-9dxxxxxd
          nodes: Primary
          readWriteMode: ReadWrite
    

    Create DbEndpoint Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new DbEndpoint(name: string, args?: DbEndpointArgs, opts?: CustomResourceOptions);
    @overload
    def DbEndpoint(resource_name: str,
                   args: Optional[DbEndpointArgs] = None,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def DbEndpoint(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   addresses: Optional[Sequence[DbEndpointAddressArgs]] = None,
                   enable_read_write_splitting: Optional[str] = None,
                   endpoint_name: Optional[str] = None,
                   endpoint_type: Optional[str] = None,
                   instance_id: Optional[str] = None,
                   nodes: Optional[str] = None,
                   read_only_node_distribution_type: Optional[str] = None,
                   read_only_node_max_delay_time: Optional[int] = None,
                   read_only_node_weights: Optional[Sequence[DbEndpointReadOnlyNodeWeightArgs]] = None,
                   read_write_mode: Optional[str] = None,
                   read_write_proxy_connection: Optional[int] = None,
                   write_node_halt_writing: Optional[bool] = None)
    func NewDbEndpoint(ctx *Context, name string, args *DbEndpointArgs, opts ...ResourceOption) (*DbEndpoint, error)
    public DbEndpoint(string name, DbEndpointArgs? args = null, CustomResourceOptions? opts = null)
    public DbEndpoint(String name, DbEndpointArgs args)
    public DbEndpoint(String name, DbEndpointArgs args, CustomResourceOptions options)
    
    type: bytepluscc:rdspostgresql:DbEndpoint
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args DbEndpointArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args DbEndpointArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args DbEndpointArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args DbEndpointArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args DbEndpointArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var dbEndpointResource = new Bytepluscc.Rdspostgresql.DbEndpoint("dbEndpointResource", new()
    {
        Addresses = new[]
        {
            new Bytepluscc.Rdspostgresql.Inputs.DbEndpointAddressArgs
            {
                DnsVisibility = false,
                DomainPrefix = "string",
                Port = "string",
            },
        },
        EnableReadWriteSplitting = "string",
        EndpointName = "string",
        EndpointType = "string",
        InstanceId = "string",
        Nodes = "string",
        ReadOnlyNodeDistributionType = "string",
        ReadOnlyNodeMaxDelayTime = 0,
        ReadOnlyNodeWeights = new[]
        {
            new Bytepluscc.Rdspostgresql.Inputs.DbEndpointReadOnlyNodeWeightArgs
            {
                NodeId = "string",
                NodeType = "string",
                Weight = 0,
            },
        },
        ReadWriteMode = "string",
        ReadWriteProxyConnection = 0,
        WriteNodeHaltWriting = false,
    });
    
    example, err := rdspostgresql.NewDbEndpoint(ctx, "dbEndpointResource", &rdspostgresql.DbEndpointArgs{
    	Addresses: rdspostgresql.DbEndpointAddressArray{
    		&rdspostgresql.DbEndpointAddressArgs{
    			DnsVisibility: pulumi.Bool(false),
    			DomainPrefix:  pulumi.String("string"),
    			Port:          pulumi.String("string"),
    		},
    	},
    	EnableReadWriteSplitting:     pulumi.String("string"),
    	EndpointName:                 pulumi.String("string"),
    	EndpointType:                 pulumi.String("string"),
    	InstanceId:                   pulumi.String("string"),
    	Nodes:                        pulumi.String("string"),
    	ReadOnlyNodeDistributionType: pulumi.String("string"),
    	ReadOnlyNodeMaxDelayTime:     pulumi.Int(0),
    	ReadOnlyNodeWeights: rdspostgresql.DbEndpointReadOnlyNodeWeightArray{
    		&rdspostgresql.DbEndpointReadOnlyNodeWeightArgs{
    			NodeId:   pulumi.String("string"),
    			NodeType: pulumi.String("string"),
    			Weight:   pulumi.Int(0),
    		},
    	},
    	ReadWriteMode:            pulumi.String("string"),
    	ReadWriteProxyConnection: pulumi.Int(0),
    	WriteNodeHaltWriting:     pulumi.Bool(false),
    })
    
    var dbEndpointResource = new DbEndpoint("dbEndpointResource", DbEndpointArgs.builder()
        .addresses(DbEndpointAddressArgs.builder()
            .dnsVisibility(false)
            .domainPrefix("string")
            .port("string")
            .build())
        .enableReadWriteSplitting("string")
        .endpointName("string")
        .endpointType("string")
        .instanceId("string")
        .nodes("string")
        .readOnlyNodeDistributionType("string")
        .readOnlyNodeMaxDelayTime(0)
        .readOnlyNodeWeights(DbEndpointReadOnlyNodeWeightArgs.builder()
            .nodeId("string")
            .nodeType("string")
            .weight(0)
            .build())
        .readWriteMode("string")
        .readWriteProxyConnection(0)
        .writeNodeHaltWriting(false)
        .build());
    
    db_endpoint_resource = bytepluscc.rdspostgresql.DbEndpoint("dbEndpointResource",
        addresses=[{
            "dns_visibility": False,
            "domain_prefix": "string",
            "port": "string",
        }],
        enable_read_write_splitting="string",
        endpoint_name="string",
        endpoint_type="string",
        instance_id="string",
        nodes="string",
        read_only_node_distribution_type="string",
        read_only_node_max_delay_time=0,
        read_only_node_weights=[{
            "node_id": "string",
            "node_type": "string",
            "weight": 0,
        }],
        read_write_mode="string",
        read_write_proxy_connection=0,
        write_node_halt_writing=False)
    
    const dbEndpointResource = new bytepluscc.rdspostgresql.DbEndpoint("dbEndpointResource", {
        addresses: [{
            dnsVisibility: false,
            domainPrefix: "string",
            port: "string",
        }],
        enableReadWriteSplitting: "string",
        endpointName: "string",
        endpointType: "string",
        instanceId: "string",
        nodes: "string",
        readOnlyNodeDistributionType: "string",
        readOnlyNodeMaxDelayTime: 0,
        readOnlyNodeWeights: [{
            nodeId: "string",
            nodeType: "string",
            weight: 0,
        }],
        readWriteMode: "string",
        readWriteProxyConnection: 0,
        writeNodeHaltWriting: false,
    });
    
    type: bytepluscc:rdspostgresql:DbEndpoint
    properties:
        addresses:
            - dnsVisibility: false
              domainPrefix: string
              port: string
        enableReadWriteSplitting: string
        endpointName: string
        endpointType: string
        instanceId: string
        nodes: string
        readOnlyNodeDistributionType: string
        readOnlyNodeMaxDelayTime: 0
        readOnlyNodeWeights:
            - nodeId: string
              nodeType: string
              weight: 0
        readWriteMode: string
        readWriteProxyConnection: 0
        writeNodeHaltWriting: false
    

    DbEndpoint Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The DbEndpoint resource accepts the following input properties:

    Addresses List<Byteplus.DbEndpointAddress>
    EnableReadWriteSplitting string
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    EndpointName string
    Instance connection endpoint name.
    EndpointType string
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    InstanceId string
    Instance ID.
    Nodes string
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    ReadOnlyNodeDistributionType string
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    ReadOnlyNodeMaxDelayTime int
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    ReadOnlyNodeWeights List<Byteplus.DbEndpointReadOnlyNodeWeight>
    ReadWriteMode string
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    ReadWriteProxyConnection int
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    WriteNodeHaltWriting bool
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    Addresses []DbEndpointAddressArgs
    EnableReadWriteSplitting string
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    EndpointName string
    Instance connection endpoint name.
    EndpointType string
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    InstanceId string
    Instance ID.
    Nodes string
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    ReadOnlyNodeDistributionType string
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    ReadOnlyNodeMaxDelayTime int
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    ReadOnlyNodeWeights []DbEndpointReadOnlyNodeWeightArgs
    ReadWriteMode string
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    ReadWriteProxyConnection int
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    WriteNodeHaltWriting bool
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses List<DbEndpointAddress>
    enableReadWriteSplitting String
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpointName String
    Instance connection endpoint name.
    endpointType String
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instanceId String
    Instance ID.
    nodes String
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    readOnlyNodeDistributionType String
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    readOnlyNodeMaxDelayTime Integer
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    readOnlyNodeWeights List<DbEndpointReadOnlyNodeWeight>
    readWriteMode String
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    readWriteProxyConnection Integer
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    writeNodeHaltWriting Boolean
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses DbEndpointAddress[]
    enableReadWriteSplitting string
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpointName string
    Instance connection endpoint name.
    endpointType string
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instanceId string
    Instance ID.
    nodes string
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    readOnlyNodeDistributionType string
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    readOnlyNodeMaxDelayTime number
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    readOnlyNodeWeights DbEndpointReadOnlyNodeWeight[]
    readWriteMode string
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    readWriteProxyConnection number
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    writeNodeHaltWriting boolean
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses Sequence[DbEndpointAddressArgs]
    enable_read_write_splitting str
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpoint_name str
    Instance connection endpoint name.
    endpoint_type str
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instance_id str
    Instance ID.
    nodes str
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    read_only_node_distribution_type str
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    read_only_node_max_delay_time int
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    read_only_node_weights Sequence[DbEndpointReadOnlyNodeWeightArgs]
    read_write_mode str
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    read_write_proxy_connection int
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    write_node_halt_writing bool
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses List<Property Map>
    enableReadWriteSplitting String
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpointName String
    Instance connection endpoint name.
    endpointType String
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instanceId String
    Instance ID.
    nodes String
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    readOnlyNodeDistributionType String
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    readOnlyNodeMaxDelayTime Number
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    readOnlyNodeWeights List<Property Map>
    readWriteMode String
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    readWriteProxyConnection Number
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    writeNodeHaltWriting Boolean
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the DbEndpoint resource produces the following output properties:

    AutoAddNewNodes string
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    Description string
    Address description
    EnableReadOnly string
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    EndpointId string
    Instance connection endpoint ID.
    Id string
    The provider-assigned unique ID for this managed resource.
    AutoAddNewNodes string
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    Description string
    Address description
    EnableReadOnly string
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    EndpointId string
    Instance connection endpoint ID.
    Id string
    The provider-assigned unique ID for this managed resource.
    autoAddNewNodes String
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description String
    Address description
    enableReadOnly String
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    endpointId String
    Instance connection endpoint ID.
    id String
    The provider-assigned unique ID for this managed resource.
    autoAddNewNodes string
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description string
    Address description
    enableReadOnly string
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    endpointId string
    Instance connection endpoint ID.
    id string
    The provider-assigned unique ID for this managed resource.
    auto_add_new_nodes str
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description str
    Address description
    enable_read_only str
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    endpoint_id str
    Instance connection endpoint ID.
    id str
    The provider-assigned unique ID for this managed resource.
    autoAddNewNodes String
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description String
    Address description
    enableReadOnly String
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    endpointId String
    Instance connection endpoint ID.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing DbEndpoint Resource

    Get an existing DbEndpoint resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: DbEndpointState, opts?: CustomResourceOptions): DbEndpoint
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            addresses: Optional[Sequence[DbEndpointAddressArgs]] = None,
            auto_add_new_nodes: Optional[str] = None,
            description: Optional[str] = None,
            enable_read_only: Optional[str] = None,
            enable_read_write_splitting: Optional[str] = None,
            endpoint_id: Optional[str] = None,
            endpoint_name: Optional[str] = None,
            endpoint_type: Optional[str] = None,
            instance_id: Optional[str] = None,
            nodes: Optional[str] = None,
            read_only_node_distribution_type: Optional[str] = None,
            read_only_node_max_delay_time: Optional[int] = None,
            read_only_node_weights: Optional[Sequence[DbEndpointReadOnlyNodeWeightArgs]] = None,
            read_write_mode: Optional[str] = None,
            read_write_proxy_connection: Optional[int] = None,
            write_node_halt_writing: Optional[bool] = None) -> DbEndpoint
    func GetDbEndpoint(ctx *Context, name string, id IDInput, state *DbEndpointState, opts ...ResourceOption) (*DbEndpoint, error)
    public static DbEndpoint Get(string name, Input<string> id, DbEndpointState? state, CustomResourceOptions? opts = null)
    public static DbEndpoint get(String name, Output<String> id, DbEndpointState state, CustomResourceOptions options)
    resources:  _:    type: bytepluscc:rdspostgresql:DbEndpoint    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Addresses List<Byteplus.DbEndpointAddress>
    AutoAddNewNodes string
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    Description string
    Address description
    EnableReadOnly string
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    EnableReadWriteSplitting string
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    EndpointId string
    Instance connection endpoint ID.
    EndpointName string
    Instance connection endpoint name.
    EndpointType string
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    InstanceId string
    Instance ID.
    Nodes string
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    ReadOnlyNodeDistributionType string
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    ReadOnlyNodeMaxDelayTime int
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    ReadOnlyNodeWeights List<Byteplus.DbEndpointReadOnlyNodeWeight>
    ReadWriteMode string
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    ReadWriteProxyConnection int
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    WriteNodeHaltWriting bool
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    Addresses []DbEndpointAddressArgs
    AutoAddNewNodes string
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    Description string
    Address description
    EnableReadOnly string
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    EnableReadWriteSplitting string
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    EndpointId string
    Instance connection endpoint ID.
    EndpointName string
    Instance connection endpoint name.
    EndpointType string
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    InstanceId string
    Instance ID.
    Nodes string
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    ReadOnlyNodeDistributionType string
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    ReadOnlyNodeMaxDelayTime int
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    ReadOnlyNodeWeights []DbEndpointReadOnlyNodeWeightArgs
    ReadWriteMode string
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    ReadWriteProxyConnection int
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    WriteNodeHaltWriting bool
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses List<DbEndpointAddress>
    autoAddNewNodes String
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description String
    Address description
    enableReadOnly String
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    enableReadWriteSplitting String
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpointId String
    Instance connection endpoint ID.
    endpointName String
    Instance connection endpoint name.
    endpointType String
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instanceId String
    Instance ID.
    nodes String
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    readOnlyNodeDistributionType String
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    readOnlyNodeMaxDelayTime Integer
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    readOnlyNodeWeights List<DbEndpointReadOnlyNodeWeight>
    readWriteMode String
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    readWriteProxyConnection Integer
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    writeNodeHaltWriting Boolean
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses DbEndpointAddress[]
    autoAddNewNodes string
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description string
    Address description
    enableReadOnly string
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    enableReadWriteSplitting string
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpointId string
    Instance connection endpoint ID.
    endpointName string
    Instance connection endpoint name.
    endpointType string
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instanceId string
    Instance ID.
    nodes string
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    readOnlyNodeDistributionType string
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    readOnlyNodeMaxDelayTime number
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    readOnlyNodeWeights DbEndpointReadOnlyNodeWeight[]
    readWriteMode string
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    readWriteProxyConnection number
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    writeNodeHaltWriting boolean
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses Sequence[DbEndpointAddressArgs]
    auto_add_new_nodes str
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description str
    Address description
    enable_read_only str
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    enable_read_write_splitting str
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpoint_id str
    Instance connection endpoint ID.
    endpoint_name str
    Instance connection endpoint name.
    endpoint_type str
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instance_id str
    Instance ID.
    nodes str
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    read_only_node_distribution_type str
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    read_only_node_max_delay_time int
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    read_only_node_weights Sequence[DbEndpointReadOnlyNodeWeightArgs]
    read_write_mode str
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    read_write_proxy_connection int
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    write_node_halt_writing bool
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.
    addresses List<Property Map>
    autoAddNewNodes String
    When the endpoint type is read/write or read-only, you can configure whether new nodes are automatically added. Values: Enable: Automatically add. Disable: Do not automatically add (default).
    description String
    Address description
    enableReadOnly String
    Whether global read-only is enabled. Enable: Enabled. Disable: Not enabled.
    enableReadWriteSplitting String
    Whether read/write splitting is enabled. Values: Enable: Enabled. Disable: Not enabled.
    endpointId String
    Instance connection endpoint ID.
    endpointName String
    Instance connection endpoint name.
    endpointType String
    Endpoint type: Cluster: default endpoint (created by default). Custom: custom endpoint.
    instanceId String
    Instance ID.
    nodes String
    List of nodes configured for the connection endpoint. Note: Required when EndpointType is Custom. The primary node does not require a node ID; use the string 'Primary'.
    readOnlyNodeDistributionType String
    Read-only weight allocation mode. Values: Default: standard weight allocation (default). Custom: custom weight allocation.
    readOnlyNodeMaxDelayTime Number
    Maximum latency threshold for read-only nodes. When the latency of a read-only node exceeds this value, read traffic will not be sent to that node. Unit: seconds. Range: 0~3600. Default: 30. Note: This parameter can be set for default endpoints with read/write splitting enabled.
    readOnlyNodeWeights List<Property Map>
    readWriteMode String
    Read/write mode: ReadWrite: read/write. ReadOnly: read-only.
    readWriteProxyConnection Number
    After enabling read/write splitting for the endpoint, set the number of proxy connections for the endpoint. The minimum value for proxy connections is 20. The maximum value depends on the specifications of the primary node; different specifications support different maximum proxy connections. For details, see product specifications.
    writeNodeHaltWriting Boolean
    Whether the endpoint sends write requests to the write node (currently only the primary node is the write node). Values: true: Yes (default). false: No.

    Supporting Types

    DbEndpointAddress, DbEndpointAddressArgs

    DnsVisibility bool
    Whether public network resolution is enabled. Values: false: Default, private network resolution. true: Both private and public network resolution.
    DomainPrefix string
    New access address prefix. The access address prefix must meet the following rules: consists of lowercase letters, numbers, and hyphens (-). Must contain at least 8 characters. The total length (including suffix) must not exceed 63 characters. Must start with a lowercase letter and end with a lowercase letter or number.
    Port string
    Port number.
    DnsVisibility bool
    Whether public network resolution is enabled. Values: false: Default, private network resolution. true: Both private and public network resolution.
    DomainPrefix string
    New access address prefix. The access address prefix must meet the following rules: consists of lowercase letters, numbers, and hyphens (-). Must contain at least 8 characters. The total length (including suffix) must not exceed 63 characters. Must start with a lowercase letter and end with a lowercase letter or number.
    Port string
    Port number.
    dnsVisibility Boolean
    Whether public network resolution is enabled. Values: false: Default, private network resolution. true: Both private and public network resolution.
    domainPrefix String
    New access address prefix. The access address prefix must meet the following rules: consists of lowercase letters, numbers, and hyphens (-). Must contain at least 8 characters. The total length (including suffix) must not exceed 63 characters. Must start with a lowercase letter and end with a lowercase letter or number.
    port String
    Port number.
    dnsVisibility boolean
    Whether public network resolution is enabled. Values: false: Default, private network resolution. true: Both private and public network resolution.
    domainPrefix string
    New access address prefix. The access address prefix must meet the following rules: consists of lowercase letters, numbers, and hyphens (-). Must contain at least 8 characters. The total length (including suffix) must not exceed 63 characters. Must start with a lowercase letter and end with a lowercase letter or number.
    port string
    Port number.
    dns_visibility bool
    Whether public network resolution is enabled. Values: false: Default, private network resolution. true: Both private and public network resolution.
    domain_prefix str
    New access address prefix. The access address prefix must meet the following rules: consists of lowercase letters, numbers, and hyphens (-). Must contain at least 8 characters. The total length (including suffix) must not exceed 63 characters. Must start with a lowercase letter and end with a lowercase letter or number.
    port str
    Port number.
    dnsVisibility Boolean
    Whether public network resolution is enabled. Values: false: Default, private network resolution. true: Both private and public network resolution.
    domainPrefix String
    New access address prefix. The access address prefix must meet the following rules: consists of lowercase letters, numbers, and hyphens (-). Must contain at least 8 characters. The total length (including suffix) must not exceed 63 characters. Must start with a lowercase letter and end with a lowercase letter or number.
    port String
    Port number.

    DbEndpointReadOnlyNodeWeight, DbEndpointReadOnlyNodeWeightArgs

    NodeId string
    Read-only nodes require the NodeId to be provided.
    NodeType string
    Node type. Values: Primary: primary node. ReadOnly: read-only node.
    Weight int
    Read weight of the node, increases in increments of 100, maximum value is 40000. Note: Weights cannot all be set to 0.
    NodeId string
    Read-only nodes require the NodeId to be provided.
    NodeType string
    Node type. Values: Primary: primary node. ReadOnly: read-only node.
    Weight int
    Read weight of the node, increases in increments of 100, maximum value is 40000. Note: Weights cannot all be set to 0.
    nodeId String
    Read-only nodes require the NodeId to be provided.
    nodeType String
    Node type. Values: Primary: primary node. ReadOnly: read-only node.
    weight Integer
    Read weight of the node, increases in increments of 100, maximum value is 40000. Note: Weights cannot all be set to 0.
    nodeId string
    Read-only nodes require the NodeId to be provided.
    nodeType string
    Node type. Values: Primary: primary node. ReadOnly: read-only node.
    weight number
    Read weight of the node, increases in increments of 100, maximum value is 40000. Note: Weights cannot all be set to 0.
    node_id str
    Read-only nodes require the NodeId to be provided.
    node_type str
    Node type. Values: Primary: primary node. ReadOnly: read-only node.
    weight int
    Read weight of the node, increases in increments of 100, maximum value is 40000. Note: Weights cannot all be set to 0.
    nodeId String
    Read-only nodes require the NodeId to be provided.
    nodeType String
    Node type. Values: Primary: primary node. ReadOnly: read-only node.
    weight Number
    Read weight of the node, increases in increments of 100, maximum value is 40000. Note: Weights cannot all be set to 0.

    Import

    $ pulumi import bytepluscc:rdspostgresql/dbEndpoint:DbEndpoint example "instance_id|endpoint_id"
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    bytepluscc byteplus-sdk/pulumi-bytepluscc
    License
    MPL-2.0
    Notes
    This Pulumi package is based on the bytepluscc Terraform Provider.
    bytepluscc logo
    Viewing docs for bytepluscc v0.0.21
    published on Thursday, Apr 2, 2026 by Byteplus
      Try Pulumi Cloud free. Your team will thank you.