-
Notifications
You must be signed in to change notification settings - Fork 47
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
Various refactorings #353
Various refactorings #353
Conversation
67452bf
to
70710ea
Compare
// We use map[string]interface{} instead a []string to facilitate constant time lookups for GameServer names. | ||
// On every reconcile loop, we check if all the GameServers for this GameServerBuild are present in cache) | ||
// The controller code will eventually delete the extra GameServers, but we can improve this process. | ||
// The solution is to create a synchonized map to track which objects were just created |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
synchronized
// (synchronized since it might be accessed by multiple reconciliation goroutines - one for each GameServerBuild) | ||
// In this map, the key is GameServerBuild.Name | ||
// The value is a struct with map[string]interface{} and a mutex | ||
// The map acts like a set which contains the GameServer.Name for all the GameServers under creation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
space after period
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's a property :D let me make it more clear!
70710ea
to
a08fc88
Compare
Drafting a PR so we can run e2e tests here.