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

Swarmkit v2 #3061

Merged
merged 7 commits into from
Apr 20, 2022
Merged

Swarmkit v2 #3061

merged 7 commits into from
Apr 20, 2022

Conversation

corhere
Copy link
Contributor

@corhere corhere commented Apr 14, 2022

- What I did
Swarmkit v2

- How I did it
https://github.com/icholy/gomajor

- How to test it
🤷

- Description for the changelog

@thaJeztah
Copy link
Member

Looks like protobuf validation isn't happy (perhaps it's somewhere still referencing the old name)

A113826C-666D-463D-AAA0-66D21C029669

Also some warning (not the cause of the failure); circleci looks to be running an ancient ubuntu version

2342558F-ED10-49D5-96B7-173A0187B2D7

@corhere
Copy link
Contributor Author

corhere commented Apr 14, 2022

I got further, but the generated .pb.go files still have import declarations for "github.com/docker/swarmkit/protobuf/plugin". I'm out of my depth here; any ideas @dperny?

@dperny
Copy link
Collaborator

dperny commented Apr 15, 2022

In Protobuild.toml, there is a [packages] section. At the bottom of that section, add a line:

"github.com/docker/swarmkit/protobuf/plugin/plugin.proto" = "github.com/moby/swarmkit/v2/protobuf/plugin"

This makes the import path correct.

dperny and others added 5 commits April 15, 2022 11:56
Resolve package import paths to the corresponding source paths in the
Makefile.

Signed-off-by: Cory Snider <[email protected]>
I don't know how, but something about converting to a Go module and
renaming it has shaken out a latent data race. The memory store
implementation had made the assumption that the callback function
supplied to ProposeValue() is invoked iff ProposeValue() returns
err == nil. This is not strictly true: in certain rare circumstances,
ProposeValue() can return a non-nil error while the callback is being
executed asynchronously in another goroutine. This results in a data
race, concurrently Commit()ing and Abort()ing the same memDB
transaction. Fix the data race by adding a guard to prevent Abort() from
being called if Commit() has been, and vice versa.

Signed-off-by: Cory Snider <[email protected]>
Unit tests are failing on CircleCI but not when run locally. Crank up
the verbosity to try to figure out what's happening.

Signed-off-by: Cory Snider <[email protected]>
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.

4 participants