feat: refactor member agent flag handling logic + add per-flag validation logic#489
feat: refactor member agent flag handling logic + add per-flag validation logic#489michaelawyu wants to merge 4 commits intokubefleet-dev:mainfrom
Conversation
Signed-off-by: michaelawyu <chenyu1@microsoft.com>
Signed-off-by: michaelawyu <chenyu1@microsoft.com>
Signed-off-by: michaelawyu <chenyu1@microsoft.com>
|
This PR follows the same pattern as applied in PR #459. |
|
UTs and cross-field validation logic are stripped away to control the PR size. |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
|
||
| # Copy the go source | ||
| COPY cmd/memberagent/main.go main.go | ||
| COPY cmd/memberagent cmd/memberagent/ |
There was a problem hiding this comment.
is there any reason for this change?
There was a problem hiding this comment.
Hi Ryan! This is needed as previously we copy only the main.go file for the member agent; however, right now a new folder cmd/memberagent/options is added in the same pattern as the hub agent, and we need to copy this as well otherwise things won't build.
cmd/memberagent/options/options.go
Outdated
| UseV1Alpha1APIs bool | ||
| UseV1Beta1APIs bool |
There was a problem hiding this comment.
where are those still used?
There was a problem hiding this comment.
Hi Ryan! The v1beta1 API flag is still in use in the upstream chart; PR #502 will drop it. I saw that the v1alpha1 API flag has been removed everywhere -> will remove it from the code.
Signed-off-by: michaelawyu <chenyu1@microsoft.com>
Description of your changes
This PR refactors the flag handling logic on the hub agent end and adds per-flag validation logic.
I have:
make reviewableto ensure this PR is ready for review.How has this code been tested
N/A
Special notes for your reviewer
N/A