Skip to content

Rule

This class encapsulates and extends the ROS resource type DATASOURCE::SLB::Rule.

Initializers

import { datasource } from '@alicloud/ros-cdk-slb'
new datasource.Rule(scope: Construct, id: string, props: RuleProps, enableResourcePropertyConstraint?: boolean)
Name Type Description
scope @alicloud/ros-cdk-core.Construct No description.
id string No description.
props RuleProps No description.
enableResourcePropertyConstraint boolean No description.

scopeRequired

  • Type: @alicloud/ros-cdk-core.Construct

idRequired

  • Type: string

propsRequired


enableResourcePropertyConstraintOptional

  • Type: boolean

Methods

Name Description
toString Returns a string representation of this construct.
synthesize Allows this construct to emit artifacts into the cloud assembly during synthesis.
addCondition No description.
addCount No description.
addDependency No description.
addResourceDesc No description.
applyRemovalPolicy No description.
getAtt No description.
setMetadata No description.

toString

public toString(): string

Returns a string representation of this construct.

synthesize

public synthesize(session: ISynthesisSession): void

Allows this construct to emit artifacts into the cloud assembly during synthesis.

This method is usually implemented by framework-level constructs such as Stack and Asset as they participate in synthesizing the cloud assembly.

sessionRequired

  • Type: @alicloud/ros-cdk-core.ISynthesisSession

The synthesis session.


addCondition

public addCondition(condition: RosCondition): void

conditionRequired

  • Type: @alicloud/ros-cdk-core.RosCondition

addCount

public addCount(count: number | IResolvable): void

countRequired

  • Type: number | @alicloud/ros-cdk-core.IResolvable

addDependency

public addDependency(resource: Resource): void

resourceRequired

  • Type: @alicloud/ros-cdk-core.Resource

addResourceDesc

public addResourceDesc(desc: string): void

descRequired

  • Type: string

applyRemovalPolicy

public applyRemovalPolicy(policy: RemovalPolicy): void

policyRequired

  • Type: @alicloud/ros-cdk-core.RemovalPolicy

getAtt

public getAtt(name: string): IResolvable

nameRequired

  • Type: string

setMetadata

public setMetadata(key: string, value: any): void

keyRequired

  • Type: string

valueRequired

  • Type: any

Static Functions

Name Description
isConstruct Return whether the given object is a Construct.

isConstruct

import { datasource } from '@alicloud/ros-cdk-slb'
datasource.Rule.isConstruct(x: any)

Return whether the given object is a Construct.

xRequired

  • Type: any

Properties

Name Type Description
node @alicloud/ros-cdk-core.ConstructNode The construct tree node associated with this construct.
ref string No description.
stack @alicloud/ros-cdk-core.Stack The stack in which this resource is defined.
resource @alicloud/ros-cdk-core.RosResource No description.
attrCookie @alicloud/ros-cdk-core.IResolvable Attribute Cookie: The cookie to be configured on the backend server.
attrCookieTimeout @alicloud/ros-cdk-core.IResolvable Attribute CookieTimeout: The timeout period of a cookie.
attrDomain @alicloud/ros-cdk-core.IResolvable Attribute Domain: The domain name that is configured in the forwarding rule.
attrHealthCheck @alicloud/ros-cdk-core.IResolvable Attribute HealthCheck: Specifies whether to enable health checks.
attrHealthCheckConnectPort @alicloud/ros-cdk-core.IResolvable Attribute HealthCheckConnectPort: The port of the backend server that is used for health checks.
attrHealthCheckDomain @alicloud/ros-cdk-core.IResolvable Attribute HealthCheckDomain: The domain name that is used for health checks.
attrHealthCheckHttpCode @alicloud/ros-cdk-core.IResolvable Attribute HealthCheckHttpCode: The HTTP status code that indicates a successful health check.
attrHealthCheckInterval @alicloud/ros-cdk-core.IResolvable Attribute HealthCheckInterval: The time interval between two consecutive health checks.
attrHealthCheckTimeout @alicloud/ros-cdk-core.IResolvable Attribute HealthCheckTimeout: The timeout period of a health check response.
attrHealthCheckUri @alicloud/ros-cdk-core.IResolvable Attribute HealthCheckUri: The URI that is used for health checks.
attrHealthyThreshold @alicloud/ros-cdk-core.IResolvable Attribute HealthyThreshold: The number of consecutive successful health checks that must occur before an unhealthy backend server is declared healthy.
attrListenerPort @alicloud/ros-cdk-core.IResolvable Attribute ListenerPort: The listener port that is used by the SLB instance.
attrListenerSync @alicloud/ros-cdk-core.IResolvable Attribute ListenerSync: Indicates whether the forwarding rule uses the scheduling algorithm, session persistence, and health check configurations of the listener.
attrLoadBalancerId @alicloud/ros-cdk-core.IResolvable Attribute LoadBalancerId: The ID of the SLB instance.
attrRuleId @alicloud/ros-cdk-core.IResolvable Attribute RuleId: The ID of the forwarding rule.
attrRuleName @alicloud/ros-cdk-core.IResolvable Attribute RuleName: The name of the forwarding rule.
attrScheduler @alicloud/ros-cdk-core.IResolvable Attribute Scheduler: The scheduling algorithm.
attrStickySession @alicloud/ros-cdk-core.IResolvable Attribute StickySession: Indicates whether session persistence is enabled.
attrStickySessionType @alicloud/ros-cdk-core.IResolvable Attribute StickySessionType: The method that is used to handle a cookie.
attrUnhealthyThreshold @alicloud/ros-cdk-core.IResolvable Attribute UnhealthyThreshold: The number of consecutive failed health checks that must occur before a healthy backend server is declared unhealthy.
attrUrl @alicloud/ros-cdk-core.IResolvable Attribute Url: The URL that is configured in the forwarding rule.
attrVserverGroupId @alicloud/ros-cdk-core.IResolvable Attribute VserverGroupId: The ID of the vServer group that is associated with the forwarding rule.

