[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[p2-dev] Mirroring a subset of a p2 repo

Hi p2,

I want to mirror a subset of a p2 repo, or to be more precise, to mirror one or more root IUs and all their (transitive) dependencies. The use case is to produce a local p2 repo, which I can use as a target platform for unit testing. p2 director does something very similar, but in addition to downloading the artifacts, it also installs them. PDE Build actually does support runnable eclipse installations as target platforms, but we use Tycho, which only supports p2 repositories as target platforms.

I've tried to use p2 mirror task, but it seems that one has to explicitly include/exclude IU or otherwise everything is mirrored. There is no support for recursively resolving and adding dependencies. On the other hand, p2 director can automatically resolve all the dependencies and download them together with the root IU, but there seem to be no way to skip IU installation.

What I have so far come up with is to first run p2 director to create an installation which includes all the bundles I want and only them, and after it to run p2 features and bundles publisher to create metadata from plugins/ and features/ directories in this installation. However, this looks like a kludge. Does anybody know if there is an easier and better way to achieve my goal? Shall I file an issue to add this function either to p2 mirror or to p2 director? Finally, in general what are advantages and drawbacks of using a p2 repo instead of a runnable installation as a target platform, form p2 point of view?

Kind regards, 
Mikhail Kalkov 

Purple Scout AB 
Software Developer

Address: Kyrkogatan 20-22, SE-41110 Gothenburg, Sweden
Phone:   +46 (0) 732 - 051405
E-mail:  mikhail.kalkov@xxxxxxxxxxxxxx
Web:     www.purplescout.se