2016-04-18 10 views
1

Ich habe versucht, ein OSGI-Bundle über Fabric zu fusionieren. Ich bekomme die Abhängigkeit von Oracle JDBC ist nicht gefunden Fehler. Das Projekt wird lokal gut ausgeführt. Wenn Sie jedoch versuchen, es als Fabric-Profil und dann als Container zu fusionieren, schlägt es fehl.Osgi Oracle JDBC-Treiber JBoss Fuse 6.2.1:

Es gab ähnliche Frage Red Hat JBoss Fuse 6.2.1: Osgi Missing Requirement: Oracle JDBC Driver im Forum, die sagen, das Problem durch Ausführen (ersetzt die richtige Versionsnummer)

install -s wrap:mvn:com.oracle/ojdbc6/<version> 

Was ich versuchte, so gut gelöst wurde. Ich kann das Orakel Abhängigkeit in den Merkmalen sehen: Listenausgabe, aber die Sicherung Behälter immer noch nicht mit dem Fehler

java.lang.Exception: Unable to create resource for bundle fab:mvn:com.oracle/ojdbc6/11.2.0.4

Jeder da draußen, der helfen kann. Detaillierte Fehler:

io.fabric8.common.util.MultiException: Error 
    at io.fabric8.agent.download.impl.MavenDownloadManager$MavenDownloader.(MavenDownloadManager.java:93) 
    at io.fabric8.agent.download.impl.MavenDownloadManager.createDownloader(MavenDownloadManager.java:71) 
    at io.fabric8.agent.region.Subsystem.downloadBundles(Subsystem.java:329) 
    at io.fabric8.agent.region.SubsystemResolver.resolve(SubsystemResolver.java:182) 
    at io.fabric8.agent.service.Deployer.deploy(Deployer.java:273) 
    at io.fabric8.agent.service.Agent.provision(Agent.java:366) 
    at io.fabric8.agent.service.Agent.provision(Agent.java:199) 
    at io.fabric8.agent.DeploymentAgent.doUpdate(DeploymentAgent.java:727) 
    at io.fabric8.agent.DeploymentAgent$4.run(DeploymentAgent.java:283) 
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) 
    at java.util.concurrent.FutureTask.run(FutureTask.java:262) 
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) 
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) 
    at java.lang.Thread.run(Thread.java:745) 
java.lang.Exception: Unable to create resource for bundle fab:mvn:com.oracle/ojdbc6/11.2.0.4 
    at io.fabric8.agent.region.Subsystem.createResource(Subsystem.java:491) 
    at io.fabric8.agent.region.Subsystem$ResourceBuilderCallback.downloaded(Subsystem.java:422) 
    at io.fabric8.agent.download.impl.MavenDownloadManager$MavenDownloader$1.operationComplete(MavenDownloadManager.java:143) 
    at io.fabric8.agent.download.impl.MavenDownloadManager$MavenDownloader$1.operationComplete(MavenDownloadManager.java:137) 
    at io.fabric8.agent.download.impl.DefaultFuture.notifyListener(DefaultFuture.java:343) 
    at io.fabric8.agent.download.impl.DefaultFuture.notifyListeners(DefaultFuture.java:328) 
    at io.fabric8.agent.download.impl.DefaultFuture.setValue(DefaultFuture.java:254) 
    at io.fabric8.agent.download.impl.AbstractDownloadTask.setFile(AbstractDownloadTask.java:53) 
    at io.fabric8.agent.download.impl.AbstractRetryableDownloadTask.run(AbstractRetryableDownloadTask.java:41) 
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) 
    at java.util.concurrent.FutureTask.run(FutureTask.java:262) 
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:178) 
    at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:292) 
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) 
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) 
    at java.lang.Thread.run(Thread.java:745) 
Caused by: org.osgi.framework.BundleException: Unsupported 'Bundle-ManifestVersion' value: 1 
    at io.fabric8.agent.resolver.ResourceBuilder.build(ResourceBuilder.java:72) 
    at io.fabric8.agent.resolver.ResourceBuilder.build(ResourceBuilder.java:65) 
    at io.fabric8.agent.region.Subsystem.createResource(Subsystem.java:489) 
... 15 more 

Die pom-Datei verwendet wird:

