Announcing Kubernetes Ingress Controller 3.5
We're happy to announce the 3.5 release of Kong Ingress Controller (KIC). This release includes the graduation of combined services to General Availability, support for connection draining, as well as the start of deprecating support for some Ingress types as we help move customers to the Kubernetes Gateway API. Let’s get into more details about these!
Combined HTTP Routes is now GA
Using Combined HTTP Routes, Kong Ingress Controller can now consolidate rules from multiple HTTPRoute resources when they are targeting the same backend services. The default behavior is to create a new Gateway service for each HTTPRoute. For large numbers of HTTPRoutes, this results in added complexity and resource utilization. Enabling this feature can dramatically reduce the number of Kong Gateway services that have to be managed.
The feature is not enabled by default, as it does change the way we name services, but you can enable it by passing the --combined-services-from-different-httproutes
flag to the KIC instance or set CONTROLLER_COMBINED_SERVICES_FROM_DIFFERENT_HTTPROUTES=true
in the env section of the Helm values.
Support for Connection Draining
When Pods in your backing services are in the Terminating phase, Kong Gateway will stop connections to the Pod. In most situations, especially with stateless connections, this is not an issue as another Pod will be able to handle the connection. For session-based workloads and in combination with Sticky Sessions, you may need the connection tear down to happen gracefully.
With the introduction of Connection Draining, your clients will continue to be routed to the same backend Pod until it reaches the terminated phase, allowing your service to gracefully handle in-flight transactions, as well as notifying your clients that their session is coming to an end.
As connection draining is tied to the lifecycle phases of your Pods, you can rely on everything that makes life easier in Kubernetes, including lifecycle hooks, signalling for graceful shutdown, and now all integrated into the Kubernetes Controller and Kong Gateway.
To enable connection draining, pass --enable-drain-support
flag to the KIC instance or set CONTROLLER_ENABLE_DRAIN_SUPPORT=true
xxx in the env section of the Helm values.
You can then use drain support in combination with sticky sessions:
apiVersion: configuration.konghq.com/v1beta1
kind: KongUpstreamPolicy
metadata:
name: echo-drain-policy
spec:
# Use consistent hashing algorithm for session persistence
algorithm: consistent-hashing
slots: 100
# Configure session-based sticky routing using cookies
hashOn:
cookie: session-id # Name of the session cookie
cookiePath: / # Path for the session cookie
Deprecation of KongIngress, TCPIngress, and UDPIngress
As our customers and the Kubernetes community move towards the stable Gateway API, we have marked KongIngress, TCPIngress, and UDPIngress as deprecated in this release of KIC. You can still use these definitions, but you will see deprecation warnings.
We have migration guides for KongIngress to move to KongUpstreamPolicy, as well as moving from TCP and UDP Ingress to TCPRoute and UDPRoute in the Gateway API.
Start using Kubernetes Ingress Controller 3.5 today
As always, the quickest way to get started with KIC is with Kong Konnect, thanks to our KIC in Kong Konnect functionality.
Please also share any feedback that you might have on our GitHub discussion forum for KIC here.
Unleash the power of APIs with Kong Konnect
