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

fixed data race at nodes deletion #425

Merged
merged 2 commits into from
May 20, 2021
Merged

fixed data race at nodes deletion #425

merged 2 commits into from
May 20, 2021

Conversation

hellt
Copy link
Member

@hellt hellt commented May 20, 2021

No description provided.

@hellt
Copy link
Member Author

hellt commented May 20, 2021

@networkop there was a data race when you delete the lab with >2 nodes. In the meantime I will change the chan to use copies of the GenericContainer structs as a quick fix, but it would be nice to get to the root of it and understand the cause of the data race

@networkop
Copy link
Contributor

@hellt do you have steps to reproduce?

@hellt
Copy link
Member Author

hellt commented May 20, 2021

@networkop , I got help from @karimra to have a fix that keeps the pointer channel
The culprit was with a pointer to the loop variable that got sent into the channel. As I understood Karims explanations, that variable is kept the same throughout the loop cycle, so we had the same pointer passed all over to the workers

https://stackoverflow.com/questions/49123133/sending-pointers-over-a-channel

in bf13970 I applied the suggested quick fix

@hellt hellt merged commit 5d41c33 into master May 20, 2021
@networkop
Copy link
Contributor

so i guess this looks like a long-term fix? or did you still want me to find an alternative @hellt ?

@hellt
Copy link
Member Author

hellt commented May 23, 2021 via email

@hellt hellt deleted the deletion-race-fix branch October 22, 2021 17:44
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.

2 participants