Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

elbv2: NetworkLoadBalancer can't be fully configured #4319

Closed
jd-carroll opened this issue Oct 1, 2019 · 6 comments
Closed

elbv2: NetworkLoadBalancer can't be fully configured #4319

jd-carroll opened this issue Oct 1, 2019 · 6 comments
Assignees
Labels
@aws-cdk/aws-elasticloadbalancing Related to Amazon Elastic Load Balancing effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. good first issue Related to contributions. See CONTRIBUTING.md p1

Comments

@jd-carroll
Copy link
Contributor

This is a continuation of #4268 (I am not able to re-open that issue)

@rix0rrr - The issue #1490 is probably a better location for the discussion around security groups. However, I still feel there are discrepancies with the current NetworkLoadBalancer.

In the cases where there are missing attributes reported, it is still possible to add them through a generic addAttribute function on the shared object. However, they are highlighted because the equivalent on the application-load-balancer side has specific support for the same attribute.

If you still feel like the workarounds are acceptable, please close this issue. 🔐

Again, the point of this issue is to highlight the discrepancies between the ApplicationLoadBalancer and NetworkLoadBalancer families.

NetworkLoadBalancer

Missing Attributes

  • access_logs.s3.enabled - Indicates whether access logs are enabled. The value is true or false. The default is false.
  • access_logs.s3.bucket - The name of the S3 bucket for the access logs. This attribute is required if access logs are enabled. The bucket must exist in the same region as the load balancer and have a bucket policy that grants Elastic Load Balancing permissions to write to the bucket.
  • access_logs.s3.prefix - The prefix for the location in the S3 bucket for the access logs.
    [From: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticloadbalancingv2-loadbalancer-loadbalancerattributes.html]

NetworkListener

  • Only 1 certificate is supported, and it does not use the same resource construct (CfnListenerCertificate) as the application listener
    [From: https://docs.aws.amazon.com/elasticloadbalancing/latest/network/create-tls-listener.html]

NetworkTargetGroup

  • No support for adding metrics

Missing Attributes:

  • deregistration_delay.timeout_seconds - The amount of time, in seconds, for Elastic Load Balancing to wait before changing the state of a deregistering target from draining to unused. The range is 0-3600 seconds. The default value is 300 seconds. If the target is a Lambda function, this attribute is not supported.
    [From: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-elasticloadbalancingv2-targetgroup-targetgroupattribute.html]

Additionally, the number and types of metrics offered on each side of the network / application load balancer seem to be duplicative and inconsistent.

@jd-carroll jd-carroll added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Oct 1, 2019
@SomayaB SomayaB added the @aws-cdk/aws-elasticloadbalancing Related to Amazon Elastic Load Balancing label Oct 1, 2019
@SomayaB
Copy link
Contributor

SomayaB commented Oct 1, 2019

@jd-carroll #4268 has been reopened.

@rix0rrr rix0rrr added feature-request A feature should be added or improved. and removed bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Oct 2, 2019
@rix0rrr
Copy link
Contributor

rix0rrr commented Oct 2, 2019

You are right about all of these. ALB for sure has gotten more love than the NLB.

Yes, there are inconsistencies, but I'm still going to classify this as a feature request (things could be better) rather than a bug (things are outright broken).

Unfortunately the reality of the enormous surface area of AWS is that we don't have the capacity to get to everything as quickly as we would. If someone would be willing to contribute here in the mean time though, we will gladly accept it.

@rix0rrr rix0rrr changed the title elbv2: Investigate NetworkLoadBalancer Inconsistencies elbv2: NetworkLoadBalancer can't be fully configured Oct 2, 2019
@davidsteed
Copy link

Atthe very least you should be able to configure a non public network load balancer. At the moment if you have a non public network load balanced fargate service it will not start as the health check fails.

@davidsteed
Copy link

I disagree that this is not a bug - it is outright broken. You can't use NetworkLoadBalancedFargateService for anything other than a public facing service. I has an option publicLoadBalancer and when set to false it does not work and cannot be made to work. It is hard to argue that this is a feature request.

@rix0rrr rix0rrr added effort/medium Medium work item – several days of effort good first issue Related to contributions. See CONTRIBUTING.md labels Jan 23, 2020
@goranopacic
Copy link

Is there a way to assign existing elastic IP address to NLB via CDK? subnetMappings is not available via construct.

@njlynch
Copy link
Contributor

njlynch commented Sep 8, 2020

Apologies for the low traction on this issue.

In the meantime, all of the originally listed gaps have been addressed:

The only gap not addressed already is supporting subnetMappings. I've created #10242 to track that.

@njlynch njlynch closed this as completed Sep 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-elasticloadbalancing Related to Amazon Elastic Load Balancing effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. good first issue Related to contributions. See CONTRIBUTING.md p1
Projects
None yet
Development

No branches or pull requests

6 participants