nodeRequired

public readonly node: ConstructNode;
  • Type: @alicloud/ros-cdk-core.ConstructNode

The construct tree node associated with this construct.


refRequired

public readonly ref: string;
  • Type: string

stackRequired

public readonly stack: Stack;
  • Type: @alicloud/ros-cdk-core.Stack

The stack in which this resource is defined.


resourceOptional

public readonly resource: RosResource;
  • Type: @alicloud/ros-cdk-core.RosResource

attrCookieRequired

public readonly attrCookie: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute Cookie: The cookie to be configured on the backend server.


attrCookieTimeoutRequired

public readonly attrCookieTimeout: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute CookieTimeout: The timeout period of a cookie.


attrDomainRequired

public readonly attrDomain: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute Domain: The domain name that is configured in the forwarding rule.


attrHealthCheckRequired

public readonly attrHealthCheck: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthCheck: Specifies whether to enable health checks.


attrHealthCheckConnectPortRequired

public readonly attrHealthCheckConnectPort: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthCheckConnectPort: The port of the backend server that is used for health checks.

Valid values: 1 to 65535.


attrHealthCheckDomainRequired

public readonly attrHealthCheckDomain: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthCheckDomain: The domain name that is used for health checks.

Valid values: $_ip: The private IP address of the backend server. If the $_ip parameter is set or the HealthCheckDomain parameter is not set, SLB uses the private IP addresses of backend servers as the domain names for health checks. domain: The domain name must be 1 to 80 characters in length. It can contain only letters, digits, periods (.),and hyphens (-).


attrHealthCheckHttpCodeRequired

public readonly attrHealthCheckHttpCode: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthCheckHttpCode: The HTTP status code that indicates a successful health check.

Separate multiple HTTP status codes with commas (,). Default value: http_2xx.


attrHealthCheckIntervalRequired

public readonly attrHealthCheckInterval: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthCheckInterval: The time interval between two consecutive health checks.


attrHealthCheckTimeoutRequired

public readonly attrHealthCheckTimeout: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthCheckTimeout: The timeout period of a health check response.

If a backend ECS instance does not send an expected response within the specified period of time, the ECS instance is considered unhealthy.


attrHealthCheckUriRequired

public readonly attrHealthCheckUri: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthCheckUri: The URI that is used for health checks.


attrHealthyThresholdRequired

public readonly attrHealthyThreshold: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute HealthyThreshold: The number of consecutive successful health checks that must occur before an unhealthy backend server is declared healthy.

In this case, the health check state is changed from fail to success.


attrListenerPortRequired

public readonly attrListenerPort: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute ListenerPort: The listener port that is used by the SLB instance.


attrListenerSyncRequired

public readonly attrListenerSync: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute ListenerSync: Indicates whether the forwarding rule uses the scheduling algorithm, session persistence, and health check configurations of the listener.


attrLoadBalancerIdRequired

public readonly attrLoadBalancerId: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute LoadBalancerId: The ID of the SLB instance.


attrRuleIdRequired

public readonly attrRuleId: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute RuleId: The ID of the forwarding rule.


attrRuleNameRequired

public readonly attrRuleName: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute RuleName: The name of the forwarding rule.


attrSchedulerRequired

public readonly attrScheduler: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute Scheduler: The scheduling algorithm.


attrStickySessionRequired

public readonly attrStickySession: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute StickySession: Indicates whether session persistence is enabled.

Valid values: on and off.


attrStickySessionTypeRequired

public readonly attrStickySessionType: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute StickySessionType: The method that is used to handle a cookie.


attrUnhealthyThresholdRequired

public readonly attrUnhealthyThreshold: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute UnhealthyThreshold: The number of consecutive failed health checks that must occur before a healthy backend server is declared unhealthy.

In this case, the health check state is changed from success to fail.


attrUrlRequired

public readonly attrUrl: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute Url: The URL that is configured in the forwarding rule.


attrVserverGroupIdRequired

public readonly attrVserverGroupId: IResolvable;
  • Type: @alicloud/ros-cdk-core.IResolvable

Attribute VserverGroupId: The ID of the vServer group that is associated with the forwarding rule.