jetty启动项目时,BUILD FAILURE,程序包com.sun.org.apache.xml.internal.security.utils不存在
·
问题描述:
使用jetty:run启动项目时,build failure,程序包不存在
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.678 s
[INFO] Finished at: 2017-09-14T23:34:18+08:00
[INFO] Final Memory: 17M/142M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project crm: Compilation failure: Compilation failure:
[ERROR]/E:/EclipseWorkspace/.../src/main/java/com/...utils/UserIDBase64.java:[5,54] 程序包com.sun.org.apache.xml.internal.security.utils不存在
[ERROR] /E:/EclipseWorkspace/...理/src/main/java/com/.../utils/UserIDBase64.java:[23,59] 找不到符号
[ERROR] 符号: 变量 Base64
[ERROR] 位置: 类 com....utils.UserIDBase64
[ERROR] /E:/...理/src/main/java/com/.../utils/UserIDBase64.java:[36,46] 找不到符号
[ERROR] 符号: 变量 Base64
[ERROR] 位置: 类 com.....utils.UserIDBase64
[ERROR] /E:/EclipseWorkspace/...理/src/main/java/com/.../utils/UserIDBase64.java:[37,53] 找不到符号
[ERROR] 符号: 变量 Base64
[ERROR] 位置: 类 com.....utils.UserIDBase64
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
解决方式:添加下面一段内容,指明rt.jar的路径
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
<compilerArguments>
<bootclasspath>${JAVA_HOME}/jre/lib/rt.jar</bootclasspath>
</compilerArguments>
</configuration>
</plugin>
魔乐社区(Modelers.cn) 是一个中立、公益的人工智能社区,提供人工智能工具、模型、数据的托管、展示与应用协同服务,为人工智能开发及爱好者搭建开放的学习交流平台。社区通过理事会方式运作,由全产业链共同建设、共同运营、共同享有,推动国产AI生态繁荣发展。
更多推荐


所有评论(0)