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

Copyright (c) 2013-2018 Brendan Hay Mozilla Public License, v. 2.0. Brendan Hay auto-generated non-portable (GHC extensions) None Haskell2010

Network.AWS.ELBv2.CreateRule

Description

Creates a rule for the specified listener. The listener must be associated with an Application Load Balancer.

Rules are evaluated in priority order, from the lowest value to the highest value. When the condition for a rule is met, the specified action is taken. If no conditions are met, the action for the default rule is taken. For more information, see Listener Rules in the Application Load Balancers Guide .

To view your current rules, use DescribeRules . To update a rule, use ModifyRule . To set the priorities of your rules, use SetRulePriorities . To delete a rule, use DeleteRule .

Synopsis

# Creating a Request

Arguments

 :: Text crListenerARN -> Natural crPriority -> CreateRule

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

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

• crListenerARN - The Amazon Resource Name (ARN) of the listener.
• crConditions - The conditions. Each condition specifies a field name and a single value. If the field name is host-header , you can specify a single host name (for example, my.example.com). A host name is case insensitive, can be up to 128 characters in length, and can contain any of the following characters. Note that you can include up to three wildcard characters. * A-Z, a-z, 0-9 * - . * * (matches 0 or more characters) * ? (matches exactly 1 character) If the field name is path-pattern , you can specify a single path pattern. A path pattern is case sensitive, can be up to 128 characters in length, and can contain any of the following characters. Note that you can include up to three wildcard characters. * A-Z, a-z, 0-9 * _ - . $/ ~ " ' @ : + * & (using &amp;) * * (matches 0 or more characters) * ? (matches exactly 1 character) • crPriority - The priority for the rule. A listener can't have multiple rules with the same priority. • crActions - An action. Each action has the type forward and specifies a target group. See: createRule smart constructor. Instances  Source # Methods Source # Methodsgfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CreateRule -> c CreateRule #gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c CreateRule #dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c CreateRule) #dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c CreateRule) #gmapT :: (forall b. Data b => b -> b) -> CreateRule -> CreateRule #gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CreateRule -> r #gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CreateRule -> r #gmapQ :: (forall d. Data d => d -> u) -> CreateRule -> [u] #gmapQi :: Int -> (forall d. Data d => d -> u) -> CreateRule -> u #gmapM :: Monad m => (forall d. Data d => d -> m d) -> CreateRule -> m CreateRule #gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateRule -> m CreateRule #gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateRule -> m CreateRule # Source # Methods Source # MethodsshowList :: [CreateRule] -> ShowS # Source # Associated Typestype Rep CreateRule :: * -> * # Methods Source # Methods Source # Methodsrnf :: CreateRule -> () # Source # Associated Typestype Rs CreateRule :: * # Methodsresponse :: (MonadResource m, MonadThrow m) => Logger -> Service -> Proxy * CreateRule -> ClientResponse -> m (Response CreateRule) # Source # MethodstoHeaders :: CreateRule -> [Header] # Source # Methods Source # Methods type Rep CreateRule Source # type Rep CreateRule = D1 * (MetaData "CreateRule" "Network.AWS.ELBv2.CreateRule" "amazonka-elbv2-1.6.0-BDuuMSavAm89hMa3xHwuj" False) (C1 * (MetaCons "CreateRule'" PrefixI True) ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "_crListenerARN") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text)) (S1 * (MetaSel (Just Symbol "_crConditions") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * [RuleCondition]))) ((:*:) * (S1 * (MetaSel (Just Symbol "_crPriority") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Nat)) (S1 * (MetaSel (Just Symbol "_crActions") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * [Action]))))) type Rs CreateRule Source # # Request Lenses The Amazon Resource Name (ARN) of the listener. The conditions. Each condition specifies a field name and a single value. If the field name is host-header , you can specify a single host name (for example, my.example.com). A host name is case insensitive, can be up to 128 characters in length, and can contain any of the following characters. Note that you can include up to three wildcard characters. * A-Z, a-z, 0-9 * - . * * (matches 0 or more characters) * ? (matches exactly 1 character) If the field name is path-pattern , you can specify a single path pattern. A path pattern is case sensitive, can be up to 128 characters in length, and can contain any of the following characters. Note that you can include up to three wildcard characters. * A-Z, a-z, 0-9 * _ - .$ / ~ " ' @ : + * & (using &amp;) * * (matches 0 or more characters) * ? (matches exactly 1 character)

The priority for the rule. A listener can't have multiple rules with the same priority.

An action. Each action has the type forward and specifies a target group.

# Destructuring the Response

Arguments

 :: Int crrsResponseStatus -> CreateRuleResponse

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

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

• crrsRules - Information about the rule.
• crrsResponseStatus - -- | The response status code.

See: createRuleResponse smart constructor.

Instances

 Source # Methods Source # Methodsgfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> CreateRuleResponse -> c CreateRuleResponse #gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c CreateRuleResponse #dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c CreateRuleResponse) #dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c CreateRuleResponse) #gmapT :: (forall b. Data b => b -> b) -> CreateRuleResponse -> CreateRuleResponse #gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> CreateRuleResponse -> r #gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> CreateRuleResponse -> r #gmapQ :: (forall d. Data d => d -> u) -> CreateRuleResponse -> [u] #gmapQi :: Int -> (forall d. Data d => d -> u) -> CreateRuleResponse -> u #gmapM :: Monad m => (forall d. Data d => d -> m d) -> CreateRuleResponse -> m CreateRuleResponse #gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateRuleResponse -> m CreateRuleResponse #gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> CreateRuleResponse -> m CreateRuleResponse # Source # Methods Source # MethodsshowList :: [CreateRuleResponse] -> ShowS # Source # Associated Typestype Rep CreateRuleResponse :: * -> * # Methods Source # Methodsrnf :: CreateRuleResponse -> () # Source # type Rep CreateRuleResponse = D1 * (MetaData "CreateRuleResponse" "Network.AWS.ELBv2.CreateRule" "amazonka-elbv2-1.6.0-BDuuMSavAm89hMa3xHwuj" False) (C1 * (MetaCons "CreateRuleResponse'" PrefixI True) ((:*:) * (S1 * (MetaSel (Just Symbol "_crrsRules") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe [Rule]))) (S1 * (MetaSel (Just Symbol "_crrsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Int))))