You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2016/03/12 10:31:34 UTC
[1/5] camel git commit: Polished
Repository: camel
Updated Branches:
refs/heads/master e095075b0 -> 7fe487c68
Polished
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/7fe487c6
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/7fe487c6
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/7fe487c6
Branch: refs/heads/master
Commit: 7fe487c68229a7f5cd297cf7b7db53466373621e
Parents: 8c2fa73
Author: Claus Ibsen <da...@apache.org>
Authored: Sat Mar 12 10:30:40 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Sat Mar 12 10:31:26 2016 +0100
----------------------------------------------------------------------
.../camel/itest/karaf/AbstractFeatureTest.java | 20 +++++---------------
1 file changed, 5 insertions(+), 15 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/7fe487c6/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
index 60218ec..63f1688 100644
--- a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
+++ b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
@@ -60,14 +60,13 @@ public abstract class AbstractFeatureTest {
@Before
public void setUp() throws Exception {
- LOG.info("Calling the setUp method ");
- LOG.info("The BundleContext is " + bundleContext);
+ LOG.info("setUp() using BundleContext: {}", bundleContext);
Thread.sleep(3000);
}
@After
public void tearDown() throws Exception {
- LOG.info("Calling the tearDown method ");
+ LOG.info("tearDown()");
}
protected void testComponent(String component) throws Exception {
@@ -162,15 +161,6 @@ public abstract class AbstractFeatureTest {
versionAsInProject().type("xml/features");
}
- public static UrlReference getKarafFeatureUrl() {
- String karafVersion = System.getProperty("karafVersion");
- LOG.info("*** The karaf version is " + karafVersion + " ***");
-
- String type = "xml/features";
- return mavenBundle().groupId("org.apache.karaf.assemblies.features").
- artifactId("standard").version(karafVersion).type(type);
- }
-
private static void switchPlatformEncodingToUTF8() {
try {
System.setProperty("file.encoding", "UTF-8");
@@ -188,7 +178,7 @@ public abstract class AbstractFeatureTest {
try {
p.load(ins);
} catch (Throwable t) {
- //
+ // ignore
}
String karafVersion = p.getProperty("org.apache.karaf/apache-karaf/version");
if (karafVersion == null) {
@@ -210,7 +200,7 @@ public abstract class AbstractFeatureTest {
public static Option[] configure(String mainFeature, String... extraFeatures) {
switchPlatformEncodingToUTF8();
String karafVersion = getKarafVersion();
- LOG.info("*** The karaf version is " + karafVersion + " ***");
+ LOG.info("*** Apache Karaf version is " + karafVersion + " ***");
List<String> list = new ArrayList<String>();
list.add("camel-core");
@@ -243,7 +233,7 @@ public abstract class AbstractFeatureTest {
vmOption("-Dfile.encoding=UTF-8"),
- // install the unit test
+ // install junit
getJUnitBundle(),
// install the features
[5/5] camel git commit: Make itest karaf run as latest karaf has some
rbac changes that causes pax-exam to not work and crash the JVM.
Posted by da...@apache.org.
Make itest karaf run as latest karaf has some rbac changes that causes pax-exam to not work and crash the JVM.
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/3b675536
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/3b675536
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/3b675536
Branch: refs/heads/master
Commit: 3b6755360d8f3a7c36db4889144dd8b3519cc144
Parents: d585525
Author: Claus Ibsen <da...@apache.org>
Authored: Sat Mar 12 09:28:53 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Sat Mar 12 10:31:26 2016 +0100
----------------------------------------------------------------------
parent/pom.xml | 2 +-
.../features/src/main/resources/features.xml | 1 -
tests/camel-itest-karaf/pom.xml | 415 ++++++++++---------
.../camel/itest/karaf/AbstractFeatureTest.java | 37 +-
4 files changed, 228 insertions(+), 227 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/3b675536/parent/pom.xml
----------------------------------------------------------------------
diff --git a/parent/pom.xml b/parent/pom.xml
index 7b64bde..6046dcc 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -346,7 +346,7 @@
<jzlib-version>1.1.3</jzlib-version>
<jzlib-bundle-version>1.1.3_2</jzlib-bundle-version>
<kafka-version>0.9.0.1</kafka-version>
- <karaf-version>2.4.3</karaf-version>
+ <karaf-version>2.4.4</karaf-version>
<karaf3-version>3.0.6</karaf3-version>
<karaf4-version>4.0.4</karaf4-version>
<kie-version>6.3.0.Final</kie-version>
http://git-wip-us.apache.org/repos/asf/camel/blob/3b675536/platforms/karaf/features/src/main/resources/features.xml
----------------------------------------------------------------------
diff --git a/platforms/karaf/features/src/main/resources/features.xml b/platforms/karaf/features/src/main/resources/features.xml
index 8a683e7..59faaa5 100644
--- a/platforms/karaf/features/src/main/resources/features.xml
+++ b/platforms/karaf/features/src/main/resources/features.xml
@@ -1646,7 +1646,6 @@
</feature>
<feature name='camel-test' version='${project.version}' resolver='(obr)' start-level='50'>
<feature version='${project.version}'>camel-core</feature>
- <feature version='${project.version}'>camel-spring</feature>
<bundle dependency='true'>mvn:org.apache.servicemix.bundles/org.apache.servicemix.bundles.junit/${junit-bundle-version}</bundle>
<bundle>mvn:org.apache.camel/camel-test/${project.version}</bundle>
</feature>
http://git-wip-us.apache.org/repos/asf/camel/blob/3b675536/tests/camel-itest-karaf/pom.xml
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/pom.xml b/tests/camel-itest-karaf/pom.xml
index 5248385..31b0051 100644
--- a/tests/camel-itest-karaf/pom.xml
+++ b/tests/camel-itest-karaf/pom.xml
@@ -15,221 +15,222 @@
See the License for the specific language governing permissions and
limitations under the License.
-->
-<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/maven-v4_0_0.xsd">
+<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/maven-v4_0_0.xsd">
- <modelVersion>4.0.0</modelVersion>
+ <modelVersion>4.0.0</modelVersion>
- <parent>
- <groupId>org.apache.camel</groupId>
- <artifactId>tests</artifactId>
- <version>2.17-SNAPSHOT</version>
- </parent>
+ <parent>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>tests</artifactId>
+ <version>2.17-SNAPSHOT</version>
+ </parent>
- <artifactId>camel-itest-karaf</artifactId>
- <name>Camel :: Integration Tests :: Karaf</name>
- <description>Performs Karaf compliance integration tests</description>
+ <artifactId>camel-itest-karaf</artifactId>
+ <name>Camel :: Integration Tests :: Karaf</name>
+ <description>Performs Karaf compliance integration tests</description>
- <dependencies>
- <dependency>
- <groupId>org.ops4j.pax.exam</groupId>
- <artifactId>pax-exam-junit4</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.ops4j.pax.exam</groupId>
- <artifactId>pax-exam</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.ops4j.pax.exam</groupId>
- <artifactId>pax-exam-container-karaf</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.ops4j.pax.exam</groupId>
- <artifactId>pax-exam-link-mvn</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.karaf</groupId>
- <artifactId>apache-karaf</artifactId>
- <version>${karaf-version}</version>
- <type>tar.gz</type>
- <scope>test</scope>
- <exclusions>
- <exclusion>
- <groupId>org.apache.karaf.shell</groupId>
- <artifactId>org.apache.karaf.shell.dev</artifactId>
- </exclusion>
- <exclusion>
- <groupId>org.eclipse</groupId>
- <artifactId>osgi</artifactId>
- </exclusion>
- <exclusion>
- <groupId>org.apache.karaf</groupId>
- <artifactId>org.apache.karaf.client</artifactId>
- </exclusion>
- <exclusion>
- <groupId>org.apache.felix</groupId>
- <artifactId>org.apache.felix.framework</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
- <dependency>
- <groupId>org.apache.felix</groupId>
- <artifactId>org.apache.felix.configadmin</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.servicemix.bundles</groupId>
- <artifactId>org.apache.servicemix.bundles.javax-inject</artifactId>
- <version>${javax-inject-bundle-version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.servicemix.bundles</groupId>
- <artifactId>org.apache.servicemix.bundles.junit</artifactId>
- <version>${junit-bundle-version}</version>
- </dependency>
- <dependency>
- <groupId>org.osgi</groupId>
- <artifactId>org.osgi.core</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-core</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.camel</groupId>
- <artifactId>camel-spring</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.camel.karaf</groupId>
- <artifactId>apache-camel</artifactId>
- <version>${project.version}</version>
- <type>pom</type>
- <scope>test</scope>
- </dependency>
+ <dependencies>
+ <dependency>
+ <groupId>org.ops4j.pax.exam</groupId>
+ <artifactId>pax-exam-junit4</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.ops4j.pax.exam</groupId>
+ <artifactId>pax-exam</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.ops4j.pax.exam</groupId>
+ <artifactId>pax-exam-container-karaf</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.ops4j.pax.exam</groupId>
+ <artifactId>pax-exam-link-mvn</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.karaf</groupId>
+ <artifactId>apache-karaf</artifactId>
+ <version>${karaf-version}</version>
+ <type>tar.gz</type>
+ <scope>test</scope>
+ <exclusions>
+ <exclusion>
+ <groupId>org.apache.karaf.shell</groupId>
+ <artifactId>org.apache.karaf.shell.dev</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.eclipse</groupId>
+ <artifactId>osgi</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.karaf</groupId>
+ <artifactId>org.apache.karaf.client</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>org.apache.felix.framework</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.felix</groupId>
+ <artifactId>org.apache.felix.configadmin</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix.bundles</groupId>
+ <artifactId>org.apache.servicemix.bundles.javax-inject</artifactId>
+ <version>${javax-inject-bundle-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.servicemix.bundles</groupId>
+ <artifactId>org.apache.servicemix.bundles.junit</artifactId>
+ <version>${junit-bundle-version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.core</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-core</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel</groupId>
+ <artifactId>camel-spring</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.camel.karaf</groupId>
+ <artifactId>apache-camel</artifactId>
+ <version>${project.version}</version>
+ <type>pom</type>
+ <scope>test</scope>
+ </dependency>
- <!-- test and logging -->
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.slf4j</groupId>
- <artifactId>slf4j-log4j12</artifactId>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>log4j</groupId>
- <artifactId>log4j</artifactId>
- <scope>test</scope>
- </dependency>
- </dependencies>
+ <!-- test and logging -->
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>log4j</groupId>
+ <artifactId>log4j</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
- <build>
- <pluginManagement>
- <plugins>
- <!-- Eclipse m2e Lifecycle Management -->
- <plugin>
- <groupId>org.eclipse.m2e</groupId>
- <artifactId>lifecycle-mapping</artifactId>
- <version>${lifecycle-mapping-version}</version>
- <configuration>
- <lifecycleMappingMetadata>
- <pluginExecutions>
- <pluginExecution>
- <pluginExecutionFilter>
- <groupId>org.apache.servicemix.tooling</groupId>
- <artifactId>depends-maven-plugin</artifactId>
- <versionRange>${depends-maven-plugin-version}</versionRange>
- <goals>
- <goal>generate-depends-file</goal>
- </goals>
- </pluginExecutionFilter>
- <action>
- <ignore />
- </action>
- </pluginExecution>
- </pluginExecutions>
- </lifecycleMappingMetadata>
- </configuration>
- </plugin>
- </plugins>
- </pluginManagement>
- <plugins>
- <!-- generate dependencies versions -->
- <plugin>
- <groupId>org.apache.servicemix.tooling</groupId>
- <artifactId>depends-maven-plugin</artifactId>
- <executions>
- <execution>
- <id>generate-depends-file</id>
- <goals>
- <goal>generate-depends-file</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
+ <build>
+ <pluginManagement>
+ <plugins>
+ <!-- Eclipse m2e Lifecycle Management -->
+ <plugin>
+ <groupId>org.eclipse.m2e</groupId>
+ <artifactId>lifecycle-mapping</artifactId>
+ <version>${lifecycle-mapping-version}</version>
+ <configuration>
+ <lifecycleMappingMetadata>
+ <pluginExecutions>
+ <pluginExecution>
+ <pluginExecutionFilter>
+ <groupId>org.apache.servicemix.tooling</groupId>
+ <artifactId>depends-maven-plugin</artifactId>
+ <versionRange>${depends-maven-plugin-version}</versionRange>
+ <goals>
+ <goal>generate-depends-file</goal>
+ </goals>
+ </pluginExecutionFilter>
+ <action>
+ <ignore/>
+ </action>
+ </pluginExecution>
+ </pluginExecutions>
+ </lifecycleMappingMetadata>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ <plugins>
+ <!-- generate dependencies versions -->
+ <plugin>
+ <groupId>org.apache.servicemix.tooling</groupId>
+ <artifactId>depends-maven-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>generate-depends-file</id>
+ <goals>
+ <goal>generate-depends-file</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
- <plugin>
- <artifactId>maven-surefire-plugin</artifactId>
- <configuration>
- <forkCount>1</forkCount>
- <reuseForks>false</reuseForks>
- <systemPropertyVariables>
- <karafVersion>${karaf-version}</karafVersion>
- </systemPropertyVariables>
- </configuration>
- </plugin>
+ <plugin>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <!-- do not re-run these tests -->
+ <rerunFailingTestsCount>0</rerunFailingTestsCount>
+ <systemPropertyVariables>
+ <karafVersion>${karaf-version}</karafVersion>
+ </systemPropertyVariables>
+ </configuration>
+ </plugin>
- </plugins>
- </build>
+ </plugins>
+ </build>
- <profiles>
- <profile>
- <id>ci-build-profile</id>
- <activation>
- <property>
- <name>maven.repo.local</name>
- </property>
- </activation>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-plugin</artifactId>
- <configuration>
- <forkedProcessTimeoutInSeconds>300</forkedProcessTimeoutInSeconds>
- <!--
- when the local repo location has been specified, we need to pass
- on this information to PAX mvn url
- -->
- <argLine>-Dorg.ops4j.pax.url.mvn.localRepository=${maven.repo.local}</argLine>
- <systemPropertyVariables>
- <karafVersion>${karaf-version}</karafVersion>
- </systemPropertyVariables>
- </configuration>
- </plugin>
- </plugins>
- </build>
- </profile>
- <profile>
- <id>karaf3</id>
- <properties>
- <karaf-version>${karaf3-version}</karaf-version>
- </properties>
- </profile>
- <profile>
- <id>karaf4</id>
- <properties>
- <karaf-version>${karaf4-version}</karaf-version>
- </properties>
- </profile>
- </profiles>
+ <profiles>
+ <profile>
+ <id>ci-build-profile</id>
+ <activation>
+ <property>
+ <name>maven.repo.local</name>
+ </property>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <forkedProcessTimeoutInSeconds>300</forkedProcessTimeoutInSeconds>
+ <!--
+ when the local repo location has been specified, we need to pass
+ on this information to PAX mvn url
+ -->
+ <argLine>-Dorg.ops4j.pax.url.mvn.localRepository=${maven.repo.local}</argLine>
+ <systemPropertyVariables>
+ <karafVersion>${karaf-version}</karafVersion>
+ </systemPropertyVariables>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ <profile>
+ <id>karaf3</id>
+ <properties>
+ <karaf-version>${karaf3-version}</karaf-version>
+ </properties>
+ </profile>
+ <profile>
+ <id>karaf4</id>
+ <properties>
+ <karaf-version>${karaf4-version}</karaf-version>
+ </properties>
+ </profile>
+ </profiles>
</project>
http://git-wip-us.apache.org/repos/asf/camel/blob/3b675536/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
index 2c1acb5..3d60a13 100644
--- a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
+++ b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
@@ -26,9 +26,9 @@ import java.util.Properties;
import javax.inject.Inject;
import org.apache.camel.CamelContext;
-import org.apache.camel.core.osgi.OsgiDefaultCamelContext;
import org.apache.camel.impl.DefaultRouteContext;
import org.apache.camel.model.DataFormatDefinition;
+import org.apache.camel.osgi.CamelContextFactory;
import org.junit.After;
import org.junit.Before;
import org.ops4j.pax.exam.Option;
@@ -36,6 +36,7 @@ import org.ops4j.pax.exam.karaf.options.KarafDistributionOption;
import org.ops4j.pax.exam.karaf.options.LogLevelOption;
import org.ops4j.pax.exam.options.MavenArtifactProvisionOption;
import org.ops4j.pax.exam.options.UrlReference;
+import org.ops4j.pax.exam.rbc.Constants;
import org.osgi.framework.BundleContext;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -126,8 +127,10 @@ public abstract class AbstractFeatureTest {
protected CamelContext createCamelContext() throws Exception {
LOG.info("Creating the CamelContext ...");
setThreadContextClassLoader();
- OsgiDefaultCamelContext camel = new OsgiDefaultCamelContext(bundleContext);
- return camel;
+ CamelContextFactory factory = new CamelContextFactory();
+ factory.setBundleContext(bundleContext);
+ LOG.info("Get the bundleContext is " + bundleContext);
+ return factory.createContext();
}
protected void setThreadContextClassLoader() {
@@ -191,7 +194,7 @@ public abstract class AbstractFeatureTest {
}
if (karafVersion == null) {
// setup the default version of it
- karafVersion = "2.4.0";
+ karafVersion = "2.4.4";
}
return karafVersion;
}
@@ -208,7 +211,6 @@ public abstract class AbstractFeatureTest {
LOG.info("*** The karaf version is " + karafVersion + " ***");
List<String> list = new ArrayList<String>();
- list.add("cxf-jaxb");
list.add("camel-core");
list.add("camel-spring");
list.add("camel-" + mainFeature);
@@ -221,29 +223,28 @@ public abstract class AbstractFeatureTest {
// for remote debugging
//org.ops4j.pax.exam.CoreOptions.vmOption("-Xdebug"),
//org.ops4j.pax.exam.CoreOptions.vmOption("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5008"),
-
+
+ // we need INFO logging otherwise we cannot see what happens
+ new LogLevelOption(LogLevelOption.LogLevel.INFO),
+
+ // to allow rbac to connect to localhost
+ org.ops4j.pax.exam.CoreOptions.systemProperty(Constants.RMI_HOST_PROPERTY).value("localhost"),
+
KarafDistributionOption.karafDistributionConfiguration()
.frameworkUrl(maven().groupId("org.apache.karaf").artifactId("apache-karaf").type("tar.gz").versionAsInProject())
.karafVersion(karafVersion)
.name("Apache Karaf")
.useDeployFolder(false).unpackDirectory(new File("target/paxexam/unpack/")),
+ // keep the folder so we can look inside when something fails
+ KarafDistributionOption.keepRuntimeFolder(),
+
vmOption("-Dfile.encoding=UTF-8"),
- //KarafDistributionOption.keepRuntimeFolder(),
- // override the config.properties (to fix pax-exam bug)
- //KarafDistributionOption.replaceConfigurationFile("etc/config.properties", new File("src/test/resources/org/apache/camel/itest/karaf/config.properties")),
- // Update the jre.properties to export the sun.misc package
- KarafDistributionOption.replaceConfigurationFile("etc/jre.properties", new File("src/test/resources/org/apache/camel/itest/karaf/jre.properties")),
- KarafDistributionOption.replaceConfigurationFile("etc/custom.properties", new File("src/test/resources/org/apache/camel/itest/karaf/custom.properties")),
- KarafDistributionOption.replaceConfigurationFile("etc/org.ops4j.pax.url.mvn.cfg", new File("src/test/resources/org/apache/camel/itest/karaf/org.ops4j.pax.url.mvn.cfg")),
-
+ // install the unit test
getJUnitBundle(),
- // we need INFO logging otherwise we cannot see what happens
- new LogLevelOption(LogLevelOption.LogLevel.INFO),
-
- // install the cxf jaxb spec as the karaf doesn't provide it by default
+ // install the features
KarafDistributionOption.features(getCamelKarafFeatureUrl(), features)
};
[4/5] camel git commit: Change camel-itest-karaf to use
camel-blueprint instead of camel-spring and make it work with karaf4 also.
Posted by da...@apache.org.
Change camel-itest-karaf to use camel-blueprint instead of camel-spring and make it work with karaf4 also.
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/8c2fa732
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/8c2fa732
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/8c2fa732
Branch: refs/heads/master
Commit: 8c2fa7321aa6e19c433c2b104daaff332ecc175e
Parents: a6d19be
Author: Claus Ibsen <da...@apache.org>
Authored: Sat Mar 12 10:26:17 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Sat Mar 12 10:31:26 2016 +0100
----------------------------------------------------------------------
tests/camel-itest-karaf/pom.xml | 7 ++++++-
.../camel/itest/karaf/AbstractFeatureTest.java | 16 +++++++++-------
2 files changed, 15 insertions(+), 8 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/8c2fa732/tests/camel-itest-karaf/pom.xml
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/pom.xml b/tests/camel-itest-karaf/pom.xml
index 31b0051..0fbb7a1 100644
--- a/tests/camel-itest-karaf/pom.xml
+++ b/tests/camel-itest-karaf/pom.xml
@@ -97,13 +97,18 @@
<scope>test</scope>
</dependency>
<dependency>
+ <groupId>org.osgi</groupId>
+ <artifactId>org.osgi.compendium</artifactId>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
- <artifactId>camel-spring</artifactId>
+ <artifactId>camel-blueprint</artifactId>
<scope>test</scope>
</dependency>
<dependency>
http://git-wip-us.apache.org/repos/asf/camel/blob/8c2fa732/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
index 3d60a13..60218ec 100644
--- a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
+++ b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
@@ -26,9 +26,9 @@ import java.util.Properties;
import javax.inject.Inject;
import org.apache.camel.CamelContext;
+import org.apache.camel.blueprint.BlueprintCamelContext;
import org.apache.camel.impl.DefaultRouteContext;
import org.apache.camel.model.DataFormatDefinition;
-import org.apache.camel.osgi.CamelContextFactory;
import org.junit.After;
import org.junit.Before;
import org.ops4j.pax.exam.Option;
@@ -38,6 +38,7 @@ import org.ops4j.pax.exam.options.MavenArtifactProvisionOption;
import org.ops4j.pax.exam.options.UrlReference;
import org.ops4j.pax.exam.rbc.Constants;
import org.osgi.framework.BundleContext;
+import org.osgi.service.blueprint.container.BlueprintContainer;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -54,6 +55,9 @@ public abstract class AbstractFeatureTest {
@Inject
protected BundleContext bundleContext;
+ @Inject
+ protected BlueprintContainer blueprintContainer;
+
@Before
public void setUp() throws Exception {
LOG.info("Calling the setUp method ");
@@ -125,12 +129,10 @@ public abstract class AbstractFeatureTest {
}
protected CamelContext createCamelContext() throws Exception {
- LOG.info("Creating the CamelContext ...");
+ LOG.info("Creating CamelContext using BundleContext: {} and BlueprintContainer: {}", bundleContext, blueprintContainer);
setThreadContextClassLoader();
- CamelContextFactory factory = new CamelContextFactory();
- factory.setBundleContext(bundleContext);
- LOG.info("Get the bundleContext is " + bundleContext);
- return factory.createContext();
+ BlueprintCamelContext context = new BlueprintCamelContext(bundleContext, blueprintContainer);
+ return context;
}
protected void setThreadContextClassLoader() {
@@ -212,7 +214,7 @@ public abstract class AbstractFeatureTest {
List<String> list = new ArrayList<String>();
list.add("camel-core");
- list.add("camel-spring");
+ list.add("camel-blueprint");
list.add("camel-" + mainFeature);
for (String extra : extraFeatures) {
list.add("camel-" + extra);
[2/5] camel git commit: Remove not needed stuff
Posted by da...@apache.org.
Remove not needed stuff
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/a6d19be7
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/a6d19be7
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/a6d19be7
Branch: refs/heads/master
Commit: a6d19be74706991b12b82beb1982933b0b8775db
Parents: 3b67553
Author: Claus Ibsen <da...@apache.org>
Authored: Sat Mar 12 10:20:01 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Sat Mar 12 10:31:26 2016 +0100
----------------------------------------------------------------------
.../apache/camel/itest/karaf/config.properties | 124 -----
.../apache/camel/itest/karaf/custom.properties | 30 --
.../org/apache/camel/itest/karaf/jre.properties | 512 -------------------
.../camel/itest/karaf/org.ops4j.pax.url.mvn.cfg | 103 ----
4 files changed, 769 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/a6d19be7/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/config.properties
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/config.properties b/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/config.properties
deleted file mode 100644
index 544c508..0000000
--- a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/config.properties
+++ /dev/null
@@ -1,124 +0,0 @@
-################################################################################
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-################################################################################
-
-# FIXING PAX-EXAM BUG
-
-#
-# This file lists Karaf default settings for this particular version of Karaf.
-# For easier maintenance when upgrading Karaf and to better document which
-# default values have changed, it is recommended to place any changes to
-# these values in a custom.properties file in the same folder as this file.
-# Each value specified in custom.properties will override the default value
-# here.
-#
-
-#
-# Properties file inclusions (as a space separated list of relative paths)
-# Included files will override the values specified in this file
-# NB: ${includes} properties files are mandatory, it means that Karaf will not start
-# if the include file is not found
-#
-${includes} = jre.properties custom.properties
-
-#
-# Properties file inclusions (as a space separated list of relative paths)
-# Included files will override the values specified in this file
-# NB: ${optionals} properties files are optionals, it means that Karaf will just
-# display a warning message but the bootstrap will be performed
-#
-# ${optionals} = my.properties
-
-
-#
-# Framework selection properties
-#
-karaf.framework=felix
-
-#
-# Location of the OSGi frameworks
-#
-karaf.framework.equinox=${karaf.default.repository}/org/eclipse/osgi/3.8.0.v20120529-1548/osgi-3.8.0.v20120529-1548.jar
-karaf.framework.felix=${karaf.default.repository}/org/apache/felix/org.apache.felix.framework/4.0.3/org.apache.felix.framework-4.0.3.jar
-
-#
-# Framework config properties.
-#
-org.osgi.framework.system.packages= \
- org.osgi.framework.startlevel;uses:="org.osgi.framework";version="1.0", \
- org.osgi.framework.wiring;uses:="org.osgi.resource,org.osgi.framework";version="1.1", \
- org.osgi.framework.hooks.bundle;uses:="org.osgi.framework";version="1.1", \
- org.osgi.framework.hooks.service;uses:="org.osgi.framework";version="1.1", \
- org.osgi.framework.hooks.resolver;uses:="org.osgi.framework.wiring";version="1.0", \
- org.osgi.framework.launch;uses:="org.osgi.framework";version="1.1", \
- org.osgi.framework.namespace;uses:="org.osgi.resource";version="1.0", \
- org.osgi.framework;version="1.7",\
- org.osgi.framework.hooks.weaving;uses:="org.osgi.framework.wiring";version="1.0",\
- org.osgi.resource;version="1.0",org.osgi.service.url;version="1.0",\
- org.osgi.service.startlevel;uses:="org.osgi.framework";version="1.1",\
- org.osgi.service.packageadmin;uses:="org.osgi.framework";version="1.2",\
- org.osgi.service.url;version="1.0", \
- org.osgi.util.tracker;uses:="org.osgi.framework";version="1.5.1", \
- org.apache.karaf.jaas.boot;version="2.3.0", \
- org.apache.karaf.jaas.boot.principal;version="2.3.0", \
- org.apache.karaf.version;version="2.3.0", \
- ${jre-${java.specification.version}}
-
-# Extra packages appended after standard packages
-# org.osgi.framework.system.packages.extra=
-
-# javax.transaction is needed to avoid class loader constraint violation when using javax.sql
-org.osgi.framework.bootdelegation=org.apache.karaf.jaas.boot,sun.*,com.sun.*,javax.transaction,javax.transaction.*
-
-# OSGi Execution Environment
-org.osgi.framework.executionenvironment=J2SE-1.7,JavaSE-1.7,J2SE-1.6,JavaSE-1.6,J2SE-1.5,JavaSE-1.5,J2SE-1.4,JavaSE-1.4,J2SE-1.3,JavaSE-1.3,J2SE-1.2,,JavaSE-1.2,CDC-1.1/Foundation-1.1,CDC-1.0/Foundation-1.0,J2ME,OSGi/Minimum-1.1,OSGi/Minimum-1.0
-
-# Set the parent classloader for the bundle to the classloader that loads the Framework (i.e. everything in lib/*.jar)
-org.osgi.framework.bundle.parent=framework
-
-# To enable the use of the startup.properties file to control the start level:
-karaf.auto.start=startup.properties
-
-org.osgi.framework.startlevel.beginning=100
-karaf.startlevel.bundle=80
-
-karaf.shutdown.port.file=${karaf.data}/port
-
-#
-# FileMonitor properties
-#
-felix.fileinstall.dir = ${karaf.base}/etc
-felix.fileinstall.filter = .*\\.cfg
-felix.fileinstall.poll = 1000
-felix.fileinstall.noInitialDelay = true
-felix.fileinstall.log.level = 3
-
-#
-# Delay for writing the framework state to disk in equinox
-# must be >= 1000 and <= 1800000
-#
-eclipse.stateSaveDelayInterval = 1000
-
-#
-# OBR Repository list
-# This property will be modified by the obr:addUrl and obr:removeUrl commands.
-#
-obr.repository.url =
-
-karaf.delay.console=false
-
http://git-wip-us.apache.org/repos/asf/camel/blob/a6d19be7/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/custom.properties
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/custom.properties b/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/custom.properties
deleted file mode 100644
index fbdb62a..0000000
--- a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/custom.properties
+++ /dev/null
@@ -1,30 +0,0 @@
-################################################################################
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-################################################################################
-
-#
-# All the values specified here will override the default values given
-# in config.properties.
-#
-
-karaf.systemBundlesStartLevel=50
-
-#
-# You can place any customized configuration here.
-#
-
http://git-wip-us.apache.org/repos/asf/camel/blob/a6d19be7/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/jre.properties
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/jre.properties b/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/jre.properties
deleted file mode 100644
index 24429ef..0000000
--- a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/jre.properties
+++ /dev/null
@@ -1,512 +0,0 @@
-################################################################################
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-################################################################################
-
-#
-# Java platform package export properties.
-#
-
-# Standard package set. Note that:
-# - javax.transaction* is exported with a mandatory attribute
-jre-1.6= \
- sun.misc, \
- javax.accessibility, \
- javax.activation;version="1.1", \
- javax.activity, \
- javax.annotation;version="1.1", \
- javax.annotation.processing;version="1.1", \
- javax.crypto, \
- javax.crypto.interfaces, \
- javax.crypto.spec, \
- javax.imageio, \
- javax.imageio.event, \
- javax.imageio.metadata, \
- javax.imageio.plugins.bmp, \
- javax.imageio.plugins.jpeg, \
- javax.imageio.spi, \
- javax.imageio.stream, \
- javax.jws, \
- javax.jws.soap, \
- javax.lang.model, \
- javax.lang.model.element, \
- javax.lang.model.type, \
- javax.lang.model.util, \
- javax.management, \
- javax.management.loading, \
- javax.management.modelmbean, \
- javax.management.monitor, \
- javax.management.openmbean, \
- javax.management.relation, \
- javax.management.remote, \
- javax.management.remote.rmi, \
- javax.management.timer, \
- javax.naming, \
- javax.naming.directory, \
- javax.naming.event, \
- javax.naming.ldap, \
- javax.naming.spi, \
- javax.net, \
- javax.net.ssl, \
- javax.print, \
- javax.print.attribute, \
- javax.print.attribute.standard, \
- javax.print.event, \
- javax.rmi, \
- javax.rmi.CORBA, \
- javax.rmi.ssl, \
- javax.script, \
- javax.security.auth, \
- javax.security.auth.callback, \
- javax.security.auth.kerberos, \
- javax.security.auth.login, \
- javax.security.auth.spi, \
- javax.security.auth.x500, \
- javax.security.cert, \
- javax.security.sasl, \
- javax.sound.midi, \
- javax.sound.midi.spi, \
- javax.sound.sampled, \
- javax.sound.sampled.spi, \
- javax.sql, \
- javax.sql.rowset, \
- javax.sql.rowset.serial, \
- javax.sql.rowset.spi, \
- javax.swing, \
- javax.swing.border, \
- javax.swing.colorchooser, \
- javax.swing.event, \
- javax.swing.filechooser, \
- javax.swing.plaf, \
- javax.swing.plaf.basic, \
- javax.swing.plaf.metal, \
- javax.swing.plaf.multi, \
- javax.swing.plaf.synth, \
- javax.swing.table, \
- javax.swing.text, \
- javax.swing.text.html, \
- javax.swing.text.html.parser, \
- javax.swing.text.rtf, \
- javax.swing.tree, \
- javax.swing.undo, \
- javax.tools, \
- javax.transaction; javax.transaction.xa; partial=true; mandatory:=partial, \
- javax.xml, \
- javax.xml.bind;version="2.2.1", \
- javax.xml.bind.annotation;version="2.2.1", \
- javax.xml.bind.annotation.adapters;version="2.2.1", \
- javax.xml.bind.attachment;version="2.2.1", \
- javax.xml.bind.helpers;version="2.2.1", \
- javax.xml.bind.util;version="2.2.1", \
- javax.xml.crypto, \
- javax.xml.crypto.dom, \
- javax.xml.crypto.dsig, \
- javax.xml.crypto.dsig.dom, \
- javax.xml.crypto.dsig.keyinfo, \
- javax.xml.crypto.dsig.spec, \
- javax.xml.datatype, \
- javax.xml.namespace, \
- javax.xml.parsers, \
- javax.xml.soap;version="1.3", \
- javax.xml.stream;version="1.2", \
- javax.xml.stream.events;version="1.2", \
- javax.xml.stream.util;version="1.2", \
- javax.xml.transform, \
- javax.xml.transform.dom, \
- javax.xml.transform.sax, \
- javax.xml.transform.stax, \
- javax.xml.transform.stream, \
- javax.xml.validation, \
- javax.xml.ws;version="2.2", \
- javax.xml.ws.handler;version="2.2", \
- javax.xml.ws.handler.soap;version="2.2", \
- javax.xml.ws.http;version="2.2", \
- javax.xml.ws.soap;version="2.2", \
- javax.xml.ws.spi;version="2.2", \
- javax.xml.ws.wsaddressing;version="2.2", \
- javax.xml.ws.spi.http;version="2.2", \
- javax.xml.xpath, \
- org.ietf.jgss, \
- org.omg.CORBA, \
- org.omg.CORBA_2_3, \
- org.omg.CORBA_2_3.portable, \
- org.omg.CORBA.DynAnyPackage, \
- org.omg.CORBA.ORBPackage, \
- org.omg.CORBA.portable, \
- org.omg.CORBA.TypeCodePackage, \
- org.omg.CosNaming, \
- org.omg.CosNaming.NamingContextExtPackage, \
- org.omg.CosNaming.NamingContextPackage, \
- org.omg.Dynamic, \
- org.omg.DynamicAny, \
- org.omg.DynamicAny.DynAnyFactoryPackage, \
- org.omg.DynamicAny.DynAnyPackage, \
- org.omg.IOP, \
- org.omg.IOP.CodecFactoryPackage, \
- org.omg.IOP.CodecPackage, \
- org.omg.Messaging, \
- org.omg.PortableInterceptor, \
- org.omg.PortableInterceptor.ORBInitInfoPackage, \
- org.omg.PortableServer, \
- org.omg.PortableServer.CurrentPackage, \
- org.omg.PortableServer.POAManagerPackage, \
- org.omg.PortableServer.POAPackage, \
- org.omg.PortableServer.portable, \
- org.omg.PortableServer.ServantLocatorPackage, \
- org.omg.SendingContext, \
- org.omg.stub.java.rmi, \
- org.omg.stub.javax.management.remote.rmi, \
- org.w3c.dom, \
- org.w3c.dom.bootstrap, \
- org.w3c.dom.css, \
- org.w3c.dom.events, \
- org.w3c.dom.html, \
- org.w3c.dom.ls, \
- org.w3c.dom.ranges, \
- org.w3c.dom.stylesheets, \
- org.w3c.dom.traversal, \
- org.w3c.dom.views, \
- org.w3c.dom.xpath, \
- org.xml.sax, \
- org.xml.sax.ext, \
- org.xml.sax.helpers
-
-# Standard package set. Note that:
-# - javax.transaction* is exported with a mandatory attribute
-jre-1.7= \
- sun.misc, \
- javax.accessibility, \
- javax.activation;version="1.1", \
- javax.activity, \
- javax.annotation;version="1.2", \
- javax.annotation.processing;version="1.2", \
- javax.crypto, \
- javax.crypto.interfaces, \
- javax.crypto.spec, \
- javax.imageio, \
- javax.imageio.event, \
- javax.imageio.metadata, \
- javax.imageio.plugins.bmp, \
- javax.imageio.plugins.jpeg, \
- javax.imageio.spi, \
- javax.imageio.stream, \
- javax.jws, \
- javax.jws.soap, \
- javax.lang.model, \
- javax.lang.model.element, \
- javax.lang.model.type, \
- javax.lang.model.util, \
- javax.management, \
- javax.management.loading, \
- javax.management.modelmbean, \
- javax.management.monitor, \
- javax.management.openmbean, \
- javax.management.relation, \
- javax.management.remote, \
- javax.management.remote.rmi, \
- javax.management.timer, \
- javax.naming, \
- javax.naming.directory, \
- javax.naming.event, \
- javax.naming.ldap, \
- javax.naming.spi, \
- javax.net, \
- javax.net.ssl, \
- javax.print, \
- javax.print.attribute, \
- javax.print.attribute.standard, \
- javax.print.event, \
- javax.rmi, \
- javax.rmi.CORBA, \
- javax.rmi.ssl, \
- javax.script, \
- javax.security.auth, \
- javax.security.auth.callback, \
- javax.security.auth.kerberos, \
- javax.security.auth.login, \
- javax.security.auth.spi, \
- javax.security.auth.x500, \
- javax.security.cert, \
- javax.security.sasl, \
- javax.sound.midi, \
- javax.sound.midi.spi, \
- javax.sound.sampled, \
- javax.sound.sampled.spi, \
- javax.sql, \
- javax.sql.rowset, \
- javax.sql.rowset.serial, \
- javax.sql.rowset.spi, \
- javax.swing, \
- javax.swing.border, \
- javax.swing.colorchooser, \
- javax.swing.event, \
- javax.swing.filechooser, \
- javax.swing.plaf, \
- javax.swing.plaf.basic, \
- javax.swing.plaf.metal, \
- javax.swing.plaf.multi, \
- javax.swing.plaf.synth, \
- javax.swing.table, \
- javax.swing.text, \
- javax.swing.text.html, \
- javax.swing.text.html.parser, \
- javax.swing.text.rtf, \
- javax.swing.tree, \
- javax.swing.undo, \
- javax.tools, \
- javax.transaction; javax.transaction.xa; partial=true; mandatory:=partial, \
- javax.xml, \
- javax.xml.bind;version="2.2.1", \
- javax.xml.bind.annotation;version="2.2.1", \
- javax.xml.bind.annotation.adapters;version="2.2.1", \
- javax.xml.bind.attachment;version="2.2.1", \
- javax.xml.bind.helpers;version="2.2.1", \
- javax.xml.bind.util;version="2.2.1", \
- javax.xml.crypto, \
- javax.xml.crypto.dom, \
- javax.xml.crypto.dsig, \
- javax.xml.crypto.dsig.dom, \
- javax.xml.crypto.dsig.keyinfo, \
- javax.xml.crypto.dsig.spec, \
- javax.xml.datatype, \
- javax.xml.namespace, \
- javax.xml.parsers, \
- javax.xml.soap;version="1.3", \
- javax.xml.stream;version="1.2", \
- javax.xml.stream.events;version="1.2", \
- javax.xml.stream.util;version="1.2", \
- javax.xml.transform, \
- javax.xml.transform.dom, \
- javax.xml.transform.sax, \
- javax.xml.transform.stax, \
- javax.xml.transform.stream, \
- javax.xml.validation, \
- javax.xml.ws;version="2.2", \
- javax.xml.ws.handler;version="2.2", \
- javax.xml.ws.handler.soap;version="2.2", \
- javax.xml.ws.http;version="2.2", \
- javax.xml.ws.soap;version="2.2", \
- javax.xml.ws.spi;version="2.2", \
- javax.xml.ws.wsaddressing;version="2.2", \
- javax.xml.ws.spi.http;version="2.2", \
- javax.xml.xpath, \
- org.ietf.jgss, \
- org.omg.CORBA, \
- org.omg.CORBA_2_3, \
- org.omg.CORBA_2_3.portable, \
- org.omg.CORBA.DynAnyPackage, \
- org.omg.CORBA.ORBPackage, \
- org.omg.CORBA.portable, \
- org.omg.CORBA.TypeCodePackage, \
- org.omg.CosNaming, \
- org.omg.CosNaming.NamingContextExtPackage, \
- org.omg.CosNaming.NamingContextPackage, \
- org.omg.Dynamic, \
- org.omg.DynamicAny, \
- org.omg.DynamicAny.DynAnyFactoryPackage, \
- org.omg.DynamicAny.DynAnyPackage, \
- org.omg.IOP, \
- org.omg.IOP.CodecFactoryPackage, \
- org.omg.IOP.CodecPackage, \
- org.omg.Messaging, \
- org.omg.PortableInterceptor, \
- org.omg.PortableInterceptor.ORBInitInfoPackage, \
- org.omg.PortableServer, \
- org.omg.PortableServer.CurrentPackage, \
- org.omg.PortableServer.POAManagerPackage, \
- org.omg.PortableServer.POAPackage, \
- org.omg.PortableServer.portable, \
- org.omg.PortableServer.ServantLocatorPackage, \
- org.omg.SendingContext, \
- org.omg.stub.java.rmi, \
- org.omg.stub.javax.management.remote.rmi, \
- org.w3c.dom, \
- org.w3c.dom.bootstrap, \
- org.w3c.dom.css, \
- org.w3c.dom.events, \
- org.w3c.dom.html, \
- org.w3c.dom.ls, \
- org.w3c.dom.ranges, \
- org.w3c.dom.stylesheets, \
- org.w3c.dom.traversal, \
- org.w3c.dom.views, \
- org.w3c.dom.xpath, \
- org.xml.sax, \
- org.xml.sax.ext, \
- org.xml.sax.helpers
-
-jre-1.8= \
- sun.misc, \
- javax.accessibility, \
- javax.activation;version="1.1", \
- javax.activity, \
- javax.annotation;version="1.2", \
- javax.annotation.processing;version="1.2", \
- javax.crypto, \
- javax.crypto.interfaces, \
- javax.crypto.spec, \
- javax.imageio, \
- javax.imageio.event, \
- javax.imageio.metadata, \
- javax.imageio.plugins.bmp, \
- javax.imageio.plugins.jpeg, \
- javax.imageio.spi, \
- javax.imageio.stream, \
- javax.jws, \
- javax.jws.soap, \
- javax.lang.model, \
- javax.lang.model.element, \
- javax.lang.model.type, \
- javax.lang.model.util, \
- javax.management, \
- javax.management.loading, \
- javax.management.modelmbean, \
- javax.management.monitor, \
- javax.management.openmbean, \
- javax.management.relation, \
- javax.management.remote, \
- javax.management.remote.rmi, \
- javax.management.timer, \
- javax.naming, \
- javax.naming.directory, \
- javax.naming.event, \
- javax.naming.ldap, \
- javax.naming.spi, \
- javax.net, \
- javax.net.ssl, \
- javax.print, \
- javax.print.attribute, \
- javax.print.attribute.standard, \
- javax.print.event, \
- javax.rmi, \
- javax.rmi.CORBA, \
- javax.rmi.ssl, \
- javax.script, \
- javax.security.auth, \
- javax.security.auth.callback, \
- javax.security.auth.kerberos, \
- javax.security.auth.login, \
- javax.security.auth.spi, \
- javax.security.auth.x500, \
- javax.security.cert, \
- javax.security.sasl, \
- javax.sound.midi, \
- javax.sound.midi.spi, \
- javax.sound.sampled, \
- javax.sound.sampled.spi, \
- javax.sql, \
- javax.sql.rowset, \
- javax.sql.rowset.serial, \
- javax.sql.rowset.spi, \
- javax.swing, \
- javax.swing.border, \
- javax.swing.colorchooser, \
- javax.swing.event, \
- javax.swing.filechooser, \
- javax.swing.plaf, \
- javax.swing.plaf.basic, \
- javax.swing.plaf.metal, \
- javax.swing.plaf.multi, \
- javax.swing.plaf.synth, \
- javax.swing.table, \
- javax.swing.text, \
- javax.swing.text.html, \
- javax.swing.text.html.parser, \
- javax.swing.text.rtf, \
- javax.swing.tree, \
- javax.swing.undo, \
- javax.tools, \
- javax.transaction; javax.transaction.xa; partial=true; mandatory:=partial, \
- javax.xml, \
- javax.xml.bind;version="2.2.1", \
- javax.xml.bind.annotation;version="2.2.1", \
- javax.xml.bind.annotation.adapters;version="2.2.1", \
- javax.xml.bind.attachment;version="2.2.1", \
- javax.xml.bind.helpers;version="2.2.1", \
- javax.xml.bind.util;version="2.2.1", \
- javax.xml.crypto, \
- javax.xml.crypto.dom, \
- javax.xml.crypto.dsig, \
- javax.xml.crypto.dsig.dom, \
- javax.xml.crypto.dsig.keyinfo, \
- javax.xml.crypto.dsig.spec, \
- javax.xml.datatype, \
- javax.xml.namespace, \
- javax.xml.parsers, \
- javax.xml.soap;version="1.3", \
- javax.xml.stream;version="1.2", \
- javax.xml.stream.events;version="1.2", \
- javax.xml.stream.util;version="1.2", \
- javax.xml.transform, \
- javax.xml.transform.dom, \
- javax.xml.transform.sax, \
- javax.xml.transform.stax, \
- javax.xml.transform.stream, \
- javax.xml.validation, \
- javax.xml.ws;version="2.2", \
- javax.xml.ws.handler;version="2.2", \
- javax.xml.ws.handler.soap;version="2.2", \
- javax.xml.ws.http;version="2.2", \
- javax.xml.ws.soap;version="2.2", \
- javax.xml.ws.spi;version="2.2", \
- javax.xml.ws.wsaddressing;version="2.2", \
- javax.xml.ws.spi.http;version="2.2", \
- javax.xml.xpath, \
- org.ietf.jgss, \
- org.omg.CORBA, \
- org.omg.CORBA_2_3, \
- org.omg.CORBA_2_3.portable, \
- org.omg.CORBA.DynAnyPackage, \
- org.omg.CORBA.ORBPackage, \
- org.omg.CORBA.portable, \
- org.omg.CORBA.TypeCodePackage, \
- org.omg.CosNaming, \
- org.omg.CosNaming.NamingContextExtPackage, \
- org.omg.CosNaming.NamingContextPackage, \
- org.omg.Dynamic, \
- org.omg.DynamicAny, \
- org.omg.DynamicAny.DynAnyFactoryPackage, \
- org.omg.DynamicAny.DynAnyPackage, \
- org.omg.IOP, \
- org.omg.IOP.CodecFactoryPackage, \
- org.omg.IOP.CodecPackage, \
- org.omg.Messaging, \
- org.omg.PortableInterceptor, \
- org.omg.PortableInterceptor.ORBInitInfoPackage, \
- org.omg.PortableServer, \
- org.omg.PortableServer.CurrentPackage, \
- org.omg.PortableServer.POAManagerPackage, \
- org.omg.PortableServer.POAPackage, \
- org.omg.PortableServer.portable, \
- org.omg.PortableServer.ServantLocatorPackage, \
- org.omg.SendingContext, \
- org.omg.stub.java.rmi, \
- org.omg.stub.javax.management.remote.rmi, \
- org.w3c.dom, \
- org.w3c.dom.bootstrap, \
- org.w3c.dom.css, \
- org.w3c.dom.events, \
- org.w3c.dom.html, \
- org.w3c.dom.ls, \
- org.w3c.dom.ranges, \
- org.w3c.dom.stylesheets, \
- org.w3c.dom.traversal, \
- org.w3c.dom.views, \
- org.w3c.dom.xpath, \
- org.xml.sax, \
- org.xml.sax.ext, \
- org.xml.sax.helpers
http://git-wip-us.apache.org/repos/asf/camel/blob/a6d19be7/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/org.ops4j.pax.url.mvn.cfg
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/org.ops4j.pax.url.mvn.cfg b/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/org.ops4j.pax.url.mvn.cfg
deleted file mode 100644
index 18fed15..0000000
--- a/tests/camel-itest-karaf/src/test/resources/org/apache/camel/itest/karaf/org.ops4j.pax.url.mvn.cfg
+++ /dev/null
@@ -1,103 +0,0 @@
-################################################################################
-#
-# Licensed to the Apache Software Foundation (ASF) under one or more
-# contributor license agreements. See the NOTICE file distributed with
-# this work for additional information regarding copyright ownership.
-# The ASF licenses this file to You under the Apache License, Version 2.0
-# (the "License"); you may not use this file except in compliance with
-# the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-################################################################################
-
-#
-# If set to true, the following property will not allow any certificate to be used
-# when accessing Maven repositories through SSL
-#
-#org.ops4j.pax.url.mvn.certificateCheck=
-
-#
-# Path to the local Maven settings file.
-# The repositories defined in this file will be automatically added to the list
-# of default repositories if the 'org.ops4j.pax.url.mvn.repositories' property
-# below is not set.
-# The following locations are checked for the existence of the settings.xml file
-# * 1. looks for the specified url
-# * 2. if not found looks for ${user.home}/.m2/settings.xml
-# * 3. if not found looks for ${maven.home}/conf/settings.xml
-# * 4. if not found looks for ${M2_HOME}/conf/settings.xml
-#
-#org.ops4j.pax.url.mvn.settings=
-
-#
-# Path to the local Maven repository which is used to avoid downloading
-# artifacts when they already exist locally.
-# The value of this property will be extracted from the settings.xml file
-# above, or defaulted to:
-# System.getProperty( "user.home" ) + "/.m2/repository"
-#
-#org.ops4j.pax.url.mvn.localRepository=
-
-#
-# Default this to false. It's just weird to use undocumented repos
-#
-org.ops4j.pax.url.mvn.useFallbackRepositories=false
-
-#
-# Uncomment if you don't wanna use the proxy settings
-# from the Maven conf/settings.xml file
-#
-# org.ops4j.pax.url.mvn.proxySupport=false
-
-#
-# Disable aether support by default. This ensure that the defaultRepositories
-# below will be used
-#
-org.ops4j.pax.url.mvn.disableAether=true
-
-#
-# Comma separated list of repositories scanned when resolving an artifact.
-# Those repositories will be checked before iterating through the
-# below list of repositories and even before the local repository
-# A repository url can be appended with zero or more of the following flags:
-# @snapshots : the repository contains snaphots
-# @noreleases : the repository does not contain any released artifacts
-# @id=reponid : the id for the repository, just like in the settings.xml this is optional but recomendet
-#
-# The following property value will add the system folder as a repo.
-#
-org.ops4j.pax.url.mvn.defaultRepositories=file:${karaf.home}/${karaf.default.repository}@snapshots@id=karaf.${karaf.default.repository}
-
-#
-# Comma separated list of repositories scanned when resolving an artifact.
-# The default list includes the following repositories containing releases:
-# http://repo1.maven.org/maven2@id=central
-# http://svn.apache.org/repos/asf/servicemix/m2-repo@id=servicemix
-# http://repository.springsource.com/maven/bundles/release@id=springsource.release
-# http://repository.springsource.com/maven/bundles/external@id=springsource.external
-# To add repositories to the default ones, prepend '+' to the list of repositories
-# to add.
-# A repository url can be appended with zero or more of the following flags:
-# @snapshots : the repository contains snapshots
-# @noreleases : the repository does not contain any released artifacts
-#
-# The default list doesn't contain any repository containing snapshots as it can impact the artifacts resolution.
-# You may want to add the following repositories containing snapshots:
-# http://oss.sonatype.org/content/repositories/snapshots@snapshots@noreleases@id=sonatype.snapshot
-# http://oss.sonatype.org/content/repositories/ops4j-snapshots@snapshots@noreleases@id=ops4j.snapshot
-# http://repository.apache.org/content/groups/snapshots-group@snapshots@noreleases@id=apache
-#
-org.ops4j.pax.url.mvn.repositories= \
- http://repo1.maven.org/maven2@id=central, \
- http://svn.apache.org/repos/asf/servicemix/m2-repo@id=servicemix, \
- http://repository.springsource.com/maven/bundles/release@id=springsource.release, \
- http://repository.springsource.com/maven/bundles/external@id=springsource.external, \
- http://oss.sonatype.org/content/repositories/releases/@id=sonatype
-
[3/5] camel git commit: Make itest karaf run as latest karaf has some
rbac changes that causes pax-exam to not work and crash the JVM. Adjust the
code so it can compile with karaf 4.
Posted by da...@apache.org.
Make itest karaf run as latest karaf has some rbac changes that causes pax-exam to not work and crash the JVM. Adjust the code so it can compile with karaf 4.
Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/d5855254
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/d5855254
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/d5855254
Branch: refs/heads/master
Commit: d5855254c22e274501f5af7d633bae52757959b4
Parents: e095075
Author: Claus Ibsen <da...@apache.org>
Authored: Sat Mar 12 09:07:09 2016 +0100
Committer: Claus Ibsen <da...@apache.org>
Committed: Sat Mar 12 10:31:26 2016 +0100
----------------------------------------------------------------------
parent/pom.xml | 4 ++--
tests/camel-itest-karaf/pom.xml | 8 +++++++-
.../apache/camel/itest/karaf/AbstractFeatureTest.java | 13 +++----------
3 files changed, 12 insertions(+), 13 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/camel/blob/d5855254/parent/pom.xml
----------------------------------------------------------------------
diff --git a/parent/pom.xml b/parent/pom.xml
index 2197a8b..7b64bde 100644
--- a/parent/pom.xml
+++ b/parent/pom.xml
@@ -346,8 +346,8 @@
<jzlib-version>1.1.3</jzlib-version>
<jzlib-bundle-version>1.1.3_2</jzlib-bundle-version>
<kafka-version>0.9.0.1</kafka-version>
- <karaf-version>2.4.4</karaf-version>
- <karaf3-version>3.0.5</karaf3-version>
+ <karaf-version>2.4.3</karaf-version>
+ <karaf3-version>3.0.6</karaf3-version>
<karaf4-version>4.0.4</karaf4-version>
<kie-version>6.3.0.Final</kie-version>
<krati-version>0.4.9</krati-version>
http://git-wip-us.apache.org/repos/asf/camel/blob/d5855254/tests/camel-itest-karaf/pom.xml
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/pom.xml b/tests/camel-itest-karaf/pom.xml
index 5fbb379..5248385 100644
--- a/tests/camel-itest-karaf/pom.xml
+++ b/tests/camel-itest-karaf/pom.xml
@@ -180,7 +180,7 @@
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<forkCount>1</forkCount>
- <reuseForks>false</reuseForks>
+ <reuseForks>false</reuseForks>
<systemPropertyVariables>
<karafVersion>${karaf-version}</karafVersion>
</systemPropertyVariables>
@@ -224,6 +224,12 @@
<karaf-version>${karaf3-version}</karaf-version>
</properties>
</profile>
+ <profile>
+ <id>karaf4</id>
+ <properties>
+ <karaf-version>${karaf4-version}</karaf-version>
+ </properties>
+ </profile>
</profiles>
</project>
http://git-wip-us.apache.org/repos/asf/camel/blob/d5855254/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
----------------------------------------------------------------------
diff --git a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
index 524198b..2c1acb5 100644
--- a/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
+++ b/tests/camel-itest-karaf/src/test/java/org/apache/camel/itest/karaf/AbstractFeatureTest.java
@@ -23,17 +23,14 @@ import java.nio.charset.Charset;
import java.util.ArrayList;
import java.util.List;
import java.util.Properties;
-
import javax.inject.Inject;
import org.apache.camel.CamelContext;
+import org.apache.camel.core.osgi.OsgiDefaultCamelContext;
import org.apache.camel.impl.DefaultRouteContext;
import org.apache.camel.model.DataFormatDefinition;
-import org.apache.camel.osgi.CamelContextFactory;
-
import org.junit.After;
import org.junit.Before;
-
import org.ops4j.pax.exam.Option;
import org.ops4j.pax.exam.karaf.options.KarafDistributionOption;
import org.ops4j.pax.exam.karaf.options.LogLevelOption;
@@ -44,7 +41,6 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import static org.junit.Assert.assertNotNull;
-
import static org.ops4j.pax.exam.CoreOptions.maven;
import static org.ops4j.pax.exam.CoreOptions.mavenBundle;
import static org.ops4j.pax.exam.CoreOptions.vmOption;
@@ -130,10 +126,8 @@ public abstract class AbstractFeatureTest {
protected CamelContext createCamelContext() throws Exception {
LOG.info("Creating the CamelContext ...");
setThreadContextClassLoader();
- CamelContextFactory factory = new CamelContextFactory();
- factory.setBundleContext(bundleContext);
- LOG.info("Get the bundleContext is " + bundleContext);
- return factory.createContext();
+ OsgiDefaultCamelContext camel = new OsgiDefaultCamelContext(bundleContext);
+ return camel;
}
protected void setThreadContextClassLoader() {
@@ -249,7 +243,6 @@ public abstract class AbstractFeatureTest {
// we need INFO logging otherwise we cannot see what happens
new LogLevelOption(LogLevelOption.LogLevel.INFO),
-
// install the cxf jaxb spec as the karaf doesn't provide it by default
KarafDistributionOption.features(getCamelKarafFeatureUrl(), features)
};