ingress
ingress copied to clipboard
Build upstreams from EndpointSlices
An attempt at #7.
This generalizes the informer code so adding more informers doesn't involve a bunch of boilerplate. It then adds the Service and EndpointSlice informers necessary to keep the upstreams updated.
This also includes some work on secrets, to try keep them out of memory, because the informer normally builds a cache of everything. Especially without -namespace, we were just kinda keeping around every secret anywhere in the cluster in memory.
After some more testing, I noticed the informer cache shifts results every now and then. I suspect periodic reconciliation. This caused the output to shift as well, and frequent reloads. I now sort the informer results before processing.
I also added a simple helper to limit logging of warning messages generated by plugins, so it is safe to log from plugins even though they run quite often.
Codecov Report
Attention: Patch coverage is 26.00473% with 313 lines in your changes missing coverage. Please review.
Project coverage is 21.97%. Comparing base (
7db5cd4) to head (1bd8fb3).
Additional details and impacted files
@@ Coverage Diff @@
## main #310 +/- ##
==========================================
+ Coverage 20.11% 21.97% +1.85%
==========================================
Files 30 33 +3
Lines 1397 1502 +105
==========================================
+ Hits 281 330 +49
- Misses 1114 1159 +45
- Partials 2 13 +11
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
I rebased this on main and fixed the conflicts. Did some testing and still good in my setup.
I didn't notice the failing test, but it was simply missing permissions for watching EndpointSlices in the chart. That's fixed now.