小编典典

我在春天使用加载时间编织。我如何在码头上设置类装载机?

java

我在春天使用加载时间编织。一切都可以在websphere上正常工作,因为它具有自己的类加载器,但是我在使用嵌入式码头的开发人员模式下遇到麻烦。我如何在码头上设置类装载机?

当我运行它时,我看到以下错误

[INFO] org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.context.weaving.AspectJWeavingEnabler#0': Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loadTimeWeaver': Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.springframework.instrument.classloading.ReflectiveLoadTimeWeaver]: Constructor threw exception; nested exception is java.lang.IllegalStateException: ClassLoader [com.google.gwt.dev.shell.jetty.JettyLauncher$WebAppContextWithReload$WebAppClassLoaderExtension] does NOT provide an 'addTransformer(ClassFileTransformer)' method.

阅读 208

收藏
2020-11-23

共1个答案

小编典典

我通过添加“ -Xbootclasspath / a:[jar的路径]”作为JvmArgs参数来解决了该问题。现在看起来

<extraJvmArgs>-Xmx4g -XX:MaxPermSize=512m -javaagent:C:\Users\auldanov\.m2\repository\org\springframework\spring-instrument\3.1.4.RELEASE\spring-instrument-3.1.4.RELEASE.jar -Xbootclasspath/a:C:\Users\auldanov\.m2\repository\org\springframework\spring-instrument\3.1.4.RELEASE\spring-instrument-3.1.4.RELEASE.jar</extraJvmArgs>
2020-11-23