amazonka-elbv2-1.5.0: Amazon Elastic Load Balancing SDK.

Copyright(c) 2013-2017 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.ELBv2.CreateTargetGroup

Contents

Description

Creates a target group.

To register targets with the target group, use RegisterTargets . To update the health check settings for the target group, use ModifyTargetGroup . To monitor the health of targets in the target group, use DescribeTargetHealth .

To route traffic to the targets in a target group, specify the target group in an action using CreateListener or CreateRule .

To delete a target group, use DeleteTargetGroup .

This operation is idempotent, which means that it completes at most one time. If you attempt to create multiple target groups with the same settings, each call succeeds.

For more information, see Target Groups for Your Application Load Balancers in the Application Load Balancers Guide or Target Groups for Your Network Load Balancers in the Network Load Balancers Guide .

Synopsis

Creating a Request

createTargetGroup Source #

Creates a value of CreateTargetGroup with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • ctgMatcher - [HTTP/HTTPS health checks] The HTTP codes to use when checking for a successful response from a target.
  • ctgHealthCheckPath - [HTTPHTTPS health checks] The ping path that is the destination on the targets for health checks. The default is .
  • ctgUnhealthyThresholdCount - The number of consecutive health check failures required before considering a target unhealthy. For Application Load Balancers, the default is 2. For Network Load Balancers, this value must be the same as the healthy threshold count.
  • ctgHealthCheckIntervalSeconds - The approximate amount of time, in seconds, between health checks of an individual target. For Application Load Balancers, the range is 5 to 300 seconds. For Network Load Balancers, the supported values are 10 or 30 seconds. The default is 30 seconds.
  • ctgTargetType - The type of target that you must specify when registering targets with this target group. The possible values are instance (targets are specified by instance ID) or ip (targets are specified by IP address). The default is instance . Note that you can't specify targets for a target group using both instance IDs and IP addresses. If the target type is ip , specify IP addresses from the subnets of the virtual private cloud (VPC) for the target group, the RFC 1918 range (10.0.0.08, 172.16.0.012, and 192.168.0.016), and the RFC 6598 range (100.64.0.010). You can't specify publicly routable IP addresses.
  • ctgHealthyThresholdCount - The number of consecutive health checks successes required before considering an unhealthy target healthy. For Application Load Balancers, the default is 5. For Network Load Balancers, the default is 3.
  • ctgHealthCheckProtocol - The protocol the load balancer uses when performing health checks on targets. The TCP protocol is supported only if the protocol of the target group is TCP. For Application Load Balancers, the default is HTTP. For Network Load Balancers, the default is TCP.
  • ctgHealthCheckTimeoutSeconds - The amount of time, in seconds, during which no response from a target means a failed health check. For Application Load Balancers, the range is 2 to 60 seconds and the default is 5 seconds. For Network Load Balancers, this is 10 seconds for TCP and HTTPS health checks and 6 seconds for HTTP health checks.
  • ctgHealthCheckPort - The port the load balancer uses when performing health checks on targets. The default is traffic-port , which is the port on which each target receives traffic from the load balancer.
  • ctgName - The name of the target group. This name must be unique per region per account, can have a maximum of 32 characters, must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.
  • ctgProtocol - The protocol to use for routing traffic to the targets. For Application Load Balancers, the supported protocols are HTTP and HTTPS. For Network Load Balancers, the supported protocol is TCP.
  • ctgPort - The port on which the targets receive traffic. This port is used unless you specify a port override when registering the target.
  • ctgVPCId - The identifier of the virtual private cloud (VPC).

data CreateTargetGroup Source #

See: createTargetGroup smart constructor.

Instances

Eq CreateTargetGroup Source # 
Data CreateTargetGroup Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CreateTargetGroup -> c CreateTargetGroup #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c CreateTargetGroup #

toConstr :: CreateTargetGroup -> Constr #

dataTypeOf :: CreateTargetGroup -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c CreateTargetGroup) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c CreateTargetGroup) #

