P2 - "No action found for: addRepository" when installing from repository [message #135891] |
Mon, 20 July 2009 13:25 |
Martin H Messages: 2 Registered: July 2009 |
Junior Member |
|
|
Hello everybody,
I'm trying to implement automatic updates for an application using the P2
framework. I have, in my build.properties, specified a path where the P2
artifacts and metadata should be placed.
I have added the following lines to my build.properties
generate.p2.metadata = true
p2.metadata.repo=file:${buildDirectory}/${buildLabel}/${buil dId}/repo
p2.artifact.repo=file:${buildDirectory}/${buildLabel}/${buil dId}/repo
p2.flavor=tooling
p2.publish.artifacts=true
The build process succeeds in creating a repository but when I try to
install my application using this repository I get an error. The command
line I use is
C:\>myapp\myapp.exe -application
org.eclipse.equinox.p2.director.app.application -metadataRepository
file:c:/builtRepo -artifactRepository file:c:/builtRepo -install
IU com.cinnober.cscreen.feature.group -destination c:\installedX86
-profile MyAppProfile -profileProperties
org.eclipse.update.install.features=true -bundlePool c:\installedX86 -
p2.os win32 -p2.ws win32 -p2.arch x86 -roaming -version 1.0.1.200906250932
-vmargs -Declipse.p2.data.area=c:\installedX86\p2
The log file in myapp\configuration contains the following
!SESSION 2009-07-20 14:59:30.216
-----------------------------------------------
eclipse.buildId=unknown
java.version=1.6.0_11
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=sv_SE
Framework arguments: -application
org.eclipse.equinox.p2.director.app.application -metadataRepository
file:c:/builtRepo -artifactRepository file:c:/builtRepo -installIU
com.cinnober.myapp.feature.group -destination c:\installedX86 -profile
myappProfile -profileProperties org.eclipse.update.install.features=true
-bundlePool c:\installedX86 -p2.os win32 -p2.ws win32 -p2.arch x86
-roaming -version 1.0.1.200906251230
Command-line arguments: -os win32 -ws win32 -arch x86 -application
org.eclipse.equinox.p2.director.app.application -metadataRepository
file:c:/builtRepo -artifactRepository file:c:/builtRepo -installIU
com.cinnober.myapp.feature.group -destination c:\installedX86 -profile
myappProfile -profileProperties org.eclipse.update.install.features=true
-bundlePool c:\installedX86 -p2.os win32 -p2.ws win32 -p2.arch x86
-roaming -version 1.0.1.200906251230
!ENTRY org.eclipse.equinox.p2.engine 4 4 2009-07-20 14:59:51.779
!MESSAGE An error occurred while configuring the installed items
!SUBENTRY 1 org.eclipse.equinox.p2.engine 4 0 2009-07-20 14:59:51.779
!MESSAGE No action found for: addRepository.
!STACK 0
java.lang.IllegalArgumentException: No action found for: addRepository.
at
org.eclipse.equinox.internal.p2.engine.InstructionParser.loo kupAction(InstructionParser.java:66)
at
org.eclipse.equinox.internal.p2.engine.InstructionParser.par seAction(InstructionParser.java:44)
at
org.eclipse.equinox.internal.p2.engine.InstructionParser.par seActions(InstructionParser.java:34)
at
org.eclipse.equinox.internal.provisional.p2.engine.Installab leUnitPhase.getActions(InstallableUnitPhase.java:161)
at
org.eclipse.equinox.internal.provisional.p2.engine.phases.Co nfigure.getActions(Configure.java:34)
at
org.eclipse.equinox.internal.provisional.p2.engine.Installab leUnitPhase.getActions(InstallableUnitPhase.java:117)
at
org.eclipse.equinox.internal.provisional.p2.engine.Phase.mai nPerform(Phase.java:111)
at
org.eclipse.equinox.internal.provisional.p2.engine.Phase.per form(Phase.java:79)
at
org.eclipse.equinox.internal.provisional.p2.engine.Installab leUnitPhase.perform(InstallableUnitPhase.java:53)
at
org.eclipse.equinox.internal.provisional.p2.engine.Phase.per form(Phase.java:46)
at
org.eclipse.equinox.internal.provisional.p2.engine.PhaseSet. perform(PhaseSet.java:38)
at
org.eclipse.equinox.internal.provisional.p2.engine.Engine.pe rform(Engine.java:53)
at
org.eclipse.equinox.internal.p2.director.app.Application.pla nAndExecute(Application.java:213)
at
org.eclipse.equinox.internal.p2.director.app.Application.run (Application.java:365)
at
org.eclipse.equinox.internal.p2.director.app.Application.sta rt(Application.java:423)
at
org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:193)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:110)
at
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:79)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:382)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java: 549)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
at org.eclipse.equinox.launcher.Main.run(Main.java:1236)
I'm using eclipse 3.4-1 on Windows x64.
The directory which I've specified to be the destination, c:\installedX86,
is created however and has a "features", "p2", and "plugins" directory
which seems to contain all my plugins.
I'm quite new to Eclipse/RCP applications so I may have done something
totally crazy.
Does anyone have a clue why this error occurs, if indeed it is an error?
One thing I am really interested in knowing is given that you have created
a P2 repository, what is the preferred way of installing a P2-enabled
application for the first time? Do you need an existing eclipse
installation (or some application that contains the P2 director)?
Regards,
/Martin
|
|
|
Re: P2 - "No action found for: addRepository" when installing from repository [message #135906 is a reply to message #135891] |
Mon, 20 July 2009 13:44 |
Laurent Marchal Messages: 91 Registered: July 2009 |
Member |
|
|
Hello Martin,
I had the same error, and it's because you need to use the fully
qualified instruction name to make it work : so just replace
"addRepository" with
"org.eclipse.equinox.p2.touchpoint.eclipse.addRepository"
See
http://wiki.eclipse.org/Equinox/p2/Engine/Touchpoint_Instruc tions#Fully_Qualified_Action_Names_and_Importing_Actions
and the previous posts
http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.techno logy.equinox/msg06476.html
Laurent Marchal.
Martin H a écrit :
> Hello everybody,
> I'm trying to implement automatic updates for an application using the
> P2 framework. I have, in my build.properties, specified a path where the
> P2 artifacts and metadata should be placed.
>
> I have added the following lines to my build.properties
>
> generate.p2.metadata = true
> p2.metadata.repo=file:${buildDirectory}/${buildLabel}/${buil dId}/repo
> p2.artifact.repo=file:${buildDirectory}/${buildLabel}/${buil dId}/repo
> p2.flavor=tooling
> p2.publish.artifacts=true
>
> The build process succeeds in creating a repository but when I try to
> install my application using this repository I get an error. The command
> line I use is
> C:\>myapp\myapp.exe -application
> org.eclipse.equinox.p2.director.app.application -metadataRepository
> file:c:/builtRepo -artifactRepository file:c:/builtRepo -install
> IU com.cinnober.cscreen.feature.group -destination c:\installedX86
> -profile MyAppProfile -profileProperties
> org.eclipse.update.install.features=true -bundlePool c:\installedX86 -
> p2.os win32 -p2.ws win32 -p2.arch x86 -roaming -version
> 1.0.1.200906250932 -vmargs -Declipse.p2.data.area=c:\installedX86\p2
>
> The log file in myapp\configuration contains the following
>
>
> !SESSION 2009-07-20 14:59:30.216
> -----------------------------------------------
> eclipse.buildId=unknown
> java.version=1.6.0_11
> java.vendor=Sun Microsystems Inc.
> BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=sv_SE
> Framework arguments: -application
> org.eclipse.equinox.p2.director.app.application -metadataRepository
> file:c:/builtRepo -artifactRepository file:c:/builtRepo -installIU
> com.cinnober.myapp.feature.group -destination c:\installedX86 -profile
> myappProfile -profileProperties org.eclipse.update.install.features=true
> -bundlePool c:\installedX86 -p2.os win32 -p2.ws win32 -p2.arch x86
> -roaming -version 1.0.1.200906251230
> Command-line arguments: -os win32 -ws win32 -arch x86 -application
> org.eclipse.equinox.p2.director.app.application -metadataRepository
> file:c:/builtRepo -artifactRepository file:c:/builtRepo -installIU
> com.cinnober.myapp.feature.group -destination c:\installedX86 -profile
> myappProfile -profileProperties org.eclipse.update.install.features=true
> -bundlePool c:\installedX86 -p2.os win32 -p2.ws win32 -p2.arch x86
> -roaming -version 1.0.1.200906251230
>
> !ENTRY org.eclipse.equinox.p2.engine 4 4 2009-07-20 14:59:51.779
> !MESSAGE An error occurred while configuring the installed items
> !SUBENTRY 1 org.eclipse.equinox.p2.engine 4 0 2009-07-20 14:59:51.779
> !MESSAGE No action found for: addRepository.
> !STACK 0
> java.lang.IllegalArgumentException: No action found for: addRepository.
> at
> org.eclipse.equinox.internal.p2.engine.InstructionParser.loo kupAction(InstructionParser.java:66)
>
> at
> org.eclipse.equinox.internal.p2.engine.InstructionParser.par seAction(InstructionParser.java:44)
>
> at
> org.eclipse.equinox.internal.p2.engine.InstructionParser.par seActions(InstructionParser.java:34)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.Installab leUnitPhase.getActions(InstallableUnitPhase.java:161)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.phases.Co nfigure.getActions(Configure.java:34)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.Installab leUnitPhase.getActions(InstallableUnitPhase.java:117)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.Phase.mai nPerform(Phase.java:111)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.Phase.per form(Phase.java:79)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.Installab leUnitPhase.perform(InstallableUnitPhase.java:53)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.Phase.per form(Phase.java:46)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.PhaseSet. perform(PhaseSet.java:38)
>
> at
> org.eclipse.equinox.internal.provisional.p2.engine.Engine.pe rform(Engine.java:53)
>
> at
> org.eclipse.equinox.internal.p2.director.app.Application.pla nAndExecute(Application.java:213)
>
> at
> org.eclipse.equinox.internal.p2.director.app.Application.run (Application.java:365)
>
> at
> org.eclipse.equinox.internal.p2.director.app.Application.sta rt(Application.java:423)
>
> at
> org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:193)
>
> at
> org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:110)
>
> at
> org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:79)
>
> at
> org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:382)
>
> at
> org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:179)
>
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java: 549)
> at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
> at org.eclipse.equinox.launcher.Main.run(Main.java:1236)
>
> I'm using eclipse 3.4-1 on Windows x64.
> The directory which I've specified to be the destination,
> c:\installedX86, is created however and has a "features", "p2", and
> "plugins" directory which seems to contain all my plugins.
>
> I'm quite new to Eclipse/RCP applications so I may have done something
> totally crazy.
> Does anyone have a clue why this error occurs, if indeed it is an error?
>
> One thing I am really interested in knowing is given that you have
> created a P2 repository, what is the preferred way of installing a
> P2-enabled application for the first time? Do you need an existing
> eclipse installation (or some application that contains the P2 director)?
>
> Regards,
> /Martin
>
>
|
|
|
|
|
Re: P2 - "No action found for: addRepository" when installing from repository [message #136056 is a reply to message #136032] |
Thu, 23 July 2009 18:30 |
Andrew Niefer Messages: 990 Registered: July 2009 |
Senior Member |
|
|
3.4.1 did not support the addRepository action, it is new in 3.5.
p2.inf was supported in 3.4.1 in a limited fashion only for the
instructions.* properties (which can be used to specify the
addRepository action).
Perhaps you are getting some 3.5 plugins included somehow?
You could do a search through C:/builtRepo/content.xml for
"addRepository" to see which IU has it.
-Andrew
Laurent Marchal wrote:
> Yes I was talking about this file, you really should consider updating
> to 3.5 Galileo, since p2 is way much simpler to setup, and lots of bugs
> has been fixed.
>
> eclipse 3.4.1 has no support for this file, so I can't help you for this
> version.
>
> Laurent.
>
> Martin H a écrit :
>> Hi Laurent,
>> are you referring to the p2.inf file? I have no such file, do I need
>> one? As I mentioned, I'm using Eclipse 3.4-1, can I still build
>> p2-enabled RCP apps with this version?
>>
>> /Martin
>>
|
|
|
Powered by
FUDForum. Page generated in 0.03295 seconds