[aws-elasticloadbalancingv2] Imported listener conditions
attribute is ignored
#9643
Labels
@aws-cdk/aws-elasticloadbalancingv2
Related to Amazon Elastic Load Balancing V2
bug
This issue is a bug.
duplicate
This issue is a duplicate.
effort/small
Small work item – less than a day of effort
good first issue
Related to contributions. See CONTRIBUTING.md
p1
This bug is related to #8328, but instead occurs only to existing (imported) listeners.
When attempting to add a rule to an importer listener on an application load balancer, it is not possible to specify multiple conditions with the
addTargetGroups
helper, because it ignores the conditions array of the input.Workarounds:
hostHeader
Reproduction Steps
Check file application-listener.ts on release v1.57.0. Look for method
addTargetGroups
of classImportedApplicationListener
and you will note that aconditions
attribute is not passed tonew ApplicationListenerRule
:What did you expect to happen?
To properly use
conditions
attribute of a target group on existing listeners.What actually happened?
conditions
is ignored and if no other attribute (likehostHeader
) is provided it throws an error:At least one of 'conditions', 'hostHeader', 'pathPattern' or 'pathPatterns' is required when defining a load balancing rule.
.Environment
Other
This bug is related to #8328 and was probably left behind by #8385.
This is 🐛 Bug Report
The text was updated successfully, but these errors were encountered: