Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Medium
-
Resolution: Fixed
-
Affects Version/s: 3.28.1
-
Fix Version/s: 3.29.1
-
Component/s: Blobstore, Repository, Scheduled Tasks
-
Labels:
-
Notability:3
Description
- Start Nexus Repo 3.28.1, upload some content to a repository
- Create a new blob store
- Promote that blob store to a group
- Create an "admin - change repository blob store" task. For the destination blob store choose the promoted blob store.
- Run the task
This will fail with errors. Note: The task should not allow saving if a promoted blob store is chosen, but it does.
Observe that the repository still functions normally, content can be downloaded.
- Create a new blob store
- Change the destination repository in the "admin - change repository blob store" task to be the new blob store
- Run the task.
The task appears to work, but the attempts to download any files from the repository fail with error. The logs show the blob files cannot be found.
Examination of the task log shows warnings, and NPE's logged at INFO level:
2020-11-16 13:59:53,073-0600 WARN [change-blobstore-moves-3-thread-5] *SYSTEM org.sonatype.nexus.blobstore.file.FileBlobStore - Attempt to access non-existent blob 2abfc011-2827-4105-8f43-75292d704e50 (/Users/rseddon/temp/sonatype-work/nexus3/blobs/abc/content/vol-31/chap-19/2abfc011-2827-4105-8f43-75292d704e50.properties)
2020-11-16 13:59:53,075-0600 INFO [change-blobstore-moves-3-thread-9] *SYSTEM com.sonatype.nexus.repository.move.internal.MoveBlobService - Failed to move blob with id: af3ab30f-48a9-40e5-a8e4-e88967365c64
java.lang.NullPointerException: null
at org.sonatype.nexus.repository.internal.blobstore.BlobStoreManagerImpl.moveBlob(BlobStoreManagerImpl.java:407)
at com.sonatype.nexus.repository.move.internal.MoveBlobService.lambda$1(MoveBlobService.java:72)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at org.sonatype.nexus.thread.internal.MDCAwareRunnable.run(MDCAwareRunnable.java:40)
at org.apache.shiro.subject.support.SubjectRunnable.doRun(SubjectRunnable.java:120)
at org.apache.shiro.subject.support.SubjectRunnable.run(SubjectRunnable.java:108)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Mitigation: Use an "admin - change repository blob store" task to move the repository back to the original blob store. This will restore consistency.
Attachments
Issue Links
- relates
-
NEXUS-25904 The "admin - change repository blob store" task should not allow selection of a promoted blob store
-
- Closed
-