Help us shape the future of Go! Take the 2026 Go Developer Survey

clb

package
v1.83.34 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 30, 2026 License: MPL-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CLB_NETWORK_TYPE_OPEN     = "OPEN"
	CLB_NETWORK_TYPE_INTERNAL = "INTERNAL"
)
View Source
const (
	CLB_LISTENER_PROTOCOL_TCP    = "TCP"
	CLB_LISTENER_PROTOCOL_UDP    = "UDP"
	CLB_LISTENER_PROTOCOL_HTTP   = "HTTP"
	CLB_LISTENER_PROTOCOL_HTTPS  = "HTTPS"
	CLB_LISTENER_PROTOCOL_TCPSSL = "TCP_SSL"
	CLB_LISTENER_PROTOCOL_QUIC   = "QUIC"
)
View Source
const (
	CLB_HTTP_METHOD_GET  = "GET"
	CLB_HTTP_METHOD_HEAD = "HEAD"
)
View Source
const (
	CLB_LISTENER_SCHEDULER_WRR       = "WRR"
	CLB_LISTENER_SCHEDULER_LEASTCONN = "LEAST_CONN"
	CLB_LISTENER_SCHEDULER_IP_HASH   = "IP_HASH"
)
View Source
const (
	HTTP_VERSION_ONE_ZERO = "HTTP/1.0"
	HTTP_VERSION_ONE_ONE  = "HTTP/1.1"
)
View Source
const (
	HEALTH_CHECK_TYPE_CUSTOM = "CUSTOM"
	HEALTH_CHECK_TYPE_PING   = "PING"
	HEALTH_CHECK_TYPE_TCP    = "TCP"
	HEALTH_CHECK_TYPE_HTTP   = "HTTP"
	HEALTH_CHECK_TYPE_HTTPS  = "HTTPS"
	HEALTH_CHECK_TYPE_GRPC   = "GRPC"
	HEALTH_CHECK_TYPE_GRPCS  = "GRPCS"
)
View Source
const (
	CONTEX_TYPE_HEX  = "HEX"
	CONTEX_TYPE_TEXT = "TEXT"
)
View Source
const (
	CERT_SSL_MODE_UNI = "UNIDIRECTIONAL"
	CERT_SSL_MODE_MUT = "MUTUAL"
)
View Source
const (
	CLB_TASK_SUCCESS   = 0
	CLB_TASK_FAIL      = 1
	CLB_TASK_EXPANDING = 2
)
View Source
const (
	HEALTH_APPLY_TYPE_LISTENER = "listener"
	HEALTH_APPLY_TYPE_RULE     = "rule"
)
View Source
const (
	AUTO_TARGET_PORT = 443
	AUTO_SOURCE_PORT = 80
)
View Source
const (
	CLB_TARGET_TYPE_NODE           = "NODE"
	CLB_TARGET_TYPE_TARGETGROUP    = "TARGETGROUP"
	CLB_TARGET_TYPE_TARGETGROUP_V2 = "TARGETGROUP-V2"
)
View Source
const (
	CLB_BACKEND_TYPE_CVM  = "CVM"
	CLB_BACKEND_TYPE_ENI  = "ENI"
	CLB_BACKEND_TYPE_NAT  = "NAT"
	CLB_BACKEND_TYPE_CCN  = "CCN"
	CLB_BACKEND_TYPE_SRV  = "SRV"
	CLB_BACKEND_TYPE_MS   = "MANAGED_SERVICE"
	CLB_BACKEND_TYPE_EVM  = "EVM"
	CLB_BACKEND_TYPE_GR   = "GLOBALROUTE"
	CLB_BACKEND_TYPE_IPDC = "IPDC"
	CLB_BACKEND_TYPE_PVGW = "PVGW"
)
View Source
const (
	CLB_SESSION_TYPE_NORMAL = "NORMAL"
	CLB_SESSION_TYPE_QUIC   = "QUIC_CID"
)
View Source
const (
	CLB_PAGE_LIMIT = 100
)
View Source
const (
	FORWARD_TYPE_HTTP = "HTTP"
)
View Source
const ResourcePrefixFromClb = "lb"