<?xml version="1.0" encoding="UTF-8"?> 
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" 
    xmlns="http://maven.apache.org/POM/4.0.0" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> 
    <modelVersion>4.0.0</modelVersion> 
    <groupId>com.mycompany.cbp.dv</groupId> 
    <artifactId>demo-cbp-dv</artifactId> 
    <version>1.0.0-SNAPSHOT</version> 
    <name>demo app </name> 
    <url>http://www.demhas.com</url> 
    <packaging>bundle</packaging> 
    <properties> 

    <fabric8.profile>demhas-cbp-dv</fabric8.profile> 

    <fabric8.features>feature-camel</fabric8.features> 
    <fabric8.bundles>wrap:mvn:com.oracle/ojdbc6/${ojdbc-version} 
        wrap:mvn:commons-dbcp/commons-dbcp/${commons-dbcp-version} 
        wrap:mvn:org.json/json/${json-version} 
    </fabric8.bundles> 


    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> 
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
    <activemq-version>5.10.0</activemq-version> 
    <jackson-version>2.5.4</jackson-version> 
    <json-version>20150729</json-version> 
    <json2-version>20140107</json2-version> 
    <slf4j-version>1.7.12</slf4j-version> 
    <log4j-version>1.2.17</log4j-version> 
    <ojdbc-version>11.2.0.4</ojdbc-version> 
    <commons-dbcp-version>1.4</commons-dbcp-version> 
    <camel-version>2.15.2</camel-version> 

    <fabic8-version>1.2.0.redhat-133</fabic8-version> 

    </properties> 

    <dependencies> 
     <dependency> 
     <groupId>org.ow2.asm</groupId> 
     <artifactId>asm-commons</artifactId> 
     <version>4.1</version> 
     <scope>runtime</scope> 
    </dependency> 

    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-core</artifactId> 
     <version>${camel-version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-blueprint</artifactId> 
     <version>${camel-version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-salesforce</artifactId> 
     <version>${camel-version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-http</artifactId> 
     <version>${camel-version}</version> 
    </dependency> 

    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-jsonpath</artifactId> 
     <version>${camel-version}</version> 
    </dependency> 

    <dependency> 
     <groupId>org.slf4j</groupId> 
     <artifactId>slf4j-api</artifactId> 
     <version>${slf4j-version}</version> 
    </dependency> 

    <dependency> 
     <groupId>org.slf4j</groupId> 
     <artifactId>slf4j-log4j12</artifactId> 
     <version>${slf4j-version}</version> 
    </dependency> 

    <dependency> 
     <groupId>log4j</groupId> 
     <artifactId>log4j</artifactId> 
     <version>${log4j-version}</version> 
    </dependency> 

    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-mybatis</artifactId> 
     <version>${camel-version}</version> 
    </dependency> 

    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-test-blueprint</artifactId> 
     <version>${camel-version}</version> 
     <scope>test</scope> 
    </dependency> 

    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-test</artifactId> 
     <version>${camel-version}</version> 
     <scope>test</scope> 
    </dependency> 

    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-jackson</artifactId> 
     <version>${camel-version}</version> 
    </dependency>  

    <dependency> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-jaxb</artifactId> 
     <version>${camel-version}</version> 
    </dependency> 

     <dependency> 
      <groupId>com.oracle</groupId> 
      <artifactId>ojdbc6</artifactId> 
      <version>${ojdbc-version}</version> 
     </dependency> 
    <dependency> 
     <groupId>commons-dbcp</groupId> 
     <artifactId>commons-dbcp</artifactId> 
     <version>${commons-dbcp-version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.apache.activemq</groupId> 
     <artifactId>activemq-client</artifactId> 
     <version>${activemq-version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.apache.activemq</groupId> 
     <artifactId>activemq-camel</artifactId> 
     <version>${activemq-version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.apache.activemq</groupId> 
     <artifactId>activemq-pool</artifactId> 
     <version>${activemq-version} </version> 
     <scope>provided</scope> 
    </dependency> 
    <dependency> 
     <groupId>org.json</groupId> 
     <artifactId>json</artifactId> 
     <version>${json-version}</version> 
    </dependency> 
    </dependencies> 
    <repositories> 
    <repository> 
     <releases> 
     <enabled>true</enabled> 
     </releases> 
     <snapshots> 
     <enabled>false</enabled> 
     </snapshots> 
     <id>public.fusesource.org</id> 
     <name>FuseSource Public Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/groups/public/</url> 
    </repository> 
    <repository> 
     <releases> 
     <enabled>true</enabled> 
     </releases> 
     <snapshots> 
     <enabled>false</enabled> 
     </snapshots> 
     <id>release.fusesource.org</id> 
     <name>FuseSource Release Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/repositories/releases</url> 
    </repository> 
    <repository> 
     <releases> 
     <enabled>true</enabled> 
     </releases> 
     <snapshots> 
     <enabled>false</enabled> 
     </snapshots> 
     <id>ea.fusesource.org</id> 
     <name>FuseSource Community Early Access Release Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/groups/ea</url> 
    </repository> 
    <repository> 
     <releases> 
     <enabled>false</enabled> 
     </releases> 
     <snapshots> 
     <enabled>true</enabled> 
     </snapshots> 
     <id>snapshot.fusesource.org</id> 
     <name>FuseSource Snapshot Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/repositories/snapshots</url> 
    </repository> 
    </repositories> 
    <pluginRepositories> 
    <pluginRepository> 
     <releases> 
     <enabled>true</enabled> 
     </releases> 
     <snapshots> 
     <enabled>false</enabled> 
     </snapshots> 
     <id>public.fusesource.org</id> 
     <name>FuseSource Public Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/groups/public</url> 
    </pluginRepository> 

    <pluginRepository> 
     <releases> 
     <enabled>true</enabled> 
     </releases> 
     <snapshots> 
     <enabled>false</enabled> 
     </snapshots> 
     <id>release.fusesource.org</id> 
     <name>FuseSource Release Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/repositories/releases</url> 
    </pluginRepository> 
    <pluginRepository> 
     <releases> 
     <enabled>true</enabled> 
     </releases> 
     <snapshots> 
     <enabled>false</enabled> 
     </snapshots> 
     <id>ea.fusesource.org</id> 
     <name>FuseSource Community Early Access Release Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/groups/ea</url> 
    </pluginRepository> 
    <pluginRepository> 
     <releases> 
     <enabled>false</enabled> 
     </releases> 
     <snapshots> 
     <enabled>true</enabled> 
     </snapshots> 
     <id>snapshot.fusesource.org</id> 
     <name>FuseSource Snapshot Repository</name> 
     <url>http://repo.fusesource.com/nexus/content/repositories/snapshots</url> 
    </pluginRepository> 
    </pluginRepositories> 
    <build> 
    <defaultGoal>install</defaultGoal> 
    <plugins> 
     <plugin> 
     <groupId>org.apache.felix</groupId> 
     <artifactId>maven-bundle-plugin</artifactId> 
     <version>2.3.7</version> 
     <extensions>true</extensions> 
     <configuration> 
      <instructions> 
      <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName> 
      <Private-Package>com.mycompany.*</Private-Package> 
      <Import-Package>*</Import-Package> 
      </instructions> 
     </configuration> 
     </plugin> 
     <plugin> 
     <groupId>org.apache.camel</groupId> 
     <artifactId>camel-maven-plugin</artifactId> 
     <version>${camel-version}</version> 
     <configuration> 
      <useBlueprint>true</useBlueprint> 
     </configuration> 
     </plugin> 
     <!-- fabric8 plugin for using deploying via mvn fabric:deploy --> 
     <plugin> 
     <groupId>io.fabric8</groupId> 
     <artifactId>fabric8-maven-plugin</artifactId> 
     <version>${fabic8-version}</version> 
     </plugin> 

    </plugins> 
    </build> 

</project> 
+0

, das wie ein Problem Stoff Agent aussieht. Es versucht, den "fab" -Typ anstelle des bnd-Wrap zu verwenden. –

Antwort

0

wie das Glas schaut nicht in einem Repository im Hinblick auf die Sicherung Behälter. Haben Sie den Oracle-Jar in einem Online-Maven-Repository oder in einem lokalen Bereich des Fuse-Containers implementiert?

Ich bin erfolgreich in den Befehl in Ihrem Beitrag erwähnt ausgeführt wird, nachdem die JAR-Datei in die MVN Repo bereitstellen:

> install -s wrap:mvn:com.oracle/ojdbc6/11.2.0.3