本地启动jetty时报错,发现tomcat-jdbc和本地jetty冲突,原因是因为父类加载顺序出现了问题
Exception in thread "main" java.util.ServiceConfigurationError: org.apache.juli.logging.Log: Provider org.eclipse.jetty.apache.jsp.JuliLog not a subtype
解决方案:添加绿色字体那一行,
<plugin> <groupId>org.eclipse.jetty</groupId> <artifactId>jetty-maven-plugin</artifactId> <configuration> <webAppConfig> <contextPath>/test</contextPath> <parentLoaderPriority>true</parentLoaderPriority> </webAppConfig> <httpConnector> <port>8080</port> </httpConnector> </configuration> </plugin>
Started Jetty Server
问题解决~