Variables

View Source
var FORWARD_TYPE = []string{
	FORWARD_TYPE_HTTP,
}

Functions

func DataSourceTencentCloudClbClusterResources

func DataSourceTencentCloudClbClusterResources() *schema.Resource

func DataSourceTencentCloudClbCrossTargets

func DataSourceTencentCloudClbCrossTargets() *schema.Resource

func DataSourceTencentCloudClbExclusiveClusters

func DataSourceTencentCloudClbExclusiveClusters() *schema.Resource

func DataSourceTencentCloudClbIdleInstances

func DataSourceTencentCloudClbIdleInstances() *schema.Resource

func DataSourceTencentCloudClbInstanceByCertId

func DataSourceTencentCloudClbInstanceByCertId() *schema.Resource

func DataSourceTencentCloudClbInstanceDetail

func DataSourceTencentCloudClbInstanceDetail() *schema.Resource

func DataSourceTencentCloudClbInstanceTraffic

func DataSourceTencentCloudClbInstanceTraffic() *schema.Resource

func DataSourceTencentCloudClbInstances

func DataSourceTencentCloudClbInstances() *schema.Resource

func DataSourceTencentCloudClbListenerRules

func DataSourceTencentCloudClbListenerRules() *schema.Resource

func DataSourceTencentCloudClbListeners

func DataSourceTencentCloudClbListeners() *schema.Resource

func DataSourceTencentCloudClbListenersByTargets

func DataSourceTencentCloudClbListenersByTargets() *schema.Resource

func DataSourceTencentCloudClbRedirections

func DataSourceTencentCloudClbRedirections() *schema.Resource

func DataSourceTencentCloudClbResources

func DataSourceTencentCloudClbResources() *schema.Resource

func DataSourceTencentCloudClbServerAttachments

func DataSourceTencentCloudClbServerAttachments() *schema.Resource

func DataSourceTencentCloudClbTargetGroupList

func DataSourceTencentCloudClbTargetGroupList() *schema.Resource

func DataSourceTencentCloudClbTargetGroups

func DataSourceTencentCloudClbTargetGroups() *schema.Resource

func DataSourceTencentCloudClbTargetHealth

func DataSourceTencentCloudClbTargetHealth() *schema.Resource

func IsHealthCheckEnable added in v1.81.92

func IsHealthCheckEnable(healthSwitch int64) bool

func ListenerIdCheck

func ListenerIdCheck(listenerId string) error

func ResourceTencentCloudAlbServerAttachment

func ResourceTencentCloudAlbServerAttachment() *schema.Resource

func ResourceTencentCloudClbClsLogAttachment added in v1.82.35

func ResourceTencentCloudClbClsLogAttachment() *schema.Resource

func ResourceTencentCloudClbCustomizedConfig

func ResourceTencentCloudClbCustomizedConfig() *schema.Resource

func ResourceTencentCloudClbCustomizedConfigAttachment added in v1.81.169

func ResourceTencentCloudClbCustomizedConfigAttachment() *schema.Resource

func ResourceTencentCloudClbCustomizedConfigV2 added in v1.81.169

func ResourceTencentCloudClbCustomizedConfigV2() *schema.Resource

func ResourceTencentCloudClbFunctionTargetsAttachment

func ResourceTencentCloudClbFunctionTargetsAttachment() *schema.Resource

func ResourceTencentCloudClbInstance

func ResourceTencentCloudClbInstance() *schema.Resource

func ResourceTencentCloudClbInstanceMixIpTargetConfig

func ResourceTencentCloudClbInstanceMixIpTargetConfig() *schema.Resource

func ResourceTencentCloudClbInstanceSlaConfig

func ResourceTencentCloudClbInstanceSlaConfig() *schema.Resource

func ResourceTencentCloudClbListener

