Hi everybody,
Currently, I am working on a template project for servlet 5.0,
Firstly I want to run the application via cargo maven plugin(tomat) and jetty maven plugin .but encountered an issue with configuring Jetty maven plugin.
When running the following command and failed.
> >mvn clean package jetty:run-war -Pjetty
Apr 03, 2021 10:04:58 PM org.jboss.weld.environment.servlet.WeldServletLifecycle initialize
INFO: WELD-ENV-001001: No supported servlet container detected, CDI injection will NOT be available in Servlets, Filters or Listeners
[WARNING] Failed startup of context o.e.j.m.p.MavenWebAppContext@c79780{/jakartaee9-servlet-starter-boilerplate,[file:///D:/hantsylabs/jakartaee9-servlet-starter-boilerplate/target/jak
artaee9-servlet-starter-boilerplate/, jar:file:///D:/hantsylabs/jakartaee9-servlet-starter-boilerplate/target/jakartaee9-servlet-starter-boilerplate/WEB-INF/lib/jakarta.faces-3.0.0.jar
!/META-INF/resources],UNAVAILABLE}{D:\hantsylabs\jakartaee9-servlet-starter-boilerplate\target\jakartaee9-servlet-starter-boilerplate.war}
java.lang.LinkageError: loader constraint violation: when resolving interface method 'void jakarta.servlet.jsp.JspApplicationContext.addELResolver(jakarta.el.ELResolver)' the class loa
der org.eclipse.jetty.webapp.WebAppClassLoader @51c6e775 of the current class, org/jboss/weld/environment/servlet/WeldServletLifecycle, and the class loader org.codehaus.plexus.classwo
rlds.realm.ClassRealm @cef885d for the method's defining class, jakarta/servlet/jsp/JspApplicationContext, have different Class objects for the type jakarta/el/ELResolver used in the s
ignature (org.jboss.weld.environment.servlet.WeldServletLifecycle is in unnamed module of loader org.eclipse.jetty.webapp.WebAppClassLoader @51c6e775, parent loader org.codehaus.plexus
.classworlds.realm.ClassRealm @cef885d; jakarta.servlet.jsp.JspApplicationContext is in unnamed module of loader org.codehaus.plexus.classworlds.realm.ClassRealm @cef885d, parent loade
r 'bootstrap')
I have read the weld doc, and jetty doc, I can not find some way to fix it.