-
Notifications
You must be signed in to change notification settings - Fork 593
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
feat: add service discovery for kong admin service #3421
Conversation
de84bf3
to
6b69ed1
Compare
Codecov ReportBase: 72.9% // Head: 72.3% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #3421 +/- ##
=======================================
- Coverage 72.9% 72.3% -0.6%
=======================================
Files 119 120 +1
Lines 14099 14318 +219
=======================================
+ Hits 10283 10362 +79
- Misses 3158 3289 +131
- Partials 658 667 +9
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
6b69ed1
to
2055d49
Compare
fe5bd66
to
2624e28
Compare
2624e28
to
4038aa3
Compare
4038aa3
to
f4a7ef3
Compare
b85d928
to
477c515
Compare
b37f9d7
to
3cb4067
Compare
Here's an e2e targeted pipeline that passed: https://github.com/Kong/kubernetes-ingress-controller/actions/runs/4128494573/jobs/7133003972#step:10:374 |
1a694c1
to
d808e16
Compare
🚢 |
9dbc558
to
9a400cf
Compare
What this PR does / why we need it:
This PR introduces kong Admin API service discovery via the
--kong-admin-svc
flag (to be discussed).When that flag is specified (as
namespace/service_name
) KIC will watchEndpointSlice
s for thatService
and add (and remove when the endpoint gets removed) a kong client for each endpoint for thatService
.This in its current form does not take into account the fact that gateway should be made ready only when its config is applied and ready (Admin API readines != Gateway Proxy readiness). We don't yet have a mechanism to be sure that a config has been applied (it can come in one of the upcoming Gateway releases) but we could implement a mechanism to make Gateway Proxy service marked as ready after the config has been sent.
#3499 covers whether we'd like to introduce said mechanism.
Which issue this PR fixes:
Fixes #3400
Special notes for your reviewer:
This is not yet 100% ready but ready for review.The multi gw manifests that are also slightly changed in this PR are almost working, that is: they deploy KIC 2.8.1 which doesn't yet support
--kong-admin-svc
flag and since--kong-admin-url
has a default of[]string{"http://localhost:8001"}
then it uses that but since with those manifests we deploy 2 separate deployments this address cannot be reached and KIC fails.PR Readiness Checklist:
Complete these before marking the PR as
ready to review
:CHANGELOG.md
release notes have been updated to reflect any significant (and particularly user-facing) changes introduced by this PR