Repository navigation
chore(store): drop Workload addresses and ports from the CRD - #120
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
There was a problem hiding this comment.
🟡 Changes recommended
The API update breaks decoding of legacy SQLite payloads containing addresses or ports, causing workload reads to fail and listings to omit existing records.
2 open issues
What changed in this PR
Aligns dir-runtime with dir v1.9.0’s removal of deprecated workload endpoint fields, continuing the migration to locators.
Changes:
- Removes
addresses,ports, and their print columns from the generated workload CRD. - Updates dir dependencies to v1.9.0 and refreshes dependency checksums.
- Raises affected Go directives and container builder images to Go 1.27.3.
| File | Description |
|---|---|
store/go.sum |
Refreshes API and transitive dependency checksums. |
store/go.mod |
Updates the API dependency and Go requirement. |
server/go.sum |
Refreshes API and transitive dependency checksums. |
server/go.mod |
Updates the API dependency and Go requirement. |
server/Dockerfile |
Updates the pinned Go builder image. |
install/chart/templates/discovery.agntcy.io_discoveredworkloads.yaml |
Removes deprecated endpoint properties and print columns. |
discovery/go.sum |
Refreshes dir and transitive dependency checksums. |
discovery/go.mod |
Updates dir modules, transitive dependencies, and Go requirement. |
discovery/Dockerfile |
Updates the pinned Go builder image. |
Review effort: Balanced
csirmazbendeguz
approved these changes
Nov 11, 2026
agntcy/dir#2397 removes the fields from agntcy.dir.runtime.v1.Workload. Pin dir/api to it and regenerate the DiscoveredWorkload CRD, which loses the two properties and the Addresses and Ports print columns. Signed-off-by: András Jáky <[email protected]>
Move github.com/agntcy/dir/api (store, discovery, server) from the pre-release pseudo-version to v1.9.0, and client/utils in discovery to v1.9.0. The dir v1.9.0 modules require Go 1.27.3, so the go directives and the builder images move to 1.27.3 too. The regenerated CRD is unchanged. Signed-off-by: András Jáky <[email protected]>
akijakya
force-pushed
the
chore/drop-workload-addresses-ports
branch
from
November 11, 2026 09:31
1e1e355 to
9f56543
Compare
ramizpolic
approved these changes
Nov 11, 2026
api v1.9.0 drops addresses and ports from Workload. protojson.Unmarshal rejects unknown fields by default, so a row written before v1.4.0 that still has them made GetWorkload fail and dropped out of ListWorkloads. Decode with DiscardUnknown instead, and cover it with a regression test. Also set the Taskfile GO_VERSION and the utils module to Go 1.27.3, so task deps:tidy matches the Go requirement of the dir v1.9.0 modules. Signed-off-by: András Jáky <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Follow-up to agntcy/dir#2397 (step 3 of agntcy/dir#2299), which removes the deprecated
addressesandportsfromagntcy.dir.runtime.v1.Workload. That change shipped in dir v1.9.0.Changes
github.com/agntcy/dir/apiin store, discovery and server is pinned tov1.9.0;github.com/agntcy/dir/clientandgithub.com/agntcy/dir/utilsin discovery move tov1.9.0too.godirectives and thegolangbuilder images in the discovery and server Dockerfiles move to 1.27.3.task crd:genregeneratesinstall/chart/templates/discovery.agntcy.io_discoveredworkloads.yaml: theaddressesandportsproperties and the Addresses and Ports print columns are gone.No code here sets the fields: since v1.4.0 the adapters emit locators only. A stored
DiscoveredWorkloadthat still has the two fields loses them (structural pruning) the next time it is written.Testing
task lintandtask testpass.task crd:genagainstapiv1.9.0 produces no further changes to the CRD.