You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@karaf.apache.org by kilkenny <ki...@gmail.com> on 2016/04/12 12:24:04 UTC

Problem with 'Unable to resolve root: missing requirement'

I use the karaf-maven-plugin for building my own custom distribution.
When i start karaf with karaf.bat i get the following error:

/Error installing boot features
org.osgi.service.resolver.ResolutionException: Unable to resolve root:
missing requirement [root] osgi.identity; osgi.identity=*package*;
type=karaf.feature; version="[4.0.4,4.0.4]";
filter:="(&(osgi.identity=package)(type=karaf.feature)(version>=4.0.4)(version<=4.0.4))"/

HereĀ“s my setup:
Karaf 4.0.4
karaf-maven-plugin 4.0.4

This is my main pom:


<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

		 <parent>
    <groupId>de.db.fkfmip.karaf.release</groupId>
    <artifactId>my.feature.release</artifactId>
        <version>1.0</version>
    </parent>
	
    <groupId>org.apache.karaf</groupId>
    <artifactId>Karaf-Delivery</artifactId>
    <version>1.0</version>
    <packaging>karaf-assembly</packaging>
    <name>Karaf - Delivery</name>
	
	
    <dependencies>
    <dependency> 
             <groupId>org.apache.karaf.features</groupId> 
             <artifactId>framework</artifactId> 
             <version>4.0.4</version> 
             <type>kar</type> 
         </dependency> 
         <dependency> 
             <groupId>org.apache.karaf.features</groupId> 
             <artifactId>framework</artifactId> 
             <version>4.0.4</version> 
             <classifier>features</classifier> 
             <type>xml</type> 
             <scope>runtime</scope> 
         </dependency> 
        <dependency>
            <groupId>org.apache.karaf.features</groupId>
            <artifactId>standard</artifactId>
            <version>4.0.4</version>
            <classifier>features</classifier>
            <type>xml</type>
        </dependency>

		<dependency>
            <groupId>org.apache.karaf.features</groupId>
            <artifactId>my_feature</artifactId>
			<version>1.0</version>
            <classifier>features</classifier>
            <type>xml</type>
        </dependency>



	</dependencies>

    <build>
        
        <resources>
            <resource>
                <directory>src/main/resources</directory>
                <filtering>false</filtering>
                <includes>
                    <include>**/*</include>
                </includes>
            </resource>
            <resource>
                <directory>src/main/filtered-resources</directory>
                <filtering>true</filtering>
                <includes>
                    <include>**/*</include>
                </includes>
            </resource>
        </resources>

        <plugins>
            
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-resources-plugin</artifactId>
                <version>2.6</version>
                <executions>
                    <execution>
                        <id>process-resources</id>
                        <goals>
                            <goal>resources</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            
            <plugin>
                <groupId>org.apache.karaf.tooling</groupId>
                <artifactId>karaf-maven-plugin</artifactId>
                <extensions>true</extensions>
		<version>4.0.4</version>
                <configuration>
                     <installedFeatures> 
                         <feature>wrapper</feature> 
                     </installedFeatures> 
                     <startupFeatures> 
                         <feature>eventadmin</feature>
                     </startupFeatures> 
                    <bootFeatures>
					
			 <feature>framework</feature> 
                         <feature>wrap</feature> 
                         <feature>shell</feature> 
                         <feature>shell-compat</feature> 
                         <feature>feature</feature> 
                         <feature>jaas</feature> 
                         <feature>ssh</feature> 
                         <feature>management</feature> 
                         <feature>bundle</feature> 
                         <feature>config</feature> 
                         <feature>deployer</feature> 
                         <feature>feature</feature> 
                         <feature>instance</feature> 
                         <feature>kar</feature> 
                         <feature>log</feature> 
                         <feature>package</feature>
                         <feature>service</feature> 
                         <feature>system</feature>
                        <feature>standard</feature>
						
                        <feature>my_feature</feature>


		     </bootFeatures>
                </configuration>
            </plugin>
        </plugins>
    </build>
</project>

Since my feature(s) are quite large it takes up to 50seconds till karaf is
started. When karaf is up, i can see all the bundles in the shell. But when
i try to see the installed and startup features (feature:list) i get the
message that no feature is available.
My idea was that maybe there is some timout for installing and starting the
bundles ?
I already set the logging to DEBUG but i have not gotten more information
about this issue and i am helpless.



--
View this message in context: http://karaf.922171.n3.nabble.com/Problem-with-Unable-to-resolve-root-missing-requirement-tp4046226.html
Sent from the Karaf - Dev mailing list archive at Nabble.com.