func ResourceTencentCloudClbListener() *schema.Resource

func ResourceTencentCloudClbListenerDefaultDomain added in v1.81.134

func ResourceTencentCloudClbListenerDefaultDomain() *schema.Resource

func ResourceTencentCloudClbListenerRule

func ResourceTencentCloudClbListenerRule() *schema.Resource

func ResourceTencentCloudClbLogSet

func ResourceTencentCloudClbLogSet() *schema.Resource

func ResourceTencentCloudClbLogTopic

func ResourceTencentCloudClbLogTopic() *schema.Resource

func ResourceTencentCloudClbRedirection

func ResourceTencentCloudClbRedirection() *schema.Resource

func ResourceTencentCloudClbReplaceCertForLbs

func ResourceTencentCloudClbReplaceCertForLbs() *schema.Resource

func ResourceTencentCloudClbSecurityGroupAttachment

func ResourceTencentCloudClbSecurityGroupAttachment() *schema.Resource

func ResourceTencentCloudClbServerAttachment

func ResourceTencentCloudClbServerAttachment() *schema.Resource

func ResourceTencentCloudClbSnatIp

func ResourceTencentCloudClbSnatIp() *schema.Resource

func ResourceTencentCloudClbTGAttachmentInstance

func ResourceTencentCloudClbTGAttachmentInstance() *schema.Resource

func ResourceTencentCloudClbTargetGroup

func ResourceTencentCloudClbTargetGroup() *schema.Resource

func ResourceTencentCloudClbTargetGroupAttachment

func ResourceTencentCloudClbTargetGroupAttachment() *schema.Resource

func ResourceTencentCloudClbTargetGroupAttachments

func ResourceTencentCloudClbTargetGroupAttachments() *schema.Resource

func ResourceTencentCloudLB

func ResourceTencentCloudLB() *schema.Resource

func RuleIdCheck

func RuleIdCheck(ruleId string) error

Types

type ClbService

type ClbService struct {
	// contains filtered or unexported fields
}

func NewClbService

func NewClbService(client *connectivity.TencentCloudClient) ClbService

func (*ClbService) AssociateTargetGroups

func (me *ClbService) AssociateTargetGroups(ctx context.Context, listenerId, clbId, targetGroupId, locationId string) (errRet error)

func (*ClbService) BindOrUnBindCustomizedConfigWithLbId

func (me *ClbService) BindOrUnBindCustomizedConfigWithLbId(ctx context.Context, action string,
	configId string, lbIdsList []interface{}) (errRet error)

func (*ClbService) CreateClbLogSet

func (me *ClbService) CreateClbLogSet(ctx context.Context, name string, logsetType string, period int) (id string, errRet error)

func (*ClbService) CreateLoadBalancerSnatIps

func (me *ClbService) CreateLoadBalancerSnatIps(ctx context.Context, id string, ips []*clb.SnatIp) (taskId string, errRet error)

func (*ClbService) CreateTargetGroup

func (me *ClbService) CreateTargetGroup(ctx context.Context, targetGroupName string, vpcId string, port uint64,
	targetGroupInstances []*clb.TargetGroupInstance, targetGroupType string, protocol string,
	healthCheck *clb.TargetGroupHealthCheck, scheduleAlgorithm string, tags []*clb.TagInfo,
	weight *uint64, fullListenSwitch *bool, keepaliveEnable *bool,
	sessionExpireTime *uint64, ipVersion string, snatEnable *bool) (targetGroupId string, err error)

func (*ClbService) CreateTopic

func (me *ClbService) CreateTopic(ctx context.Context, params map[string]interface{}) (response *clb.CreateTopicResponse, err error)

func (*ClbService) DeleteAttachmentById

func (me *ClbService) DeleteAttachmentById(ctx context.Context, clbId string, listenerId string, locationId string, targets []interface{}, domain string, url string) error

func (*ClbService) DeleteClbFunctionTargetsAttachmentById

