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 lan info to a guest_device (port) #165

Merged
merged 1 commit into from
Mar 15, 2018

Conversation

felipedf
Copy link
Member

@felipedf felipedf commented Feb 2, 2018

Adding vlan info to a guest_device when it assume a logical port function

@agrare
Copy link
Member

agrare commented Feb 15, 2018

@miq-bot assign @Fryguy

@agrare
Copy link
Member

agrare commented Feb 15, 2018

@felipedf could you add a description of what these fields mean? I don't see how they relate to VLANs or how vnicMode is a boolean and not a string.

@felipedf
Copy link
Member Author

@agrare well, now guest_devices can assume a role of a port and a port can have many logical ports, which will also be a guest_device through child_devices field. Supposedly a logical port contains a reference to its vlan and the vnicMode would say whether or not vnic is enabled on this port

@agrare
Copy link
Member

agrare commented Feb 15, 2018

@felipedf is this a port on a switch? I wonder if we should add a port model and a switch can have many ports, then a guest_device belongs_to a port?

@agrare
Copy link
Member

agrare commented Feb 15, 2018

Spoke offline with @felipedf and this is intended for host NICs not switch ports, and these properties are meant to represent the vlan_id. I recommended just calling it vlan_id and using just one property.

@felipedf
Copy link
Member Author

felipedf commented Feb 16, 2018

Spoke with @agrare and decided to keep vlan_id and a vlan_enabled properties, where vlan_enabled is meant to represent the status of a vlan, so a port can be associated to a vlan even though its status is disabled

@rodneyhbrown7
Copy link

@agrare @Fryguy can this be merged?

@agrare
Copy link
Member

agrare commented Mar 15, 2018

Can you change the name from :vlan_id to something that doesn't end in _id since rails will assume this is a foreign key.
This will represent a physical port on a switch with a tagged vlan.

@felipedf felipedf force-pushed the vlan_to_guest_devices branch from 40a0f4b to d3154c2 Compare March 15, 2018 20:57
@felipedf
Copy link
Member Author

Done 😃 👍

@miq-bot
Copy link
Member

miq-bot commented Mar 15, 2018

Checked commit felipedf@d3154c2 with ruby 2.3.3, rubocop 0.52.1, haml-lint 0.20.0, and yamllint 1.10.0
1 file checked, 0 offenses detected
Everything looks fine. 🏆

@Fryguy Fryguy merged commit 1c77c78 into ManageIQ:master Mar 15, 2018
@Fryguy Fryguy added this to the Sprint 82 Ending Mar 26, 2018 milestone Mar 15, 2018
@felipedf felipedf deleted the vlan_to_guest_devices branch May 4, 2018 18:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants