Fugue.AWS.ELBv2.TargetGroup

Module Members

external

(Function)

Create a reference to an externally managed TargetGroup

Example usage:

targetGroup: ELBv2.TargetGroup.external("arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/my-targets/73e2d6bc24d8a067")

Type Signature

 fun (String) -> TargetGroup
Argument: arn

The ARN of an existing TargetGroup.

Type: String

Returns:

A reference to the specified TargetGroup

Type: TargetGroup

new

(Function)

new TargetGroup (Constructor)

Example usage:

myTargetGroup: ELBv2.TargetGroup.new {
  name: "myTargetGroup",
  protocol: ELBv2.HTTP,
  port: 8080,
  vpc: myVpc,
}

Type Signature

 fun { name: String,
       protocol: Protocol,
       port: Int,
       healthCheckIntervalSeconds: Optional<Int>,
       healthCheckPath: Optional<String>,
       healthCheckPort: Optional<Int>,
       healthCheckProtocol: Optional<Protocol>,
       healthCheckTimeoutSeconds: Optional<Int>,
       healthyThresholdCount: Optional<Int>,
       unhealthyThresholdCount: Optional<Int>,
       matcher: Optional<Matcher>,
       deregistrationDelayTimeoutSeconds: Optional<Int>,
       stickiness: Optional<Stickiness>,
       vpc: Vpc,
       targetType: Optional<TargetType>,
       targets: Optional<List<Target>>,
       tags: Optional<List<Tag>>,
       resourceId: Optional<String> } -> TargetGroup
Argument: name

The name of the target group. Up to 32 characters consisting of letters, numbers, and ‘-‘. Must not begin or end with a ‘-‘. Must be unique per region and per account.

Type: String

Argument: protocol

The protocol to use when forwarding traffic to targets.

Type: Protocol

Argument: port

The target port to send traffic to. Must be between 1 and 65535. May be overridden on a per-target basis.

Type: Int

Argument: healthCheckIntervalSeconds

Approximate number of seconds between health checks for each target. Must be between 5 and 300. Defaults to 30. Mutable.

Type: Optional<Int>

Argument: healthCheckPath

The HTTP path to use for health checks. Must be less then 1024 characters. Defaults to "/". Mutable.

Type: Optional<String>

Argument: healthCheckPort

The port to send health checks to. Defaults to None, which uses the port the target receives forwarded traffic on. Mutable.

Type: Optional<Int>

Argument: healthCheckProtocol

The protocol to use for health checks. Defaults to ELBv2.HTTP. Mutable.

Type: Optional<Protocol>

Argument: healthCheckTimeoutSeconds

The number of seconds to allow a target to respond to a health check. Must be between 2 and 60. Defaults to 5. Mutable.

Type: Optional<Int>

Argument: healthyThresholdCount

The number of consecutive health checks that must be successful before an unhealthy target is marked as healthy. Must be between 2 and 10. Defaults to 5. Mutable.

Type: Optional<Int>

Argument: unhealthyThresholdCount

The number of consecutive health checks that must fail before a target is marked as unhealthy. Must be between 2 and 10. Defaults to 2. Mutable.

Type: Optional<Int>

Argument: matcher

Determines which HTTP codes signal a successful response from a target. See Matcher for functions to declare matchers. Defaults to ELBv2.Matcher.httpCodes {codes: [200]}. Mutable.

Type: Optional<Matcher>

Argument: deregistrationDelayTimeoutSeconds

Delay before deregistering a target in seconds. Must be between 0 and 3600. Defaults to 300. Mutable.

Type: Optional<Int>

Argument: stickiness

Enables sticky sessions. See Stickiness for functions to declare stickiness policies. Defaults to None, which disables sticky sessions. Mutable.

Type: Optional<Stickiness>

Argument: vpc

The VPC in which to create the target group.

Type: Vpc

Argument: targetType

The type of targets for this group. Can be either ELBv2.InstanceTargetType or ELBv2.IpTargetType. The target group can only have targets of this specified type. Default is ELBv2.InstanceTargetType.

Type: Optional<TargetType>

Argument: targets

A list of targets to forward traffic to. Targets may also be added dynamically by auto scaling groups and ECS services. Target types must match the type specified in the targetType field. Mutable.

@tags The list of tags to assign to the target group. Mutable.

Type: Optional<List<Target>>

Argument: tags
Type: Optional<List<Tag>>
Argument: resourceId

Resource ID of the resource to import with Fugue Import. This field is only honored on fugue run. The resource ID is the ARN. Mutable. Example: arn:aws:elasticloadbalancing:us-east-1:123456789012:targetgroup/my-targets/73e2d6bc24d8a067

Type: Optional<String>

Returns:

A new Fugue.Core.AWS.ELBv2.TargetGroup value.

Type: TargetGroup

region

(Function)

Retrieve the region from a TargetGroup value.

Works for TargetGroups defined in compositions as well as external values.

Example usage:

myVpc: EC2.Vpc.new {
  region: AWS.Us-east-2,
  cidrBlock: "10.0.0.0/16",
}

myTargetGroup: ELBv2.TargetGroup.new {
  name: "myTargetGroup",
  protocol: ELBv2.HTTP,
  port: 8080,
  vpc: myVpc,
}

region: ELBv2.TargetGroup.region(myTargetGroup) # => AWS.Us-east-2

Type Signature

 fun (TargetGroup) -> Region
Argument: targetGroup

The target group from which to get the region.

Type: TargetGroup

Returns:

The region containing the target group.

Type: Region