func (me *ClbService) DeleteClbFunctionTargetsAttachmentById(ctx context.Context, loadBalancerId string, listenerId string) (errRet error)

func (*ClbService) DeleteLbCustomizedConfigById

func (me *ClbService) DeleteLbCustomizedConfigById(ctx context.Context, configId string) (errRet error)

func (*ClbService) DeleteListenerById

func (me *ClbService) DeleteListenerById(ctx context.Context, clbId string, listenerId string) error

func (*ClbService) DeleteLoadBalancerById

func (me *ClbService) DeleteLoadBalancerById(ctx context.Context, clbId string) error

func (*ClbService) DeleteLoadBalancerSnatIps

func (me *ClbService) DeleteLoadBalancerSnatIps(ctx context.Context, id string, ips []*string) (taskId string, errRet error)

func (*ClbService) DeleteRedirectionById

func (me *ClbService) DeleteRedirectionById(ctx context.Context, rewriteId string) error

func (*ClbService) DeleteRuleById

func (me *ClbService) DeleteRuleById(ctx context.Context, clbId string, listenerId string, locationId string) error

func (*ClbService) DeleteTarget

func (me *ClbService) DeleteTarget(ctx context.Context, targetGroupId string) error

func (*ClbService) DeregisterTargetInstances

func (me *ClbService) DeregisterTargetInstances(ctx context.Context, targetGroupId, bindIp string, port uint64) (err error)

func (*ClbService) DescribeAllAutoRedirections

func (me *ClbService) DescribeAllAutoRedirections(ctx context.Context, rewriteId string) (rewriteInfos []*map[string]string, errRet error)

func (*ClbService) DescribeAssociateTargetGroups

func (me *ClbService) DescribeAssociateTargetGroups(ctx context.Context, ids []string) (has bool, err error)

func (*ClbService) DescribeAttachmentByPara

func (me *ClbService) DescribeAttachmentByPara(ctx context.Context, clbId string, listenerId string, locationId string) (clbAttachment *clb.ListenerBackend, errRet error)

func (*ClbService) DescribeAttachmentsByFilter

func (me *ClbService) DescribeAttachmentsByFilter(ctx context.Context, params map[string]string) (clbAttachments []*clb.ListenerBackend, errRet error)

func (*ClbService) DescribeClbClsLogAttachmentById added in v1.82.35

func (me *ClbService) DescribeClbClsLogAttachmentById(ctx context.Context, loadBalancerId, logSetId, logTopicId string) (ret *clb.LoadBalancer, errRet error)

func (*ClbService) DescribeClbClusterResourcesByFilter

func (me *ClbService) DescribeClbClusterResourcesByFilter(ctx context.Context, param map[string]interface{}) (clusterResources []*clb.ClusterResource, errRet error)

func (*ClbService) DescribeClbCrossTargetsByFilter

func (me *ClbService) DescribeClbCrossTargetsByFilter(ctx context.Context, param map[string]interface{}) (crossTargets []*clb.CrossTargets, errRet error)

func (*ClbService) DescribeClbExclusiveClustersByFilter

func (me *ClbService) DescribeClbExclusiveClustersByFilter(ctx context.Context, param map[string]interface{}) (exclusiveClusters []*clb.Cluster, errRet error)

func (*ClbService) DescribeClbFunctionTargetsAttachmentById

func (me *ClbService) DescribeClbFunctionTargetsAttachmentById(ctx context.Context, loadBalancerId string, listenerId string,
	locationId string, domain string, url string) (functionTargets []*clb.FunctionTarget, locationIdTarget, domainTarget, urlTarget string, errRet error)

func (*ClbService) DescribeClbIdleInstancesByFilter

func (me *ClbService) DescribeClbIdleInstancesByFilter(ctx context.Context, param map[string]interface{}) (idleLoadbalancers []*clb.IdleLoadBalancer, errRet error)

func (*ClbService) DescribeClbInstanceByCertId

func (me *ClbService) DescribeClbInstanceByCertId(ctx context.Context, param map[string]interface{}) (instances []*clb.CertIdRelatedWithLoadBalancers, errRet error)

