Why is my RCP eclipse product blocked and cannot be updated?

I am creating an RCP-based product on Eclipse, and I encounter a problem when, when I try to use the built-in user interface p2 to install updates for the product, I get an error message in the dialog "There are not enough access privileges to apply this update."

I was debugging in Eclipse and found that the β€œroot cause” is the p2.profile file with xml, which includes this snippet:

<iuProperties id='com.datical.db.ui.product' version='1.33.0.201412032223'> <properties size='4'> <property name='org.eclipse.equinox.p2.internal.inclusion.rules' value='STRICT'/> <property name='org.eclipse.equinox.p2.type.root' value='true'/> <property name='org.eclipse.equinox.p2.type.lock' value='3'/> <property name='org.eclipse.equinox.p2.base' value='true'/> </properties> </iuProperties> 

The corresponding line corresponds to the line <property name='org.eclipse.equinox.p2.type.lock' value='3'/>

I'm not sure what I'm doing wrong. I think that I should have something bad in defining a product or defining my function or in my installation process that calls this line.

When I look at the Eclipse code (our target environment is 3.7 / Indigo), I see the profile being written inside org.eclipse.equinox.internal.p2.engine:SurrogateProfileHandler:addSharedProfileBaseIUs (which is private static.) This is called from SurrogateProfileHandler:createProfile

The product p2 repository is built using tycho plugins version 0.15.

+5
source share
3 answers

Finally, we discovered another piece of information that may be relevant. We used the custom OSGI directory name. When we removed this, everything started working as expected.

+1
source

It seems that you have a common installation where the product you want to update is potentially used by many installations as a base - and therefore cannot be updated.

0
source

Such a problem goes beyond the fact that you can respond well to stackoverflow, because you really need to provide an example project and exact steps to reproduce the problem.

The most likely cause of the symptoms you see is some file system resolution issue. This documentation mentions that you need permission to write to the installation directory to run Eclipse using -initialize . You may be missing some permissions, which is why some of the -initialize procedures fail and leave the installation in an inconsistent state.

0
source

Source: https://habr.com/ru/post/1208307/


All Articles