Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] what is "org.eclipse.equinox.p2.type.lock"

ok, I'm a bit closer to the problem.

it's related to eclipse.p2.data.area property in configuration/config.ini
Initially, when product is first installed, eclipse.p2.data.area points to absolute path in product main install dir, e.g. "file\:/Applications/Abc/eclipse/p2"
At this time, everything seems possible to update and remove, at least from p2 UI.
After any provisioning operation, the eclipse.p2.data.area get's replaced with relative path "@config/../p2"

Now on next product run, a new p2 folder is created next to cascaded configuration area - somewhere in user directory. (Although this folder never existed before)
From now on, nothing seems possible to update or uninstall from p2 UI.

Now if I create a symbolic link from cascaded/p2 to /Applcations/Abc/eclipse/p2 all is updateable again.


So If I'm getting this correctly, p2 converts eclipse.p2.data.area absolute path to relative path with "@config" and then resolves "@config" variable to cascaded directory, instead of main directory.




2011/3/22 Jacek Pospychała <jacek.pospychala@xxxxxxxxx>
hi,

I'm trying to understand what is this property "org.eclipse.equinox.p2.type.lock", who sets it and why.


Basically, there's a Mac product with extreemly confusing configuration. It uses cascaded configuration areas, 
a shared bundle pool and another one in user directory. It has some top level features that are not updateable (no matter if I'm root or regular user).
At the top of that product, I'm installing my feature. Unfortunately, after installing it, I can't update it due to "updates are not permitted" error.

So far, I found that this is caused by org.eclipse.equinox.p2.type.lock property set to 3 for my feature IU in profile metadata.
If I replace property with 1, then update goes one step further and fails somewhere else. (yay!)

So I'm wondering if anybody knows how does p2 decide to set the lock property on newly installed feature.
Is there any documentation for that, or is there any good place to set a breakpoint? e.g. during the installation or during first start?


Thanks in advance!

Jacek





Back to the top