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 bond hash policy #708

Merged
merged 1 commit into from
Oct 5, 2023
Merged

✨ Add bond hash policy #708

merged 1 commit into from
Oct 5, 2023

Conversation

shibaPuppy
Copy link
Contributor

@shibaPuppy shibaPuppy commented Sep 6, 2022

https://github.com/openstack/ironic/blob/master/ironic/tests/unit/drivers/modules/network/json_samples/network_data.json#L31
Adds the bond hash policy feature added to Ironic.

What this PR does / why we need it:

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 #

@metal3-io-bot metal3-io-bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Sep 6, 2022
@metal3-io-bot
Copy link
Contributor

Hi @shibaPuppy. Thanks for your PR.

I'm waiting for a metal3-io member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

@metal3-io-bot metal3-io-bot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Sep 6, 2022
Copy link
Member

@dtantsur dtantsur left a comment

Choose a reason for hiding this comment

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

/ok-to-test

https://github.com/canonical/cloud-init/blob/main/cloudinit/sources/helpers/openstack.py#L679 seems to require bond_links actually? I'm not sure how the link you pasted proves it's optional.

@metal3-io-bot metal3-io-bot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Sep 7, 2022
@shibaPuppy
Copy link
Contributor Author

shibaPuppy commented Sep 7, 2022

@dtantsur
cloud-init code copies bond_links.
try to get the desired bond id value by putting an empty array in bond_links as shown below.

links:
- id: bond0
  type: bond
  ethernet_mac_address: ff:ff:ff:ff:ff:ff
  bond_links: [] # here empty array
- id: bond1
  type: bond
  ethernet_mac_address: 11:22:33:44:55:66
  bond_links:
    - eth0
    - eth1
....

@metal3-io-bot
Copy link
Contributor

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues will close after an additional 30d of inactivity.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@metal3-io-bot metal3-io-bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 17, 2023
@metal3-io-bot metal3-io-bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Apr 25, 2023
@metal3-io-bot metal3-io-bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Apr 25, 2023
@shibaPuppy shibaPuppy changed the title Change to optional for network-data bond_link field Add bond hash policy Apr 25, 2023
@shibaPuppy
Copy link
Contributor Author

@dtantsur
hi,
adds the bond hash policy feature added to Ironic.
please review

@metal3-io-bot metal3-io-bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Apr 25, 2023
@metal3-io-bot metal3-io-bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Apr 25, 2023
// +kubebuilder:validation:Enum="layer2";"layer3+4";"layer2+3"
// Selects the transmit hash policy used for port selection in balance-xor and 802.3ad modes
// +optional
BondHashPolicy string `json:"bond_xmit_hash_policy"`
Copy link
Member

Choose a reason for hiding this comment

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

The JSON name does not conform to the used standard and does not fully match the field name. Why not just bondHashPolicy?

// +kubebuilder:validation:Enum="layer2";"layer3+4";"layer2+3"
// Selects the transmit hash policy used for port selection in balance-xor and 802.3ad modes
// +optional
BondHashPolicy string `json:"bond_xmit_hash_policy"`
Copy link
Member

Choose a reason for hiding this comment

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

same

"mtu": link.MTU,
"ethernet_mac_address": macAddress,
"bond_mode": link.BondMode,
"bond_xmit_hash_policy": link.BondHashPolicy,
Copy link
Member

Choose a reason for hiding this comment

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

I cannot find this field in the network data schema. Where is it coming from?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@dtantsur
It does not exist in the network-data schema, but I confirmed that the code exists in the ironic sample & cloud-init.

@metal3-io-bot metal3-io-bot removed the needs-rebase Indicates that a PR cannot be merged because it has merge conflicts with HEAD. label Oct 2, 2023
@Rozzii
Copy link
Member

Rozzii commented Oct 3, 2023

/test-centos-e2e-integration-main
/test-ubuntu-integration-main

@Rozzii Rozzii removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Oct 3, 2023
@Rozzii
Copy link
Member

Rozzii commented Oct 3, 2023

/test-centos-e2e-integration-main
/test-ubuntu-integration-main

Copy link
Member

@Rozzii Rozzii left a comment

Choose a reason for hiding this comment

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

/lgtm
Looks good as far as I can tell.

@metal3-io-bot metal3-io-bot added the lgtm Indicates that a PR is ready to be merged. label Oct 5, 2023
@Rozzii
Copy link
Member

Rozzii commented Oct 5, 2023

PTAL @kashifest @mboukhalfa @lentzi90

@Rozzii
Copy link
Member

Rozzii commented Oct 5, 2023

@kashifest
Copy link
Member

/test-ubuntu-e2e-features-main
/test-e2e-upgrade-main-from-release-0-5

@Rozzii
Copy link
Member

Rozzii commented Oct 5, 2023

@kashifest seems like the test haven't been triggered

@kashifest
Copy link
Member

/test-ubuntu-e2e-feature-main

Copy link
Member

@adilGhaffarDev adilGhaffarDev left a comment

Choose a reason for hiding this comment

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

/lgtm

@lentzi90
Copy link
Member

lentzi90 commented Oct 5, 2023

/retitle ✨ Add bond hash policy

@metal3-io-bot metal3-io-bot changed the title Add bond hash policy ✨ Add bond hash policy Oct 5, 2023
@lentzi90
Copy link
Member

lentzi90 commented Oct 5, 2023

/test-e2e-upgrade-main-from-release-1-5

@kashifest
Copy link
Member

/test-ubuntu-e2e-feature-main

@kashifest
Copy link
Member

/test-e2e-upgrade-main-from-release-1-5

@kashifest
Copy link
Member

/approve

@metal3-io-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kashifest, Rozzii

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

@metal3-io-bot metal3-io-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 5, 2023
@metal3-io-bot metal3-io-bot merged commit 1bc274f into metal3-io:main Oct 5, 2023
18 checks passed
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. lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. 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.

9 participants