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

🌱Add more helper functions in topologymutation varaible.go to help unmarshal variables #9670

Conversation

lubronzhan
Copy link
Contributor

@lubronzhan lubronzhan commented Nov 3, 2023

What this PR does / why we need it:
Add more function. For example to unmarshal nested variable from topology spec, and unmarshal bool variable from topology spec.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #9669

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-area PR is missing an area label size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Nov 3, 2023
@lubronzhan lubronzhan force-pushed the topic/add_func_to_topologymultation_variable_extractor branch from d263ca5 to 3174b89 Compare November 4, 2023 17:34
Copy link
Contributor

@killianmuldoon killianmuldoon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed the prod code and a little bit on the testing. Some comments on the signature of these functions to try to keep them consistent and clear.

exp/runtime/topologymutation/variables.go Outdated Show resolved Hide resolved
exp/runtime/topologymutation/variables.go Outdated Show resolved Hide resolved
exp/runtime/topologymutation/variables_test.go Outdated Show resolved Hide resolved
exp/runtime/topologymutation/variables_test.go Outdated Show resolved Hide resolved
exp/runtime/topologymutation/variables_test.go Outdated Show resolved Hide resolved
Copy link
Contributor

@killianmuldoon killianmuldoon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/area runtime-sdk

@k8s-ci-robot k8s-ci-robot added area/runtime-sdk Issues or PRs related to Runtime SDK and removed do-not-merge/needs-area PR is missing an area label labels Nov 6, 2023
Copy link
Contributor

@killianmuldoon killianmuldoon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thiink the TODO on L31 should be covered by this PR, right?

@lubronzhan lubronzhan force-pushed the topic/add_func_to_topologymultation_variable_extractor branch from f519b2a to 34970f9 Compare November 7, 2023 03:34
@lubronzhan
Copy link
Contributor Author

/retest-required

@lubronzhan lubronzhan force-pushed the topic/add_func_to_topologymultation_variable_extractor branch 3 times, most recently from 1520a9c to 5de6f49 Compare November 7, 2023 04:44
@lubronzhan
Copy link
Contributor Author

pull-cluster-api-apidiff-main failed because there is API change on the function

@killianmuldoon
Copy link
Contributor

pull-cluster-api-apidiff-main failed because there is API change on the function

This should be fine - as it's not required for merge. We just use it as a signal that something in the API has changed

@killianmuldoon
Copy link
Contributor

/test pull-cluster-api-e2e-full-main

To run the tests that use these functions.

@lubronzhan
Copy link
Contributor Author

Thanks. pull-cluster-api-e2e-full-main passed, I fixed the unit tests

@lubronzhan
Copy link
Contributor Author

Hi @fabriziopandini could you help take a look since it's related to runtime-extension? Thanks

@lubronzhan
Copy link
Contributor Author

Hi @sbueringer do you have time to review? Thanks

@lubronzhan
Copy link
Contributor Author

Hi @sbueringer is it a good time now?

Copy link
Member

@sbueringer sbueringer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup now is a good time. Sorry also lost track a bit of this PR.

exp/runtime/topologymutation/variables_test.go Outdated Show resolved Hide resolved
exp/runtime/topologymutation/variables.go Outdated Show resolved Hide resolved
exp/runtime/topologymutation/variables.go Show resolved Hide resolved
@lubronzhan
Copy link
Contributor Author

Almost forgot, let me get back to this tomorrow

@lubronzhan lubronzhan force-pushed the topic/add_func_to_topologymultation_variable_extractor branch 2 times, most recently from 01c5966 to 9fb7a89 Compare January 30, 2024 01:40
@sbueringer
Copy link
Member

Last one from my side: #9670 (comment)

Feel free to also directly squash

@lubronzhan lubronzhan force-pushed the topic/add_func_to_topologymultation_variable_extractor branch from 2f62c10 to 35ba78f Compare January 30, 2024 23:31
@lubronzhan
Copy link
Contributor Author

/test pull-cluster-api-test-main

Signed-off-by: lubronzhan <lubronzhan@gmail.com>
@lubronzhan lubronzhan force-pushed the topic/add_func_to_topologymultation_variable_extractor branch from 35ba78f to ec9d06b Compare January 30, 2024 23:42
@k8s-ci-robot
Copy link
Contributor

k8s-ci-robot commented Jan 30, 2024

@lubronzhan: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-cluster-api-apidiff-main ec9d06b link false /test pull-cluster-api-apidiff-main

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@sbueringer
Copy link
Member

sbueringer commented Jan 31, 2024

Thank you very much!

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 31, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: sbueringer

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 088d0a1bd12ec9afec6484d03c538dd001942c43

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jan 31, 2024
@k8s-ci-robot k8s-ci-robot merged commit 2fd1e7d into kubernetes-sigs:main Jan 31, 2024
19 of 20 checks passed
@k8s-ci-robot k8s-ci-robot added this to the v1.7 milestone Jan 31, 2024
@lubronzhan lubronzhan deleted the topic/add_func_to_topologymultation_variable_extractor branch January 31, 2024 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/runtime-sdk Issues or PRs related to Runtime SDK cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add more helper func for topologymutation func
4 participants