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

Fixing iface deletion bug when netIds don't match #80

Merged
merged 1 commit into from
Apr 24, 2019
Merged

Conversation

Levovar
Copy link
Collaborator

@Levovar Levovar commented Apr 23, 2019

The project assumes that a DanmNet's NetworkID and ObjectMeta.Name parameters always match.
This is even outlined in the schema descriptor.
However, recently we have introduced some changes which broke this assumption.
First, with the "default" feature, and then lately with the variable static delegate configuration.
The user might not even perceive it, but as a result of these changes interfaces weren't properly cleaned-up during CNI DEL invocations.
Instead of re-writing the whole codebase, we save the real name of the network as well into the interface's DanmEp, and use this parameter when we read the network descriptor during the deletion of the interface.
Meaning of NetworkID parameter left untouched in all the other places, but eventually, we need to revise when to sue which parameter.

Commit contains one more small,, but important change: the first interface of a Pod will be always named "eth0" from now on.
This change will make it impossible for users to accidentally screw-up network naming, and thus kill their own Pod.

The project assumes that a DanmNet's NetworkID and ObjectMeta.Name parameters always match.
This is even outlined inthe schema descriptor.
However, recently we have introduced some changes which broke this assumption.
First, with the "default" feature, and then lately with the variable static delegate configuration.
The user might not even perceive it, but as a result of these changes interfaces weren't properly cleaned-up during CNI DEL invocations.
Instead of re-writing the whole codebase, we save the real name of the network as well into the interface's DanmEp, and use this parameter when we read the network descriptor during the deletion of the interface.
Meaning of NetworkID parameter left untouched in all the other places, but eventually, we need to revise when to sue which parameter.

Commit contains one more smal,, but important change: the first interface of a Pod will be always named "eth0" from now on.
This change will make it impossible for users to accidentally screw-up network naming, and thus kill their own Pod.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant