aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "John Ross (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ARIES-1147) Installing a subsystems as a transitive dependency via a Repository service fails
Date Tue, 14 Jan 2014 15:58:50 GMT

    [ https://issues.apache.org/jira/browse/ARIES-1147?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13870837#comment-13870837
] 

John Ross commented on ARIES-1147:
----------------------------------

Hi David,

I've only been able to have a quick look so far, but I don't think that is the correct fix.
"subsystem://?Subsystem-SymbolicName=org.osgi.service.subsystem.root&Subsystem-Version=1.0.0!/my-subsystem@0.5.0"
is a syntactically invalid subsystem URI. I see that the subsystems impl is generating it
in ResourceInstaller, line 111. I believe that should be the starting point of any fix. I
would also like to understand more of your scenario. I'm not sure I understand how the root
subsystem is becoming the "provisionTo" for a subsystem that's a repository resource.

I'm not sure it was ever considered that provisionTo.getLocation() could be a subsystem URI
when ResourceInstaller.getLocation() was written. I suspect that we're going to need to allow
for the possibility of a syntactically incorrect subsystem URI under certain circumstances
and treat is as a generic location string.

Would you mind backing that change out for now and attaching it as a patch instead until there's
more time to ferret this out?

> Installing a subsystems as a transitive dependency via a Repository service fails
> ---------------------------------------------------------------------------------
>
>                 Key: ARIES-1147
>                 URL: https://issues.apache.org/jira/browse/ARIES-1147
>             Project: Aries
>          Issue Type: Bug
>          Components: Subsystem
>    Affects Versions: 1.0
>            Reporter: David Bosschaert
>            Assignee: David Bosschaert
>
> When installing a subsystem that contains a bundle which has a dependency that is fulfilled
by another subsystem that is available via a registered Repository Service, an error occurs.
> The exception occurs when constructing a SubsystemUri instance with an uri value of:
{{subsystem://?Subsystem-SymbolicName=org.osgi.service.subsystem.root&Subsystem-Version=1.0.0!/my-subsystem@0.5.0}}
> The full exception is:
> {code}java.lang.IllegalArgumentException: invalid version "1.0.0!/cdi-subsystem@0.5.0":
non-numeric "0!/cdi-subsystem@0"
> 	at org.osgi.framework.Version.parseInt(Version.java:170)
> 	at org.osgi.framework.Version.<init>(Version.java:134)
> 	at org.osgi.framework.Version.parseVersion(Version.java:233)
> 	at org.apache.aries.subsystem.core.internal.SubsystemUri.<init>(SubsystemUri.java:65)
> 	at org.apache.aries.subsystem.core.internal.Location.<init>(Location.java:58)
> 	at org.apache.aries.subsystem.core.internal.RawSubsystemResource.<init>(RawSubsystemResource.java:114)
> 	at org.apache.aries.subsystem.core.internal.SubsystemResourceInstaller.installRepositoryContent(SubsystemResourceInstaller.java:149)
> 	at org.apache.aries.subsystem.core.internal.SubsystemResourceInstaller.install(SubsystemResourceInstaller.java:36)
> 	at org.apache.aries.subsystem.core.internal.SubsystemResourceInstaller.installAriesSubsystem(SubsystemResourceInstaller.java:98)
> 	at org.apache.aries.subsystem.core.internal.SubsystemResourceInstaller.install(SubsystemResourceInstaller.java:38)
> 	at org.apache.aries.subsystem.core.internal.InstallAction.run(InstallAction.java:75)
> 	at org.apache.aries.subsystem.core.internal.InstallAction.run(InstallAction.java:31)
> 	at java.security.AccessController.doPrivileged(Native Method)
> 	at org.apache.aries.subsystem.core.internal.BasicSubsystem.install(BasicSubsystem.java:621)
> 	at org.apache.aries.subsystem.core.internal.BasicSubsystem.install(BasicSubsystem.java:259)
> 	at org.apache.aries.subsystem.core.internal.BasicSubsystem.install(BasicSubsystem.java:63)
> 	at org.coderthoughts.subsystems.gogo.Activator.install(Activator.java:29)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:606)
> 	at org.apache.felix.gogo.runtime.Reflective.invoke(Reflective.java:137)
> 	at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:82)
> 	at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:477)
> 	at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:403)
> 	at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
> 	at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)
> 	at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)
> 	at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)
> 	at org.apache.felix.gogo.shell.Console.run(Console.java:62)
> 	at org.apache.felix.gogo.shell.Shell.console(Shell.java:203)
> 	at org.apache.felix.gogo.shell.Shell.gosh(Shell.java:128)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:606)
> 	at org.apache.felix.gogo.runtime.Reflective.invoke(Reflective.java:137)
> 	at org.apache.felix.gogo.runtime.CommandProxy.execute(CommandProxy.java:82)
> 	at org.apache.felix.gogo.runtime.Closure.executeCmd(Closure.java:477)
> 	at org.apache.felix.gogo.runtime.Closure.executeStatement(Closure.java:403)
> 	at org.apache.felix.gogo.runtime.Pipe.run(Pipe.java:108)
> 	at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:183)
> 	at org.apache.felix.gogo.runtime.Closure.execute(Closure.java:120)
> 	at org.apache.felix.gogo.runtime.CommandSessionImpl.execute(CommandSessionImpl.java:89)
> 	at org.apache.felix.gogo.shell.Activator.run(Activator.java:75)
> 	at java.lang.Thread.run(Thread.java:744)
> Caused by: java.lang.NumberFormatException: For input string: "0!/cdi-subsystem@0"
> 	at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
> 	at java.lang.Integer.parseInt(Integer.java:492)
> 	at java.lang.Integer.parseInt(Integer.java:527)
> 	at org.osgi.framework.Version.parseInt(Version.java:168)
> 	... 45 more{code}



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message