我能够在一个新模块中组装一个具有标准和webconsole特性的karaf容器:
<dependencies>
<dependency>
<groupId>org.apache.karaf.features</groupId>
<artifactId>framework</artifactId>
<type>kar</type>
</dependency>
<dependency>
<groupId>org.apache.karaf.features</groupId>
<artifactId>standard</artifactId>
<classifier>features</classifier>
<type>xml</type>
<scope>runtime</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.karaf.tooling</groupId>
<artifactId>karaf-maven-plugin</artifactId>
<version>${org.apache.karaf.features.framework.version}</version>
<extensions>true</extensions>
<configuration>
<bootFeatures>
<feature>standard</feature>
<feature>webconsole</feature>
</bootFeatures>
</configuration>
</plugin>
</plugins>
</build>


现在,我想做更多的事情,我想将我的其他模块/代码添加到这个容器中,一起启动它,并测试我的代码,我的REST调用等等……
我的一个模块是这样的:
<artifactId>config-testutils</artifactId>
<properties>
<bundle.symbolicName>${project.groupId}.${project.artifactId}</bundle.symbolicName>
<bundle.namespace>${project.groupId}.${project.artifactId}</bundle.namespace>
</properties>
<name>${project.groupId}.${project.artifactId}</name>
<packaging>jar</packaging>我如何添加这些模块,以查看它们在我正在组装的Karaf中是否工作正常?除了手动放到deploy文件夹之外,还有其他方法吗?
发布于 2018-11-06 14:39:51
您应该创建一个包含您自己的包的要素,并将其添加到<bootFeatures>中
https://stackoverflow.com/questions/52978782
复制相似问题