Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 3.9.0
-
Fix Version/s: 3.13.0
-
Labels:
-
Story Points:1
Description
After installing bundler using the "gem" command, I have these two files in my blobstore:
$ find . -name \*.properties | xargs grep dep |grep bundle.ruby ./default/content/vol-14/chap-12/2275cf69-8d11-4358-9db3-aeef478ab151.properties:@BlobStore.blob-name=/dependencies/bundle.ruby ./default/content/vol-42/chap-03/22c81bc4-835b-4fdc-9fb4-2e3f3ee36707.properties:@BlobStore.blob-name=/dependencies/bundle.ruby
After this, I expired cache in my rubygems.org proxy repository, and then requested this (just once):
http://localhost:8081/repository/rubygems-proxy/api/v1/dependencies?gems=bundle
And now I have:
$ find . -name \*.properties | xargs grep dep |grep bundle.ruby ./default/content/vol-14/chap-12/2275cf69-8d11-4358-9db3-aeef478ab151.properties:@BlobStore.blob-name=/dependencies/bundle.ruby ./default/content/vol-23/chap-47/c3542d69-4f1c-476c-8ed4-2e4e2dd9f71a.properties:@BlobStore.blob-name=/dependencies/bundle.ruby ./default/content/vol-01/chap-41/8d4ed298-039b-4d9f-bca5-55d9ab09c1fe.properties:@BlobStore.blob-name=/dependencies/bundle.ruby ./default/content/vol-42/chap-03/22c81bc4-835b-4fdc-9fb4-2e3f3ee36707.properties:@BlobStore.blob-name=/dependencies/bundle.ruby
Those older blobs are not marked for deletion, running compact blobstore does not remove them.
Every time cache expires and the dependency request is made two more dependency files are cached. Over time, these will consume quite a lot of space.
Expected:
- Older dependency files should be deleted as new ones are downloaded from the remote.
- Ideally, if the content of the file has not changed, no new file will be stored.
- We will need to publish a groovy script that can find the "orphaned" dependency blobs created by this bug and delete them.