func (*ClbService) DescribeClbInstanceDetailByFilter

func (me *ClbService) DescribeClbInstanceDetailByFilter(ctx context.Context, param map[string]interface{}) (instanceDetail []*clb.LoadBalancerDetail, errRet error)

func (*ClbService) DescribeClbInstanceTraffic

func (me *ClbService) DescribeClbInstanceTraffic(ctx context.Context, param map[string]interface{}) (instanceTraffic []*clb.LoadBalancerTraffic, errRet error)

func (*ClbService) DescribeClbListenersByTargets

func (me *ClbService) DescribeClbListenersByTargets(ctx context.Context, param map[string]interface{}) (listenersByTargets []*clb.LBItem, errRet error)

func (*ClbService) DescribeClbLogSet

func (me *ClbService) DescribeClbLogSet(ctx context.Context) (logSetId string, healthId string, errRet error)

func (*ClbService) DescribeClbResourcesByFilter

func (me *ClbService) DescribeClbResourcesByFilter(ctx context.Context, param map[string]interface{}) (resources []*clb.ZoneResource, errRet error)

func (*ClbService) DescribeClbTargetGroupAttachmentsById

func (me *ClbService) DescribeClbTargetGroupAttachmentsById(ctx context.Context, targetGroups []string, associationsSet map[string]struct{}) (targetGroupAttachments []string, errRet error)

func (*ClbService) DescribeClbTargetGroupListByFilter

func (me *ClbService) DescribeClbTargetGroupListByFilter(ctx context.Context, param map[string]interface{}) (targetGroupList []*clb.TargetGroupInfo, errRet error)

func (*ClbService) DescribeClbTargetHealthByFilter

func (me *ClbService) DescribeClbTargetHealthByFilter(ctx context.Context, param map[string]interface{}) (targetHealth []*clb.LoadBalancerHealth, errRet error)

func (*ClbService) DescribeDescribeCustomizedConfigAssociateListById added in v1.81.169

func (me *ClbService) DescribeDescribeCustomizedConfigAssociateListById(ctx context.Context, configId string) (bindList []*clbintl.BindDetailItem, errRet error)

func (*ClbService) DescribeLbCustomizedConfigById

func (me *ClbService) DescribeLbCustomizedConfigById(ctx context.Context, configId, configType string) (customizedConfig *clb.ConfigListItem, errRet error)

func (*ClbService) DescribeLbIntlCustomizedConfigById added in v1.82.45

func (me *ClbService) DescribeLbIntlCustomizedConfigById(ctx context.Context, configId, configType string) (customizedConfig *clbintl.ConfigListItem, errRet error)

func (*ClbService) DescribeListenerById

func (me *ClbService) DescribeListenerById(ctx context.Context, listenerId string, clbId string) (clbListener *clb.Listener, errRet error)

func (*ClbService) DescribeListenersByFilter

func (me *ClbService) DescribeListenersByFilter(ctx context.Context, params map[string]interface{}) (listeners []*clb.Listener, errRet error)

func (*ClbService) DescribeLoadBalancerByFilter

func (me *ClbService) DescribeLoadBalancerByFilter(ctx context.Context, params map[string]interface{}) (clbs []*clb.LoadBalancer, errRet error)

func (*ClbService) DescribeLoadBalancerById

func (me *ClbService) DescribeLoadBalancerById(ctx context.Context, clbId string) (clbInstance *clb.LoadBalancer, errRet error)

func (*ClbService) DescribeRedirectionById

func (me *ClbService) DescribeRedirectionById(ctx context.Context, rewriteId string) (rewriteInfo *RedirectionInfo, errRet error)

func (*ClbService) DescribeRedirectionsByFilter

func (me *ClbService) DescribeRedirectionsByFilter(ctx context.Context, params map[string]string) (rewriteInfos []*map[string]string, errRet error)

func (*ClbService) DescribeRuleByPara

