本文整理汇总了Java中org.ops4j.pax.exam.options.MavenUrlReference类的典型用法代码示例。如果您正苦于以下问题:Java MavenUrlReference类的具体用法?Java MavenUrlReference怎么用?Java MavenUrlReference使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
MavenUrlReference类属于org.ops4j.pax.exam.options包,在下文中一共展示了MavenUrlReference类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: configuration
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Configuration
public static Option[] configuration() throws Exception {
MavenArtifactUrlReference karaf = maven().groupId("org.apache.karaf").artifactId("apache-karaf")
.type("zip").version("4.0.7");
MavenUrlReference brave = maven().groupId("io.zipkin.brave.karaf").artifactId("brave-features").type("xml")
.classifier("features").version("1.0.0-SNAPSHOT");
return new Option[] //
{
karafDistributionConfiguration().frameworkUrl(karaf).useDeployFolder(false),
configureConsole().ignoreLocalConsole(), //
logLevel(LogLevel.INFO), //
keepRuntimeFolder(), //
features(brave, "brave-core", "brave-kafka08"),
// Create an empty config to trigger creation of component
newConfiguration("io.zipkin.reporter.urlconnect").asOption(),
newConfiguration("io.zipkin.reporter.kafka08").asOption()
};
}
示例2: configuration
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Configuration
public Option[] configuration() {
MavenUrlReference karafStandardFeature = maven()
.groupId("org.apache.karaf.features").artifactId("standard")
.type("xml").classifier("features").versionAsInProject();
return combine(
configurationMinimal(),
// KarafDistributionOption.debugConfiguration("9999", true),
KarafDistributionOption.replaceConfigurationFile("credential.store", new File("target/test-classes/credential.store")),
environment("CREDENTIAL_STORE_PROTECTION_ALGORITHM=masked-MD5-DES"),
environment("CREDENTIAL_STORE_PROTECTION_PARAMS=MDkEKXNvbWVhcmJpdHJhcnljcmF6eXN0cmluZ3RoYXRkb2Vzbm90bWF0dGVyAgID6AQIQt//5Ifg0x8="),
environment("CREDENTIAL_STORE_PROTECTION=9KjAtKnaEnb3hgj+67wrS85IHABrZXBgG2gShcQ9kEGl4zjV9TLfyEwxBJ6836dI"),
environment("CREDENTIAL_STORE_ATTR_location=credential.store"),
vmOption("-Dprop=CS:key"),
KarafDistributionOption.features(karafStandardFeature, "management")
);
}
示例3: additionalKarafConfig
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public List<Option> additionalKarafConfig() {
final MavenUrlReference apixRepo =
maven().groupId("org.fcrepo.apix")
.artifactId("fcrepo-api-x-karaf").versionAsInProject()
.classifier("features").type("xml");
final ArrayList<Option> options = new ArrayList<>(super.additionalKarafConfig());
options.addAll(Arrays.asList(
editConfigurationFilePut("etc/system.properties", "reindexing.dynamic.test.port", System.getProperty(
"reindexing.dynamic.test.port")),
deployFile("cfg/org.fcrepo.camel.reindexing.cfg"),
deployFile("cfg/org.fcrepo.camel.service.activemq.cfg"),
deployFile("cfg/org.fcrepo.camel.service.cfg"),
deployFile("cfg/org.fcrepo.apix.indexing.cfg"),
features(apixRepo, "fcrepo-api-x-indexing")));
return options;
}
示例4: additionalKarafConfig
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public List<Option> additionalKarafConfig() {
final List<Option> options = new ArrayList<>(super.additionalKarafConfig());
// This test dependency is not in any features files, so we have to add it manually.
final MavenArtifactUrlReference jsoup = maven().groupId("org.jsoup")
.artifactId("jsoup")
.versionAsInProject();
final MavenUrlReference apixRepo =
maven().groupId("org.fcrepo.apix")
.artifactId("fcrepo-api-x-karaf").versionAsInProject()
.classifier("features").type("xml");
options.addAll(Arrays.asList(mavenBundle(jsoup), features(apixRepo, "fcrepo-api-x-loader")));
return options;
}
示例5: getFeatureRepo
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public MavenUrlReference getFeatureRepo() {
return maven()
.groupId("org.opendaylight.hello")
.artifactId("hello-features")
.classifier("features")
.type("xml")
.versionAsInProject();
}
示例6: getFeatureRepo
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public MavenUrlReference getFeatureRepo() {
return maven()
.groupId("org.opendaylight.fpc")
.artifactId("fpc-features")
.classifier("features")
.type("xml")
.versionAsInProject();
}
示例7: getFeatureRepo
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public MavenUrlReference getFeatureRepo() {
return maven()
.groupId("com.hashcms")
.artifactId("sdna-features")
.classifier("features")
.type("xml")
.versionAsInProject();
}
示例8: getFeatureRepo
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public MavenUrlReference getFeatureRepo() {
return maven()
.groupId("${groupId}")
.artifactId("features-${artifactId}")
.classifier("features")
.type("xml")
.versionAsInProject();
}
示例9: baseConfiguration
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
/**
*
* @param fuseDistroArtifact
* @return
*/
protected Option[] baseConfiguration(String fuseDistroArtifact) {
MavenUrlReference fuseDistro = maven()
.groupId("org.jboss.fuse").artifactId(fuseDistroArtifact)
.type("zip").versionAsInProject();
MavenUrlReference karafStandardFeature = maven()
.groupId("org.jboss.fuse").artifactId("fuse-karaf-framework")
.type("xml").classifier("features").versionAsInProject();
return combine(
new Option[] {
karafDistributionConfiguration().frameworkUrl(fuseDistro)
.unpackDirectory(new File("target/paxexam")),
keepRuntimeFolder(),
configureConsole().ignoreLocalConsole(),
editConfigurationFilePut("etc/branding.properties", "welcome", ""),
editConfigurationFilePut("etc/branding-ssh.properties", "welcome", ""),
// feature exam/4.11.0 uses:
// <bundle dependency="true">mvn:org.apache.geronimo.specs/geronimo-atinject_1.0_spec/1.0</bundle>
// we'll override it
mavenBundle("org.apache.servicemix.bundles", "org.apache.servicemix.bundles.javax-inject").versionAsInProject(),
mavenBundle("org.jboss.fuse.itests", "fuse-itests-common").versionAsInProject()
},
// logging configuration
editConfigurationFilePut("etc/org.ops4j.pax.logging.cfg", new File("src/test/resources/etc/org.ops4j.pax.logging.cfg"))
);
}
示例10: config
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Configuration
public Option[] config() {
MavenUrlReference fuseDistro = maven()
.groupId("org.jboss.fuse").artifactId("jboss-fuse-karaf-minimal")
.type("zip").versionAsInProject();
return options(
karafDistributionConfiguration().frameworkUrl(fuseDistro),
configureConsole().ignoreRemoteShell().ignoreLocalConsole(),
systemTimeout(60000),
vmOptions("-Dprop=CS:key"),
logLevel(LogLevelOption.LogLevel.WARN)
);
}
示例11: additionalKarafConfig
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public List<Option> additionalKarafConfig() {
final MavenUrlReference apixRepo =
maven().groupId("org.fcrepo.apix")
.artifactId("fcrepo-api-x-karaf").versionAsInProject()
.classifier("features").type("xml");
return Arrays.asList(
features(apixRepo, "fcrepo-api-x-listener"),
deployFile("cfg/org.fcrepo.camel.service.activemq.cfg"));
}
示例12: setupContainer
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
protected Option[] setupContainer() {
MavenArtifactUrlReference karafUrl = maven()
.groupId(KARAF_GROUP_ID)
.artifactId(KARAF_ARTIFACT_ID)
.version(KARAF_VERSION)
.type("zip");
MavenUrlReference paxJdbcFeaturesRepo = maven()
.groupId(PAXJDBC_FEATURES_GROUP_ID)
.artifactId(PAXJDBC_FEATURE)
.classifier("features")
.type("xml")
.version(PAX_JDBC_VERSION);
//.versionAsInProject(); //this is not working ???
File jdbcConfigFile = new File("src/test/resources/demodbDS.properties");
//Setup pax-jdbc datasource
Option[] configOptions = editConfigurationFilePut("etc/org.ops4j.datasource-demodbDS.cfg", jdbcConfigFile);
Option[] baseOptions = options(karafDistributionConfiguration()
.frameworkUrl(karafUrl)
.unpackDirectory(new File("target/exam"))
.useDeployFolder(false)
.karafVersion(KARAF_VERSION)
.name("Apache Karaf"),
configureConsole().ignoreLocalConsole(),
logLevel(LogLevelOption.LogLevel.INFO),
keepRuntimeFolder(),
//Features
features(paxJdbcFeaturesRepo, "transaction", "jndi", "pax-jdbc-config", "pax-jdbc-h2")
);
return combine(configOptions, baseOptions);
}
示例13: getFeatureRepo
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public MavenUrlReference getFeatureRepo() {
return maven()
.groupId("odl.example")
.artifactId("odlexample-features")
.classifier("features")
.type("xml")
.versionAsInProject();
}
示例14: getFeatureRepo
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Override
public MavenUrlReference getFeatureRepo() {
return maven()
.groupId("org.opendaylight.neutron")
.artifactId("features-neutron-test")
.classifier("features")
.type("xml")
.versionAsInProject();
}
示例15: config
import org.ops4j.pax.exam.options.MavenUrlReference; //导入依赖的package包/类
@Configuration
public Option[] config() throws Exception{
MavenArtifactUrlReference karafUrl = maven()
.groupId("org.apache.karaf")
.artifactId("apache-karaf")
.versionAsInProject()
.type("tar.gz");
MavenUrlReference karafStandardRepo = maven()
.groupId("org.apache.karaf.features")
.artifactId("standard")
.classifier("features")
.type("xml")
.versionAsInProject();
MavenUrlReference managedPropertiesRepo = maven()
.groupId("dk.netdesign")
.artifactId("managedproperties-feature")
.classifier("features")
.type("xml")
.versionAsInProject();
return new Option[] {
// KarafDistributionOption.debugConfiguration("5005", true),
karafDistributionConfiguration()
.frameworkUrl(karafUrl)
.unpackDirectory(new File("exam"))
.useDeployFolder(false),
keepRuntimeFolder(),
features(karafStandardRepo, "scr", "webconsole"),
features(managedPropertiesRepo, "ManagedProperties", "ManagedPropertiesTestResources"),
replaceConfigurationFile("etc/org.ops4j.pax.logging.cfg", new File(this.getClass().getClassLoader().getResource("dk/netdesign/common/osgi/config/test/org.ops4j.pax.logging.cfg").toURI())),
replaceConfigurationFile("etc/org.ops4j.pax.url.mvn.cfg", new File(this.getClass().getClassLoader().getResource("dk/netdesign/common/osgi/config/test/org.ops4j.pax.url.mvn.cfg").toURI())),
replaceConfigurationFile("etc/WrapperTypes.cfg", new File(this.getClass().getClassLoader().getResource("dk/netdesign/common/osgi/config/test/WrapperTypes.cfg").toURI())),
replaceConfigurationFile("etc/FilteringConfig.cfg", new File(this.getClass().getClassLoader().getResource("dk/netdesign/common/osgi/config/test/FilteringConfig.cfg").toURI())),
replaceConfigurationFile("etc/AutoFilteringListTypes.cfg", new File(this.getClass().getClassLoader().getResource("dk/netdesign/common/osgi/config/test/AutoFilteringListTypes.cfg").toURI())),
};
}