Skip to content
This repository was archived by the owner on Apr 14, 2021. It is now read-only.

Add cross-application user cache [3975]#3983

Merged
indirect merged 20 commits into2-0-devfrom
3975
Sep 11, 2015
Merged

Add cross-application user cache [3975]#3983
indirect merged 20 commits into2-0-devfrom
3975

Conversation

@stefanlance
Copy link
Copy Markdown
Contributor

@indirect wrote this in response to #3975

@stefanlance stefanlance reopened this Sep 10, 2015
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Raise a proper exception subclass?

@segiddins segiddins deleted the 3975 branch November 17, 2015 07:53
@coilysiren coilysiren modified the milestone: 2.0 — Breaking Changes Oct 9, 2016
bundlerbot added a commit that referenced this pull request Jun 22, 2017
[2.0] Add a global cache for downloaded .gem files

### What was the end-user problem that led to this PR?

The problem was that bundler would need to download `foo-1.0.gem` files from a RubyGems server for each different ruby version installed on a user's machine. It also meant that people installing into a per-app path would need to re-download every gem for that bundle an additional time. This adds up, and makes `bundle install` slower than it needs to be.

### Was was your diagnosis of the problem?

My diagnosis was that Bundler could keep a (per-source) cache of these `.gem` files, and pull from that cache instead of hitting the network whenever possible.

### What is your fix for the problem, implemented in this PR?

My fix implements said cache, in a very similar way to the compact index cache (same cache slug per remote strategy, etc). This largely comes from #3983.

### Why did you choose this fix out of the possible options?

I chose this fix because it is safe when used from multi-source gemfiles, it is easy to clear (`rm -rf bundle cache`), and it minimally interferes with the existing installation process.
bundlerbot added a commit that referenced this pull request Jun 22, 2017
[2.0] Add a global cache for downloaded .gem files

### What was the end-user problem that led to this PR?

The problem was that bundler would need to download `foo-1.0.gem` files from a RubyGems server for each different ruby version installed on a user's machine. It also meant that people installing into a per-app path would need to re-download every gem for that bundle an additional time. This adds up, and makes `bundle install` slower than it needs to be.

### Was was your diagnosis of the problem?

My diagnosis was that Bundler could keep a (per-source) cache of these `.gem` files, and pull from that cache instead of hitting the network whenever possible.

### What is your fix for the problem, implemented in this PR?

My fix implements said cache, in a very similar way to the compact index cache (same cache slug per remote strategy, etc). This largely comes from #3983.

### Why did you choose this fix out of the possible options?

I chose this fix because it is safe when used from multi-source gemfiles, it is easy to clear (`rm -rf bundle cache`), and it minimally interferes with the existing installation process.
bundlerbot added a commit that referenced this pull request Jun 27, 2017
[2.0] Add a global cache for downloaded .gem files

### What was the end-user problem that led to this PR?

The problem was that bundler would need to download `foo-1.0.gem` files from a RubyGems server for each different ruby version installed on a user's machine. It also meant that people installing into a per-app path would need to re-download every gem for that bundle an additional time. This adds up, and makes `bundle install` slower than it needs to be.

### Was was your diagnosis of the problem?

My diagnosis was that Bundler could keep a (per-source) cache of these `.gem` files, and pull from that cache instead of hitting the network whenever possible.

### What is your fix for the problem, implemented in this PR?

My fix implements said cache, in a very similar way to the compact index cache (same cache slug per remote strategy, etc). This largely comes from #3983.

### Why did you choose this fix out of the possible options?

I chose this fix because it is safe when used from multi-source gemfiles, it is easy to clear (`rm -rf bundle cache`), and it minimally interferes with the existing installation process.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants