helloworld example not working

41 views
Skip to first unread message

deni5n

unread,
Sep 20, 2022, 10:55:10 AMSep 20
to WildFly
hello,


but got an error:

Failed to define class org.jboss.as.quickstarts.helloworld.HelloWorldServlet in Module "deployment.helloworld.war" from Service Module Loader: java.lang.NoClassDefFoundError: Failed to link org/jboss/as/quickstarts/helloworld/HelloWorldServlet (Module "deployment.helloworld.war" from Service Module Loader): jakarta/servlet/http/HttpServlet


server run with:

JBoss Bootstrap Environment

JBOSS_HOME: /home/deni5n/tmp/wfzk/libs/wildfly-26.1.2.Final

JAVA: /usr/lib/jvm/java-11-openjdk-amd64/bin/java

JAVA_OPTS:  -server -Xms64m -Xmx512m -XX:MetaspaceSize=96M -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true -Djboss.modules.system.pkgs=org.jboss.byteman -Djava.awt.headless=true  --add-exports=java.desktop/sun.awt=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.url.ldap=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.url.ldaps=ALL-UNNAMED --add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.lang.invoke=ALL-UNNAMED --add-opens=java.base/java.lang.reflect=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.base/java.security=ALL-UNNAMED --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.util.concurrent=ALL-UNNAMED --add-opens=java.management/javax.management=ALL-UNNAMED --add-opens=java.naming/javax.naming=ALL-UNNAMED

what am I doing wrong?

James Perkins

unread,
Sep 20, 2022, 10:57:32 AMSep 20
to WildFly
It looks like you're using a Jakarta EE 10 quickstart with a Jakarta EE 8 container. You'd need to either use this branch https://github.com/wildfly/quickstart/releases/tag/26.1.2.Final or use WildFly Preview.
Reply all
Reply to author
Forward
0 new messages