Class AddApplicationActionProps
Properties for adding a new action to a listener.
Inheritance
Namespace: Amazon.CDK.AWS.ElasticLoadBalancingV2
Assembly: Amazon.CDK.AWS.ElasticLoadBalancingV2.dll
Syntax (csharp)
public class AddApplicationActionProps : Object, IAddApplicationActionProps, IAddRuleProps
Syntax (vb)
Public Class AddApplicationActionProps
Inherits Object
Implements IAddApplicationActionProps, IAddRuleProps
Remarks
ExampleMetadata: infused
Examples
ApplicationListener listener;
listener.AddAction("Fixed", new AddApplicationActionProps {
Priority = 10,
Conditions = new [] { ListenerCondition.PathPatterns(new [] { "/ok" }) },
Action = ListenerAction.FixedResponse(200, new FixedResponseOptions {
ContentType = ContentType.TEXT_PLAIN,
MessageBody = "OK"
})
});
Synopsis
Constructors
AddApplicationActionProps() |
Properties
Action | Action to perform. |
Conditions | Rule applies if matches the conditions. |
HostHeader | (deprecated) Rule applies if the requested host matches the indicated host. |
PathPattern | (deprecated) Rule applies if the requested path matches the given path pattern. |
PathPatterns | (deprecated) Rule applies if the requested path matches any of the given patterns. |
Priority | Priority of this target group. |
Constructors
AddApplicationActionProps()
public AddApplicationActionProps()
Properties
Action
Conditions
Rule applies if matches the conditions.
public ListenerCondition[] Conditions { get; set; }
Property Value
Remarks
Default: - No conditions.
See: https://docs.aws.amazon.com/elasticloadbalancing/latest/application/load-balancer-listeners.html
HostHeader
(deprecated) Rule applies if the requested host matches the indicated host.
public string HostHeader { get; set; }
Property Value
System.String
Remarks
May contain up to three '*' wildcards.
Requires that priority is set.
Default: No host condition
Stability: Deprecated
PathPattern
(deprecated) Rule applies if the requested path matches the given path pattern.
public string PathPattern { get; set; }
Property Value
System.String
Remarks
May contain up to three '*' wildcards.
Requires that priority is set.
Default: No path condition
Stability: Deprecated
PathPatterns
(deprecated) Rule applies if the requested path matches any of the given patterns.
public string[] PathPatterns { get; set; }
Property Value
System.String[]
Remarks
May contain up to three '*' wildcards.
Requires that priority is set.
Default: - No path condition.
Stability: Deprecated
Priority
Priority of this target group.
public Nullable<double> Priority { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
The rule with the lowest priority will be used for every request. If priority is not given, these target groups will be added as defaults, and must not have conditions.
Priorities must be unique.
Default: Target groups are used as defaults