-
Notifications
You must be signed in to change notification settings - Fork 93
Support load balancer listeners with http protocol via annotation #239
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than having a boolean annotation I'd like us to follow AWS's lead:
pkg/oci/load_balancer.go
Outdated
@@ -70,6 +70,10 @@ const ( | |||
// ServiceAnnotaionLoadBalancerSecurityListManagementMode is a Service annotation for | |||
// specifying the security list managment mode ("All", "Frontend", "None") that configures how security lists are managed by the CCM | |||
ServiceAnnotaionLoadBalancerSecurityListManagementMode = "service.beta.kubernetes.io/oci-load-balancer-security-list-management-mode" | |||
|
|||
// ServiceAnnotationLoadBalancerEnableHTTPProtocol is a Service annotation for | |||
// enabling/disabling the load balancer listener with the http protocol. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be nice if the comment stated what the accepted values are, and also what is the effect of setting this, i.e. why would a user want to do it/why are we supporting it?
ff5dd26
to
23f5a14
Compare
70a17aa
to
0e39e7e
Compare
docs/load-balancer-annotations.md
Outdated
@@ -28,6 +28,7 @@ spec: | |||
| `oci-load-balancer-subnet2` | The OCID of the second [subnet][2] of the two required subnets to attach the load balancer to. Must be in separate Availability Domains. | Value provided in config file | | |||
| `oci-load-balancer-connection-idle-timeout` | The maximum idle time, in seconds, allowed between two successive receive or two successive send operations between the client and backend servers. | `300` for TCP listeners, `60` for HTTP listeners | | |||
| `oci-load-balancer-security-list-management-mode` | Specifies the [security list mode](##security-list-management-modes) (`"All"`, `"Frontend"`,`"None"`) to configure how security lists are managed by the CCM. | `"All"` | |||
| `oci-load-balancer-backend-protocol` | Specifies the [load balancer listener][5] backend protocol ("TCP", "HTTP"). | `"TCP"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The linked page is too general maybe just copy from the API documentation:
Specify protocol on which the listener accepts connection requests. To get a list of valid protocols, use the ListProtocols operation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Good work. 👍
0e39e7e
to
0de33ae
Compare
0de33ae
to
1d5807d
Compare
Addresses #208
Currently only TCP listeners are supported when creating a service type load balancer. The oci console allows for either TCP or HTTP.
When the service is create with the
service.beta.kubernetes.io/oci-load-balancer-backend-protocol
annotation is set to"HTTP"
the listener protocol will be overridden to use HTTP. The value"TCP"
may also be used for TCP listeners, however, this is the default when the value is empty or when the annotation is not present.