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

update to Gateway API v0.5.0/v1beta1 #4560

Closed
skriss opened this issue Jun 8, 2022 · 6 comments · Fixed by #4617
Closed

update to Gateway API v0.5.0/v1beta1 #4560

skriss opened this issue Jun 8, 2022 · 6 comments · Fixed by #4617
Assignees
Labels
area/gateway-api Issues or PRs related to the Gateway (Gateway API working group) API. kind/feature Categorizes issue or PR as related to a new feature.
Milestone

Comments

@skriss
Copy link
Member

skriss commented Jun 8, 2022

Once Gateway API v0.5.0 is released, Contour needs to be updated to use it, as well as the v1beta1 API.

ref. #4555

@skriss skriss added kind/feature Categorizes issue or PR as related to a new feature. area/gateway-api Issues or PRs related to the Gateway (Gateway API working group) API. labels Jun 8, 2022
@skriss skriss added this to the 1.22.0 milestone Jun 8, 2022
@skriss skriss self-assigned this Jun 8, 2022
skriss added a commit that referenced this issue Jun 16, 2022
Updates Gateway API to v0.5.0-rc1 in
preparation for updating to v0.5.0 when
it's released.

Updates #4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
@skriss
Copy link
Member Author

skriss commented Jun 21, 2022

I'm discovering that updating to v1beta1 types is problematic, specifically for HTTPRoute, because TLSRoute is not moving to beta, but we have a lot of code that's shared across those two types for hostnames, status, etc. Since v1alpha2 and v1beta1 are effectively identical for HTTPRoute (and both will be present), it may make sense to only update GatewayClass and Gateway to v1beta1 for now, and wait until TLSRoute graduates to update the route code.

@youngnick
Copy link
Member

That makes sense for now, but we may have to make that shared logic a bit smarter - I suspect that it may be a while before we move TLSRoute to v1beta1.

@skriss
Copy link
Member Author

skriss commented Jun 22, 2022

That makes sense for now, but we may have to make that shared logic a bit smarter - I suspect that it may be a while before we move TLSRoute to v1beta1.

Alright, that's good to know, I'll start looking at making it work for both.

@carlisia
Copy link
Contributor

carlisia commented Jun 22, 2022

Since v1alpha2 and v1beta1 are effectively identical for HTTPRoute (and both will be present), it may make sense to only update GatewayClass and Gateway to v1beta1 for now, and wait until TLSRoute graduates to update the route code.

Hey @skriss (👋!!) just wanted to be sure:
Although you have a bump to Gateway API release v0.5.0-rc1 on your latest Contour release (Contour v1.21.1), you are still only using the v1alpha2 api all across, is this correct? And you will be updating maybe only GatewayClass and Gateway to v1beta1 in a future release? The next one possibly? Am I reading this correctly?

Addendum: and you are not using any of the standard Gateway API CRDs in the currently release, right?

This is what I am seeing in the Contour code, wanted to double check that I didn't miss anything while I'm updating Knative's net-gateway-api to Contour v1.21.1 + 0.5.0-rc1 of the Gateway API.

@skriss
Copy link
Member Author

skriss commented Jun 22, 2022

Hey @carlisia!

Since v1alpha2 and v1beta1 are effectively identical for HTTPRoute (and both will be present), it may make sense to only update GatewayClass and Gateway to v1beta1 for now, and wait until TLSRoute graduates to update the route code.

Hey @skriss (👋!!) just wanted to be sure: Although you have a bump to Gateway API release v0.5.0-rc1 on your latest Contour release (Contour v1.21.1), you are still only using the v1alpha2 api all across, is this correct?

We've updated Contour's main branch to use Gateway API v0.5.0-rc1, but that hasn't made it into any release and we'll update to v0.5.0 before our next release. Correct, we are still using the v1alpha2 API version, even in main.

And you will be updating maybe only GatewayClass and Gateway to v1beta1 in a future release? The next one possibly? Am > I reading this correctly?

I think we'll probably update Contour code to use v1beta1 for GatewayClass, Gateway, and HTTPRoute before Contour's next release (although since v1alpha2 and v1beta1 are automatically converted between by the API server, users can still use either API version), though I'm still sorting out exactly how much of a pain it will be to update HTTPRoute code :)

Addendum: and you are not using any of the standard Gateway API CRDs in the currently release, right?

Contour 1.21.1 uses Gateway API v0.4.3 which didn't have release channels yet; on main (using v0.5.0-rc1) we've decided to use the experimental channel since we've already implemented ReferencePolicy, and that's only in the experimental channel right now.

This is what I am seeing in the Contour code, wanted to double check that I didn't miss anything while I'm updating Knative's net-gateway-api to Contour v1.21.1 + 0.5.0-rc1 of the Gateway API.

Yep, just note that Contour 1.21.1 is using Gateway API v0.4.3 (https://github.com/projectcontour/contour/blob/v1.21.1/go.mod#L43), it's only on main that we've updated to v0.5.0-rc1 (and that'll be updated to v0.5.0 as soon as it's out).

@carlisia
Copy link
Contributor

Ah gotcha. Thought v0.5.0-rc1 was both on main and on 1.21.1. Glad this surfaced (thanks for making it clear!), I'll point my update to a recent commit on main for now.

Copy that on ReferencePolicy being on the experimental channel and that being the only resource that Contour uses right now from either of the channels.

I'll be following closely your next update so I'm sure to meet the Knative v1.6 release timeline, which is coming soon. It seems that v1beta1 might be cut this week.

I didn't know about the conversion between the two APIs, thanks for expanding on that!

Thank you again for your very clear explanations!

skriss added a commit that referenced this issue Jun 27, 2022
Updates GatewayClass and Gateway
code to use the v1beta1 API since these
resources have moved to beta in the
v0.5.0 Gateway API release.

Updates #4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
skriss added a commit to skriss/contour that referenced this issue Jun 27, 2022
Updates HTTPRoute code to use the v1beta1
API since this resource has moved to beta
in the v0.5.0 Gateway API release.

Updates projectcontour#4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
skriss added a commit to skriss/contour that referenced this issue Jun 28, 2022
Updates HTTPRoute code to use the v1beta1
API since this resource has moved to beta
in the v0.5.0 Gateway API release.

Updates projectcontour#4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
skriss added a commit that referenced this issue Jun 28, 2022
Updates HTTPRoute code to use the v1beta1
API since this resource has moved to beta
in the v0.5.0 Gateway API release.

Updates #4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
skriss added a commit to skriss/contour that referenced this issue Jul 13, 2022
Closes projectcontour#4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
skriss added a commit that referenced this issue Jul 13, 2022
* update Gateway API to v0.5.0

Closes #4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
gary-tai pushed a commit to gary-tai/contour that referenced this issue Jul 19, 2022
* update Gateway API to v0.5.0

Closes projectcontour#4560.

Signed-off-by: Steve Kriss <krisss@vmware.com>
Signed-off-by: Gary Tai <gary.c.tai@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/gateway-api Issues or PRs related to the Gateway (Gateway API working group) API. kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants