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

cmd/dist/fetch: address subtle concurrency bug #572

Merged
merged 1 commit into from
Feb 25, 2017

Conversation

stevvooe
Copy link
Member

When using the fetcher concurrently, the loop modifying the closed
base parameter was causing urls from different digests to be returned
randomly. We copy the the value and then modify it to make it work
correctly.

Luckily, we are using content addressable storage or this would have
been undetectable.

Signed-off-by: Stephen J Day stephen.day@docker.com

When using the fetcher concurrently, the loop modifying the closed
`base` parameter was causing urls from different digests to be returned
randomly. We copy the the value and then modify it to make it work
correctly.

Luckily, we are using content addressable storage or this would have
been undetectable.

Signed-off-by: Stephen J Day <stephen.day@docker.com>
@stevvooe
Copy link
Member Author

This one was fun!

@codecov-io
Copy link

codecov-io commented Feb 25, 2017

Codecov Report

Merging #572 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #572   +/-   ##
=======================================
  Coverage   62.12%   62.12%           
=======================================
  Files           3        3           
  Lines         404      404           
=======================================
  Hits          251      251           
  Misses         93       93           
  Partials       60       60

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0f76e0a...2e0c92b. Read the comment docs.

@stevvooe
Copy link
Member Author

I'm merging this to keep moving. If anyone objects, please let me know.

@stevvooe stevvooe merged commit c2c057a into containerd:master Feb 25, 2017
@stevvooe stevvooe deleted the fetcher-concurrency-bug branch February 25, 2017 02:41
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