gmapT :: (forall b. Data b => b -> b) -> CreateTargetGroup -> CreateTargetGroup #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CreateTargetGroup -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CreateTargetGroup -> r #

gmapQ :: (forall d. Data d => d -> u) -> CreateTargetGroup -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> CreateTargetGroup -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> CreateTargetGroup -> m CreateTargetGroup #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateTargetGroup -> m CreateTargetGroup #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateTargetGroup -> m CreateTargetGroup #

Read CreateTargetGroup Source # 
Show CreateTargetGroup Source # 
Generic CreateTargetGroup Source # 
Hashable CreateTargetGroup Source # 
NFData CreateTargetGroup Source # 

Methods

rnf :: CreateTargetGroup -> () #

AWSRequest CreateTargetGroup Source # 
ToQuery CreateTargetGroup Source # 
ToPath CreateTargetGroup Source # 
ToHeaders CreateTargetGroup Source # 
type Rep CreateTargetGroup Source # 
type Rep CreateTargetGroup = D1 (MetaData "CreateTargetGroup" "Network.AWS.ELBv2.CreateTargetGroup" "amazonka-elbv2-1.5.0-8JFLFpIxDmMIkmtukHsD5H" False) (C1 (MetaCons "CreateTargetGroup'" PrefixI True) ((:*:) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_ctgMatcher") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Matcher))) ((:*:) (S1 (MetaSel (Just Symbol "_ctgHealthCheckPath") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) (S1 (MetaSel (Just Symbol "_ctgUnhealthyThresholdCount") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Nat))))) ((:*:) (S1 (MetaSel (Just Symbol "_ctgHealthCheckIntervalSeconds") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Nat))) ((:*:) (S1 (MetaSel (Just Symbol "_ctgTargetType") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe TargetTypeEnum))) (S1 (MetaSel (Just Symbol "_ctgHealthyThresholdCount") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Nat)))))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_ctgHealthCheckProtocol") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe ProtocolEnum))) ((:*:) (S1 (MetaSel (Just Symbol "_ctgHealthCheckTimeoutSeconds") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Nat))) (S1 (MetaSel (Just Symbol "_ctgHealthCheckPort") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))))) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_ctgName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) (S1 (MetaSel (Just Symbol "_ctgProtocol") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 ProtocolEnum))) ((:*:) (S1 (MetaSel (Just Symbol "_ctgPort") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Nat)) (S1 (MetaSel (Just Symbol "_ctgVPCId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)))))))
type Rs CreateTargetGroup Source # 

Request Lenses

ctgMatcher :: Lens' CreateTargetGroup (Maybe Matcher) Source #

HTTP/HTTPS health checks
The HTTP codes to use when checking for a successful response from a target.

ctgHealthCheckPath :: Lens' CreateTargetGroup (Maybe Text) Source #

HTTP/HTTPS health checks
The ping path that is the destination on the targets for health checks. The default is /.

ctgUnhealthyThresholdCount :: Lens' CreateTargetGroup (Maybe Natural) Source #

The number of consecutive health check failures required before considering a target unhealthy. For Application Load Balancers, the default is 2. For Network Load Balancers, this value must be the same as the healthy threshold count.

ctgHealthCheckIntervalSeconds :: Lens' CreateTargetGroup (Maybe Natural) Source #

The approximate amount of time, in seconds, between health checks of an individual target. For Application Load Balancers, the range is 5 to 300 seconds. For Network Load Balancers, the supported values are 10 or 30 seconds. The default is 30 seconds.

ctgTargetType :: Lens' CreateTargetGroup (Maybe TargetTypeEnum) Source #

The type of target that you must specify when registering targets with this target group. The possible values are instance (targets are specified by instance ID) or ip (targets are specified by IP address). The default is instance . Note that you can't specify targets for a target group using both instance IDs and IP addresses. If the target type is ip , specify IP addresses from the subnets of the virtual private cloud (VPC) for the target group, the RFC 1918 range (10.0.0.08, 172.16.0.012, and 192.168.0.016), and the RFC 6598 range (100.64.0.010). You can't specify publicly routable IP addresses.

ctgHealthyThresholdCount :: Lens' CreateTargetGroup (Maybe Natural) Source #

The number of consecutive health checks successes required before considering an unhealthy target healthy. For Application Load Balancers, the default is 5. For Network Load Balancers, the default is 3.

ctgHealthCheckProtocol :: Lens' CreateTargetGroup (Maybe ProtocolEnum) Source #

The protocol the load balancer uses when performing health checks on targets. The TCP protocol is supported only if the protocol of the target group is TCP. For Application Load Balancers, the default is HTTP. For Network Load Balancers, the default is TCP.

ctgHealthCheckTimeoutSeconds :: Lens' CreateTargetGroup (Maybe Natural) Source #

The amount of time, in seconds, during which no response from a target means a failed health check. For Application Load Balancers, the range is 2 to 60 seconds and the default is 5 seconds. For Network Load Balancers, this is 10 seconds for TCP and HTTPS health checks and 6 seconds for HTTP health checks.

ctgHealthCheckPort :: Lens' CreateTargetGroup (Maybe Text) Source #

The port the load balancer uses when performing health checks on targets. The default is traffic-port , which is the port on which each target receives traffic from the load balancer.

ctgName :: Lens' CreateTargetGroup Text Source #

The name of the target group. This name must be unique per region per account, can have a maximum of 32 characters, must contain only alphanumeric characters or hyphens, and must not begin or end with a hyphen.

ctgProtocol :: Lens' CreateTargetGroup ProtocolEnum Source #

The protocol to use for routing traffic to the targets. For Application Load Balancers, the supported protocols are HTTP and HTTPS. For Network Load Balancers, the supported protocol is TCP.

ctgPort :: Lens' CreateTargetGroup Natural Source #

The port on which the targets receive traffic. This port is used unless you specify a port override when registering the target.

ctgVPCId :: Lens' CreateTargetGroup Text Source #

The identifier of the virtual private cloud (VPC).

Destructuring the Response

createTargetGroupResponse Source #

Creates a value of CreateTargetGroupResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data CreateTargetGroupResponse Source #

See: createTargetGroupResponse smart constructor.

Instances

Eq CreateTargetGroupResponse Source # 
Data CreateTargetGroupResponse Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CreateTargetGroupResponse -> c CreateTargetGroupResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c CreateTargetGroupResponse #

toConstr :: CreateTargetGroupResponse -> Constr #

dataTypeOf :: CreateTargetGroupResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c CreateTargetGroupResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c CreateTargetGroupResponse) #

gmapT :: (forall b. Data b => b -> b) -> CreateTargetGroupResponse -> CreateTargetGroupResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CreateTargetGroupResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CreateTargetGroupResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> CreateTargetGroupResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> CreateTargetGroupResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> CreateTargetGroupResponse -> m CreateTargetGroupResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateTargetGroupResponse -> m CreateTargetGroupResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateTargetGroupResponse -> m CreateTargetGroupResponse #

Read CreateTargetGroupResponse Source # 
Show CreateTargetGroupResponse Source # 
Generic CreateTargetGroupResponse Source # 
NFData CreateTargetGroupResponse Source # 
type Rep CreateTargetGroupResponse Source # 
type Rep CreateTargetGroupResponse = D1 (MetaData "CreateTargetGroupResponse" "Network.AWS.ELBv2.CreateTargetGroup" "amazonka-elbv2-1.5.0-8JFLFpIxDmMIkmtukHsD5H" False) (C1 (MetaCons "CreateTargetGroupResponse'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_ctgrsTargetGroups") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe [TargetGroup]))) (S1 (MetaSel (Just Symbol "_ctgrsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Int))))

Response Lenses

ctgrsTargetGroups :: Lens' CreateTargetGroupResponse [TargetGroup] Source #

Information about the target group.