Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 357492 - Provide artifact repository access without need to know IArtifactDescriptor
Summary: Provide artifact repository access without need to know IArtifactDescriptor
Status: CLOSED WONTFIX
Alias: None
Product: Equinox
Classification: Eclipse Project
Component: p2 (show other bugs)
Version: 3.8.0 Juno   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: P2 Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-13 09:56 EDT by Tobias Oberlies CLA
Modified: 2019-11-14 03:50 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Oberlies CLA 2011-09-13 09:56:42 EDT
The IArtifactRepository interface is quite low-level: With IArtifactDescriptor exposed, one needs to be aware of (and able to handle correctly) the different properties and processing steps associated to an IArtifactDescriptor. This missing isolation leads to bugs and code smells. Examples:
- bug 271707
- org.eclipse.equinox.p2.publisher.AbstractPublisherAction.createPack200ArtifactDescriptor -> why does the publisher need know how to extract pack200 artifacts

There should be an interface (or possibly two for read-only and read/write) which make the most common artifact repository operations possible without knowing IArtifactDescriptor:
- Retrieve a canonical artifact
- Add a canonical artifact
- Add an artifact in non-canonical form (to support pack200 files; optional method)

The default implementation of these interfaces would simply wrap an IArtifactRepository. There could be different implementations with different policies:
- MD5 sum computation on addition
- MD5 sum verification on retrieval
- Ranking between artifact forms, etc.
Currently all these policies are already implemented - somewhere. IMHO we really would as little references to IArtifactDescriptor as possible.
Comment 1 Lars Vogel CLA 2019-11-14 03:50:00 EST
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.

If the bug is still relevant, please remove the "stalebug" whiteboard tag.