Skip to content

sdkserver: fix race condition in SDK.SetLabel and SDK.SetAnnotation (issue #455)#588

Merged
jkowalski merged 1 commit intoagones-dev:masterfrom
Yingxin-Jiang:issue-455
Feb 13, 2019
Merged

sdkserver: fix race condition in SDK.SetLabel and SDK.SetAnnotation (issue #455)#588
jkowalski merged 1 commit intoagones-dev:masterfrom
Yingxin-Jiang:issue-455

Conversation

@Yingxin-Jiang
Copy link
Contributor

Fix issue #455.

When synchronizing GameServer with requested operations, i.e. updateState, updateLabel, updateAnnotation, change the key format from {operation}/{data} to {operation}. The operation data is persisted in SDKServer to prevent old operation data from overwriting the new one.

@agones-bot
Copy link
Collaborator

Build Failed 😱

Build Id: 1c400861-b848-408c-a4ac-83cbc15548a2

To get permission to view the Cloud Build view, join the agones-discuss Google Group.

@agones-bot
Copy link
Collaborator

Build Succeeded 👏

Build Id: 3f5630d9-5784-4aa2-9cdb-4daddf8112cb

The following development artifacts have been built, and will exist for the next 30 days:

A preview of the website (the last 30 builds are retained):

To install this version:

  • git fetch https://github.com/GoogleCloudPlatform/agones.git pull/588/head:pr_588 && git checkout pr_588
  • helm install install/helm/agones --namespace agones-system --name agones --set agones.image.tag=0.8.0-96a26dc

streamMutex: sync.RWMutex{},
gsLabels: map[string]string{},
gsAnnotations: map[string]string{},
gsUpdateMutex: sync.RWMutex{},
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: no need to initialize mutex like that (default value is fine). feel free to remove all of those.

@jkowalski jkowalski merged commit 05efc96 into agones-dev:master Feb 13, 2019
@markmandel markmandel added this to the 0.8.0 milestone Feb 13, 2019
@markmandel markmandel added the kind/bug These are bugs. label Feb 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/bug These are bugs.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants