Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 329540

Summary: [repository] CompositeMetadataRepository#createMemoryComposite(IProvisioningAgent) is not thread safe
Product: [Eclipse Project] Equinox Reporter: Dean Roberts <dean.t.roberts>
Component: p2Assignee: P2 Inbox <equinox.p2-inbox>
Status: RESOLVED WONTFIX QA Contact:
Severity: minor    
Priority: P3 CC: aniefer, irbull, pascal
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard: stalebug

Description Dean Roberts CLA 2010-11-05 09:02:40 EDT
Build Identifier: I20101025-1800

The method constructs a unique URI to pass to IMetadataRepositoryManager.createRepository() in a non-atomic fashion.  Allowing the remote possibility of collision.

This, combined with the gratuitous addition and removal of the in memory repository from the repository manager may argue for the creation of IMetadataRepositoryManager API to create an in memory only repo.  Such API would not need to be passed a URI and, internally, would not need to store the returned repo.

Reproducible: Always
Comment 1 Ian Bull CLA 2010-11-09 17:40:10 EST
I've been told that using 'in memory composites' is really just used for testing purposes. I've tried to use them for other uses and hit some different problems (mem:// is not a real URI prefix).
Comment 2 Andrew Niefer CLA 2010-11-09 18:09:48 EST
Memory composites are used by the publisher and tools like repo2runnable and mirror to group the input repos together.
Comment 3 Ian Bull CLA 2010-11-09 19:13:59 EST
Yep, I've seen them used in the publisher too (that's where I got the idea). IIRC, I had problems when I tried to use the memory composites with the planner / engine.
Comment 4 Eclipse Genie CLA 2019-03-11 18:11:50 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 5 Lars Vogel CLA 2019-10-08 10:47:49 EDT
This bug was marked as stalebug a while ago. Marking as wontfix.

If this report is still relevant for the current release, please
reopen and remove the stalebug whiteboard tag.