Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] Upgrades through ProfileChangeRequest

The PCR is the lowest level mechanism to reason about what is installed. As such it does not enforce any policy to automatically detect updates from things that are already installed.

Some of the logic you are looking for is available in the org.eclipse.equinox.p2.operations bundle.

If using operations is not a possibility for you, then you will have to detect the presence of the IU you are trying to install by querying the profile.

On 2010-04-07, at 12:28 PM, Matt Hughes wrote:

> I have a pretty simple use case I believe.  I want to install an
> artifact via a ProfileChangeRequest and if an earlier version of that
> artifact already exists, I want to remove the old version and install
> the new version.
> 
> For some reason, I thought all I had to do was mark the addition to
> the PCR, hand it to the IDirector and it would figure out the upgrade
> (that is, add a removal action for the old version).  I realize that
> doesn't work -- at least not as I am doing it now -- but isn't there
> some way to tell P2 (via requirements, maybe?) to perform the upgrade?
> 
> Unless I'm missing something, it is up to the developer to search
> through their repositories and mark the old versions as removals in
> the PCR.  Seems like this is a pretty basic use case.
> _______________________________________________
> p2-dev mailing list
> p2-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/p2-dev



Back to the top