我对ejb2感兴趣,并且在代码中的某个地方,ejb2遗留代码正在尝试加载属性,我想在spring boot application.properties上重定向它。但是我真的不知道如何与ejb共享spring boot依赖注入类。没有可能做到这一点?我读过一些关于Ear类加载器的信息,但是我是否有点困惑,是否有可能共享同一个JVM类加载器。谢谢
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-ear-plugin</artifactId>
<version>2.9</version>
<executions>
<execution>
<id>default-ear</id>
<phase>package</phase>
<goals>
<goal>ear</goal>
</goals>
<configuration>
<defaultLibBundleDir>lib</defaultLibBundleDir>
<generateApplicationXml>false</generateApplicationXml>
<modules>
<ejbModule>
<groupId>mygrp</groupId>
<artifactId>MyEjb2</artifactId>
<bundleFileName>myejb2.jar</bundleFileName>
</ejbModule>
<webModule>
<groupId>mygrp</groupId>
<artifactId>MySpringBootWar</artifactId>
</webModule>
</modules>
</configuration>
</execution>
</executions>
<configuration>
<skinnyWars>true</skinnyWars>
<version>5</version>
<defaultLibBundleDir>APP-INF/lib</defaultLibBundleDir>
<earSourceDirectory>src/main/application</earSourceDirectory>
<earSourceIncludes>APP-INF/**/*.*,META-INF/**/*.*</earSourceIncludes>
<earSourceExcludes>**/.copyarea.db,**/**.keep*</earSourceExcludes>
<generateApplicationXml>false</generateApplicationXml>
</configuration>