func (me *ClbService) DescribeRuleByPara(ctx context.Context, clbId string, listenerId string, domain string, url string, domains []*string) (clbRule *clb.RuleOutput, errRet error)

func (*ClbService) DescribeRulesByFilter

func (me *ClbService) DescribeRulesByFilter(ctx context.Context, params map[string]string) (rules []*clb.RuleOutput, errRet error)

func (*ClbService) DescribeTargetGroupInstances

func (me *ClbService) DescribeTargetGroupInstances(ctx context.Context, filters map[string]string) (targetGroupInstances []*clb.TargetGroupBackend, errRet error)

func (*ClbService) DescribeTargetGroupList added in v1.82.75

func (me *ClbService) DescribeTargetGroupList(ctx context.Context, targetGroupId string, filters map[string]string) (targetGroupInfos []*clb.TargetGroupInfo, errRet error)

func (*ClbService) DescribeTargetGroups

func (me *ClbService) DescribeTargetGroups(ctx context.Context, targetGroupId string, filters map[string]string) (targetGroupInfos []*clb.TargetGroupInfo, errRet error)

func (*ClbService) DescribeTargetsByPara added in v1.81.117

func (me *ClbService) DescribeTargetsByPara(ctx context.Context, clbId, listenerId, locationId string) (clbAttachment *clb.ListenerBackend, errRet error)

func (*ClbService) DescribeTaskStatusById

func (me *ClbService) DescribeTaskStatusById(ctx context.Context, taskId string) (status int64, errRet error)

func (*ClbService) DisassociateTargetGroups

func (me *ClbService) DisassociateTargetGroups(ctx context.Context, targetGroupId, listenerId, clbId, locationId string) (errRet error)

func (*ClbService) ModifyTargetGroup

func (me *ClbService) ModifyTargetGroup(ctx context.Context, targetGroupId, targetGroupName string, port uint64) (err error)

func (*ClbService) ModifyTargetGroupAttribute added in v1.82.74

func (me *ClbService) ModifyTargetGroupAttribute(ctx context.Context, request *clb.ModifyTargetGroupAttributeRequest) (err error)

func (*ClbService) ModifyTargetGroupInstancesPort

func (me *ClbService) ModifyTargetGroupInstancesPort(ctx context.Context, targetGroupId, bindIp string, port, weight uint64) (errRet error)

func (*ClbService) ModifyTargetGroupInstancesWeight

func (me *ClbService) ModifyTargetGroupInstancesWeight(ctx context.Context, targetGroupId, bindIp string, port, weight uint64) (errRet error)

func (*ClbService) ModifyTargetPort

func (me *ClbService) ModifyTargetPort(ctx context.Context, loadBalancerId, listenerId string, target clb.Target, newPort int64) (errRet error)

not use

func (*ClbService) ModifyTargetWeight

func (me *ClbService) ModifyTargetWeight(ctx context.Context, loadBalancerId, listenerId string, target clb.Target, weight int64) (errRet error)

not use

func (*ClbService) RegisterTargetInstances

func (me *ClbService) RegisterTargetInstances(ctx context.Context, targetGroupId, bindIp string, port, weight uint64) (err error)

func (*ClbService) SetClbSecurityGroup

func (me *ClbService) SetClbSecurityGroup(ctx context.Context, securityGroup string, lbId string, operation string) (errRet error)

func (*ClbService) UpdateClsLogSet

func (me *ClbService) UpdateClsLogSet(ctx context.Context, request *cls.ModifyLogsetRequest) (errRet error)

type RedirectionInfo added in v1.82.90

type RedirectionInfo struct {
	SourceRuleId     string
	TargetRuleId     string
	SourceListenerId string
	TargetListenerId string
	ClbId            string
	RewriteCode      *int64
	TakeUrl          *bool
	SourceDomain     string
}

RedirectionInfo holds the full information of a CLB redirection rule, including non-string fields RewriteCode (*int64) and TakeUrl (*bool).

Source Files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL