Class: TencentCloud::Clb::V20180317::RsWeightRule

Inherits:
TencentCloud::Common::AbstractModel
  • Object
show all
Extended by:
Gem::Deprecate
Defined in:
lib/v20180317/models.rb

Overview

修改节点权重的数据类型

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(listenerid = nil, targets = nil, locationid = nil, domain = nil, url = nil, weight = nil) ⇒ RsWeightRule

Returns a new instance of RsWeightRule.



7635
7636
7637
7638
7639
7640
7641
7642
# File 'lib/v20180317/models.rb', line 7635

def initialize(listenerid=nil, targets=nil, locationid=nil, domain=nil, url=nil, weight=nil)
  @ListenerId = listenerid
  @Targets = targets
  @LocationId = locationid
  @Domain = domain
  @Url = url
  @Weight = weight
end

Instance Attribute Details

#DomainObject

Parameters:

  • ListenerId:

    负载均衡监听器 ID。

  • Targets:

    要修改权重的后端机器列表。

  • LocationId:

    转发规则的ID,七层规则时需要此参数,4层规则不需要。

  • Domain:

    目标规则的域名,提供LocationId参数时本参数不生效。

  • Url:

    目标规则的URL,提供LocationId参数时本参数不生效。

  • Weight:

    后端服务修改后的转发权重,取值范围:此参数的优先级低于前述(cloud.tencent.com/document/api/214/30694#Target)中的Weight参数,即最终的权重值以Target中的Weight参数值为准,仅当Target中的Weight参数为空时,才以RsWeightRule中的Weight参数为准。



7628
7629
7630
# File 'lib/v20180317/models.rb', line 7628

def Domain
  @Domain
end

#ListenerIdObject

Parameters:

  • ListenerId:

    负载均衡监听器 ID。

  • Targets:

    要修改权重的后端机器列表。

  • LocationId:

    转发规则的ID,七层规则时需要此参数,4层规则不需要。

  • Domain:

    目标规则的域名,提供LocationId参数时本参数不生效。

  • Url:

    目标规则的URL,提供LocationId参数时本参数不生效。

  • Weight:

    后端服务修改后的转发权重,取值范围:此参数的优先级低于前述(cloud.tencent.com/document/api/214/30694#Target)中的Weight参数,即最终的权重值以Target中的Weight参数值为准,仅当Target中的Weight参数为空时,才以RsWeightRule中的Weight参数为准。



7628
7629
7630
# File 'lib/v20180317/models.rb', line 7628

def ListenerId
  @ListenerId
end

#LocationIdObject

Parameters:

  • ListenerId:

    负载均衡监听器 ID。

  • Targets:

    要修改权重的后端机器列表。

  • LocationId:

    转发规则的ID,七层规则时需要此参数,4层规则不需要。

  • Domain:

    目标规则的域名,提供LocationId参数时本参数不生效。

  • Url:

    目标规则的URL,提供LocationId参数时本参数不生效。

  • Weight:

    后端服务修改后的转发权重,取值范围:此参数的优先级低于前述(cloud.tencent.com/document/api/214/30694#Target)中的Weight参数,即最终的权重值以Target中的Weight参数值为准,仅当Target中的Weight参数为空时,才以RsWeightRule中的Weight参数为准。



7628
7629
7630
# File 'lib/v20180317/models.rb', line 7628

def LocationId
  @LocationId
end

#TargetsObject

Parameters:

  • ListenerId:

    负载均衡监听器 ID。

  • Targets:

    要修改权重的后端机器列表。

  • LocationId:

    转发规则的ID,七层规则时需要此参数,4层规则不需要。

  • Domain:

    目标规则的域名,提供LocationId参数时本参数不生效。

  • Url:

    目标规则的URL,提供LocationId参数时本参数不生效。

  • Weight:

    后端服务修改后的转发权重,取值范围:此参数的优先级低于前述(cloud.tencent.com/document/api/214/30694#Target)中的Weight参数,即最终的权重值以Target中的Weight参数值为准,仅当Target中的Weight参数为空时,才以RsWeightRule中的Weight参数为准。



7628
7629
7630
# File 'lib/v20180317/models.rb', line 7628

def Targets
  @Targets
end

#UrlObject

Parameters:

  • ListenerId:

    负载均衡监听器 ID。

  • Targets:

    要修改权重的后端机器列表。

  • LocationId:

    转发规则的ID,七层规则时需要此参数,4层规则不需要。

  • Domain:

    目标规则的域名,提供LocationId参数时本参数不生效。

  • Url:

    目标规则的URL,提供LocationId参数时本参数不生效。

  • Weight:

    后端服务修改后的转发权重,取值范围:此参数的优先级低于前述(cloud.tencent.com/document/api/214/30694#Target)中的Weight参数,即最终的权重值以Target中的Weight参数值为准,仅当Target中的Weight参数为空时,才以RsWeightRule中的Weight参数为准。



7628
7629
7630
# File 'lib/v20180317/models.rb', line 7628

def Url
  @Url
end

#WeightObject

Parameters:

  • ListenerId:

    负载均衡监听器 ID。

  • Targets:

    要修改权重的后端机器列表。

  • LocationId:

    转发规则的ID,七层规则时需要此参数,4层规则不需要。

  • Domain:

    目标规则的域名,提供LocationId参数时本参数不生效。

  • Url:

    目标规则的URL,提供LocationId参数时本参数不生效。

  • Weight:

    后端服务修改后的转发权重,取值范围:此参数的优先级低于前述(cloud.tencent.com/document/api/214/30694#Target)中的Weight参数,即最终的权重值以Target中的Weight参数值为准,仅当Target中的Weight参数为空时,才以RsWeightRule中的Weight参数为准。



7628
7629
7630
# File 'lib/v20180317/models.rb', line 7628

def Weight
  @Weight
end

Instance Method Details

#deserialize(params) ⇒ Object



7644
7645
7646
7647
7648
7649
7650
7651
7652
7653
7654
7655
7656
7657
7658
# File 'lib/v20180317/models.rb', line 7644

def deserialize(params)
  @ListenerId = params['ListenerId']
  unless params['Targets'].nil?
    @Targets = []
    params['Targets'].each do |i|
      target_tmp = Target.new
      target_tmp.deserialize(i)
      @Targets << target_tmp
    end
  end
  @LocationId = params['LocationId']
  @Domain = params['Domain']
  @Url = params['Url']
  @Weight = params['Weight']
end