karaf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jirka (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (KARAF-4730) Feature not installed - missing requirement osgi.service; effective:=active; filter
Date Sat, 24 Sep 2016 15:04:21 GMT

     [ https://issues.apache.org/jira/browse/KARAF-4730?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Jirka updated KARAF-4730:
-------------------------
    Description: 
I have a feature that works correctly on Karaf 4.0.5. When I try to install it on Karaf 4.0.6,
I get an error.

{code}
2016-09-24 16:03:56,955 | ERROR | nsole user karaf | ShellUtil                        | 43
- org.apache.karaf.shell.core - 4.0.6 | Exception caught while executing command
org.osgi.service.resolver.ResolutionException: Unable to resolve root: missing requirement
[root] osgi.identity; osgi.identity=myapp; type=karaf.feature; version="[1.4.0.SNAPSHOT,1.4.0.SNAPSHOT
]"; filter:="(&(osgi.identity=myapp)(type=karaf.feature)(version>=1.4.0.SNAPSHOT)(version<=1.4.0.SNAPSHOT))"
[caused by: Unable to resolve myapp/1.4.0.SNAPSHOT: missing requirement [myapp/1
.4.0.SNAPSHOT] osgi.identity; osgi.identity=com.myapp.mybundle; type=osgi.bundle; version="[1.4.0.SNAPSHOT,1.4.0.SNAPSHOT]";
resolution:=mandatory [caused by: Unable to resolve com.myapp.mybundle/1.4.0.SNAPSHOT: missing
requirement [com.myapp.mybundle/1.4.0.SNAPSHOT] osgi.service; effective:=active; filter:="(&(objectClass=javax.sql.DataSource)(osgi.jndi.service.n
ame=myDB))"]]
        at org.apache.felix.resolver.ResolutionError.toException(ResolutionError.java:42)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:235)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:158)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:216)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:263)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1176)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.service.FeaturesServiceImpl$1.call(FeaturesServiceImpl.java:1074)[8:org.apache.karaf.features.core:4.0.6]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_92]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_92]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_92]
        at java.lang.Thread.run(Thread.java:745)[:1.8.0_92]
{code} 

The feature has a bundle com.myapp.mybundle with a blueprint file with a reference to a service
registered earlier.
 
{code}
	<reference id="dataSourceRef" interface="javax.sql.DataSource" filter="(osgi.jndi.service.name=myDB)"
/>
{code}

The service is registered correctly with the required interface and property.

When I install the bundle manually from the Karaf shell, it installs correctly.

When I remove the filter from the blueprint reference, 

<reference id="dataSourceRef" interface="javax.sql.DataSource" 
-filter="(osgi.jndi.service.name=myDB)"- />


both the feature and the bundle install correctly.


  was:
I have a feature that works correctly on Karaf 4.0.5. When I try to install it on Karaf 4.0.6,
I get an error.

{code}
2016-09-24 16:03:56,955 | ERROR | nsole user karaf | ShellUtil                        | 43
- org.apache.karaf.shell.core - 4.0.6 | Exception caught while executing command
org.osgi.service.resolver.ResolutionException: Unable to resolve root: missing requirement
[root] osgi.identity; osgi.identity=myapp; type=karaf.feature; version="[1.4.0.SNAPSHOT,1.4.0.SNAPSHOT
]"; filter:="(&(osgi.identity=myapp)(type=karaf.feature)(version>=1.4.0.SNAPSHOT)(version<=1.4.0.SNAPSHOT))"
[caused by: Unable to resolve crystal/1.4.0.SNAPSHOT: missing requirement [myapp/1
.4.0.SNAPSHOT] osgi.identity; osgi.identity=com.myapp.mybundle; type=osgi.bundle; version="[1.4.0.SNAPSHOT,1.4.0.SNAPSHOT]";
resolution:=mandatory [caused by: Unable to resolve com.myapp.mybundle/1.4.0.SNAPSHOT: missing
requirement [com.myapp.mybundle/1.4.0.SNAPSHOT] osgi.service; effective:=active; filter:="(&(objectClass=javax.sql.DataSource)(osgi.jndi.service.n
ame=myDB))"]]
        at org.apache.felix.resolver.ResolutionError.toException(ResolutionError.java:42)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:235)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:158)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:216)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:263)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1176)[8:org.apache.karaf.features.core:4.0.6]
        at org.apache.karaf.features.internal.service.FeaturesServiceImpl$1.call(FeaturesServiceImpl.java:1074)[8:org.apache.karaf.features.core:4.0.6]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_92]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_92]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_92]
        at java.lang.Thread.run(Thread.java:745)[:1.8.0_92]
{code} 

