Skip to content
This repository has been archived by the owner on Oct 27, 2020. It is now read-only.

Running multiple processes #20

Open
langri-sha opened this issue Nov 11, 2017 · 2 comments
Open

Running multiple processes #20

langri-sha opened this issue Nov 11, 2017 · 2 comments

Comments

@langri-sha
Copy link

langri-sha commented Nov 11, 2017

I would like to know whether there are any unintended consequences from using cache-loader from multiple processes writing into the same cache directory?

To give a bit of a background, I would like to create a manager for my project that would handle requests for building checked out project sources in parallel. At the moment, I am constructing a strong hash from the environment for all the loader dependencies that's added as a component to the cache output path.

I am curious if there would be any issues when I try to run two parallel builds when the environments are not different (cache output directories are the same), but my project sources changed? If so, perhaps this is something that might be added to the README.

@michael-ciniawsky
Copy link
Member

Did you have time to test this out ? :)

@juanca
Copy link

juanca commented Nov 16, 2017

I am using happypack@4.0.0. where all each of my loaders are split into 4 processes with their own cache-loader.

I haven't run into major issues.

There are some hiccups where the cache is stale and it is not being updated automatically (which, at the moment, my team fixes by blowing away all the cache) -- and I personally have not been able to reproduce, but it seems to be related with switching git branches.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants