rollouts-plugin-trafficrouter-gatewayapi icon indicating copy to clipboard operation
rollouts-plugin-trafficrouter-gatewayapi copied to clipboard

feat: configurable HTTP route version

Open tommy351 opened this issue 1 year ago • 9 comments

Some Gateway API implementations do not support Gateway API v1 yet. (e.g. GKE) I added a new flag http-route-api-version for users to configure HTTP route version during plugin initialization. This feature requires https://github.com/argoproj/argo-rollouts/pull/2992 which is introduced in Argo Rollouts v1.7.0-rc1.

trafficRouterPlugins:
  name: argoproj-labs/gatewayAPI
  location: https://github.com/argoproj-labs/rollouts-plugin-trafficrouter-gatewayapi/releases/download/v0.2.0/gateway-api-plugin-linux-amd64
  args:
    - "--http-route-api-version"
    - v1beta1

tommy351 avatar Apr 29 '24 09:04 tommy351

@tommy351 did you find examples when v1 doesnt work correctly with versions that are less than v1 ? I tried it with several traffic providers with beta versions and it worked well. If you found so example, can you share it with us, please ?

Philipp-Plotnikov avatar Apr 29 '24 11:04 Philipp-Plotnikov

The problem with this Pr is that it instantly doubles the testing and maintenance effort as we will need to see what happens this both 1.0 and pre 1.0 releases

Also if this flag stays as a permanent feature we will need to create a compatibility table with versions of plugin vs versions of gateway api which in the long run might be too much

What I suggest is to have two releases of the plugin and let people downgrade if their provider doesn't support 1.0

After all this is supposed to be a temporary case. What do you think @tommy351 ?

kostis-codefresh avatar Apr 29 '24 16:04 kostis-codefresh

GKE doesn't support v1 currently, and users can't install newer CRDs. I think having two releases is also fine for me.

tommy351 avatar Apr 30 '24 03:04 tommy351

@tommy351 it doesn't mean that you can't use gateway api with v1, did you find traffic provider where you had a problem ? You can use versions less than v1 but use gateway api with v1, I tested and locally for me it worked, if you had problem, please share it with us

Philipp-Plotnikov avatar Apr 30 '24 03:04 Philipp-Plotnikov

The plugin prints this error without this fix. It's not because I didn't create a corresponding HTTPRoute resource. The plugin can't use v1 API because the corresponding version doesn't exist on the cluster at all.

time="2024-04-30T03:54:39Z" level=error msg="rollout syncHandler error: failed to set weight via plugin: the server could not find the requested resource (get httproutes.gate
way.networking.k8s.io test)" namespace=default rollout=test

tommy351 avatar Apr 30 '24 03:04 tommy351

The plugin prints this error without this fix. It's not because I didn't create a corresponding HTTPRoute resource. The plugin can't use v1 API because the corresponding version doesn't exist on the cluster at all.


time="2024-04-30T03:54:39Z" level=error msg="rollout syncHandler error: failed to set weight via plugin: the server could not find the requested resource (get httproutes.gate

way.networking.k8s.io test)" namespace=default rollout=test

I will be near the computer on the evening, but did you try to install CRD of gateway api of v1 and create HTTPRoute with beta version ? I remember I installed CRD of v1 and created beta HTTPRoute, but not sure I had in cluster CRD of beta version. (I can't now check it but I think I only had v1 gateway CRD, traffic provider that supports beta version and routes with beta versions and all was good)

Philipp-Plotnikov avatar Apr 30 '24 08:04 Philipp-Plotnikov

I just tried installing v1 CRDs on a GKE cluster. It's impossible to override the CRDs installed by GKE. When I executed the following command, it didn't fail but the CRDs didn't changed either.

kubectl apply -f https://github.com/kubernetes-sigs/gateway-api/releases/download/v1.0.0/standard-install.yaml

tommy351 avatar May 02 '24 03:05 tommy351

I think the gateway api is actually lead by Google. So it is really strange that they don't support it.

Do you have an account manager that you can contact and ask them about it?

I mean if they intend to support 1.0 real soon maybe we just need to wait?

kostis-codefresh avatar May 02 '24 19:05 kostis-codefresh

I just found that Google will update their CRDs on 1.29.3. It should be released a few months later.

https://cloud.google.com/kubernetes-engine/docs/how-to/gatewayclass-capabilities#architecture

tommy351 avatar May 03 '24 03:05 tommy351

@tommy351 Do I understand correctly that Google now supports Gateway API 1.0 and this PR is no longer needed?

kostis-codefresh avatar Jun 12 '24 15:06 kostis-codefresh