The feature has a bundle com.myapp.mybundle with a blueprint file with a reference to a service
registered earlier.
 
{code}
	<reference id="dataSourceRef" interface="javax.sql.DataSource" filter="(osgi.jndi.service.name=myDB)"
/>
{code}

The service is registered correctly with the required interface and property.

When I install the bundle manually from the Karaf shell, it installs correctly.

When I remove the filter from the blueprint reference, 

<reference id="dataSourceRef" interface="javax.sql.DataSource" 
-filter="(osgi.jndi.service.name=myDB)"- />


both the feature and the bundle install correctly.



> Feature not installed -  missing requirement osgi.service; effective:=active; filter
> ------------------------------------------------------------------------------------
>
>                 Key: KARAF-4730
>                 URL: https://issues.apache.org/jira/browse/KARAF-4730
>             Project: Karaf
>          Issue Type: Bug
>    Affects Versions: 4.0.6
>            Reporter: Jirka
>
> I have a feature that works correctly on Karaf 4.0.5. When I try to install it on Karaf
4.0.6, I get an error.
> {code}
> 2016-09-24 16:03:56,955 | ERROR | nsole user karaf | ShellUtil                      
 | 43 - org.apache.karaf.shell.core - 4.0.6 | Exception caught while executing command
> org.osgi.service.resolver.ResolutionException: Unable to resolve root: missing requirement
[root] osgi.identity; osgi.identity=myapp; type=karaf.feature; version="[1.4.0.SNAPSHOT,1.4.0.SNAPSHOT
> ]"; filter:="(&(osgi.identity=myapp)(type=karaf.feature)(version>=1.4.0.SNAPSHOT)(version<=1.4.0.SNAPSHOT))"
[caused by: Unable to resolve myapp/1.4.0.SNAPSHOT: missing requirement [myapp/1
> .4.0.SNAPSHOT] osgi.identity; osgi.identity=com.myapp.mybundle; type=osgi.bundle; version="[1.4.0.SNAPSHOT,1.4.0.SNAPSHOT]";
resolution:=mandatory [caused by: Unable to resolve com.myapp.mybundle/1.4.0.SNAPSHOT: missing
requirement [com.myapp.mybundle/1.4.0.SNAPSHOT] osgi.service; effective:=active; filter:="(&(objectClass=javax.sql.DataSource)(osgi.jndi.service.n
> ame=myDB))"]]
>         at org.apache.felix.resolver.ResolutionError.toException(ResolutionError.java:42)[8:org.apache.karaf.features.core:4.0.6]
>         at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:235)[8:org.apache.karaf.features.core:4.0.6]
>         at org.apache.felix.resolver.ResolverImpl.resolve(ResolverImpl.java:158)[8:org.apache.karaf.features.core:4.0.6]
>         at org.apache.karaf.features.internal.region.SubsystemResolver.resolve(SubsystemResolver.java:216)[8:org.apache.karaf.features.core:4.0.6]
>         at org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:263)[8:org.apache.karaf.features.core:4.0.6]
>         at org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1176)[8:org.apache.karaf.features.core:4.0.6]
>         at org.apache.karaf.features.internal.service.FeaturesServiceImpl$1.call(FeaturesServiceImpl.java:1074)[8:org.apache.karaf.features.core:4.0.6]
>         at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_92]
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_92]
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_92]
>         at java.lang.Thread.run(Thread.java:745)[:1.8.0_92]
> {code} 
> The feature has a bundle com.myapp.mybundle with a blueprint file with a reference to
a service registered earlier.
>  
> {code}
> 	<reference id="dataSourceRef" interface="javax.sql.DataSource" filter="(osgi.jndi.service.name=myDB)"
/>
> {code}
> The service is registered correctly with the required interface and property.
> When I install the bundle manually from the Karaf shell, it installs correctly.
> When I remove the filter from the blueprint reference, 
> <reference id="dataSourceRef" interface="javax.sql.DataSource" 
> -filter="(osgi.jndi.service.name=myDB)"- />
> both the feature and the bundle install correctly.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message