本文介绍了无法执行目标org.apache.felix:maven-scr-plugin:1.17.0:scr的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
开始使用AEM项目.现在,我正在尝试在本地启动项目,并在构建过程中遇到下一个错误(stacktrace cut):
Started to work with AEM project. Now I am trying to launch project locally and got next error during building (stacktrace cut):
[ERROR] Failed to execute goal org.apache.felix:maven-scr-plugin:1.17.0:scr (generate-scr-scrdescriptor) on project canadian-tire-site-core: Execution generate-scr-scrdescriptor of goal org.apache.felix:maven-scr-plugin:1.17.0:scr failed: org.apache.felix.scrplugin.annotations.AnnotationProcessor is not an ImageIO SPI class -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.felix:maven-scr-plugin:1.17.0:scr (generate-scr-scrdescriptor) on project canadian-tire-site-core: Execution generate-scr-scrdescriptor of goal org.apache.felix:maven-scr-plugin:1.17.0:scr failed: org.apache.felix.scrplugin.annotations.AnnotationProcessor is not an ImageIO SPI class
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:213) .....
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution generate-scr-scrdescriptor of goal org.apache.felix:maven-scr-plugin:1.17.0:scr failed: org.apache.felix.scrplugin.annotations.AnnotationProcessor is not an ImageIO SPI class
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:145) ....
Caused by: java.lang.IllegalArgumentException: org.apache.felix.scrplugin.annotations.AnnotationProcessor is not an ImageIO SPI class
at javax.imageio.spi.ServiceRegistry.checkClassAllowed (ServiceRegistry.java:745) ....
配置文件部分:
<!-- Apache Felix SCR Plugin -->
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-scr-plugin</artifactId>
<version>1.17.0</version>
<executions>
<execution>
<id>generate-scr-scrdescriptor</id>
<goals>
<goal>scr</goal>
</goals>
<configuration>
<properties>
<service.vendor>CTC</service.vendor>
</properties>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>1.5.11</version>
</dependency>
</dependencies>
</plugin>
我还检查了Java和mvn版本,在这里看起来一切正常:
I have also checked Java and mvn versions and looks like everything fine here:
echo $JAVA_HOME
C:\Program Files\Java\jdk-9.0.4
mvn -v
Apache Maven 3.5.2
Maven home: C:\apache-maven-3.5.2-bin
Java version: 9.0.4, vendor: Oracle Corporation
Java home: C:\Program Files\Java\jdk-9.0.4
如果有人可以建议我应该朝哪个方向看,那将很棒.
Would be great if someone can advice in which direction I should look.
推荐答案
AEM 6.3可以不支持 JDK 9
.
AEM 6.3 does not support JDK 9
.
看看这个 jira错误如果您想继续尝试使用JAVA 1.9和AEM,则可以解决该问题.
Take a look at this jira bug for a workaround for your issue if you want to continue experimenting with JAVA 1.9 and AEM.
这篇关于无法执行目标org.apache.felix:maven-scr-plugin:1.17.0:scr的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!