IllegalArgumentException when upgrading to wildfly 31

340 views
Skip to first unread message

VIJAYABHASKARA REDDY

unread,
Mar 25, 2024, 12:52:32 PM3/25/24
to WildFly
Hi,

We are upgrading to wildly 31 Final from wildly 23 and getting below error while deploying a war file which contains code for a web service. Can some one help me how to resolve this issue?

we have the following listener class in web xml

<listener>
        < listener-class> com.sun.xml.ws.transport.http.servlet.WSServletContextListener
                       </listener-class>
  </listener>

I tried to use jakarta.servlet.ServletContextListener but getting below exception. could you please tell me which similar class we should use from Jakarta to avoid this exception in deployment.

<listener>
    <listener-class>jakarta.servlet.ServletContextListener</listener-class>
</listener>
{"WFLYCTL0080: Failed services" => {"jboss.deployment.unit.\"brews.war\".undertow-deployment.UndertowDeploymentInfoService" => "Failed to start service
    Caused by: java.lang.IllegalArgumentException: UT010012: Listener class class com.sun.xml.ws.transport.http.servlet.WSServletContextListener must implement at least one listener interface"}}

Thanks
--Vijay


Emmanuel Hugonnet

unread,
Mar 27, 2024, 3:20:54 AM3/27/24
to wil...@googlegroups.com
com.sun.xml.ws.transport.http.servlet.WSServletContextListener is not JakartaEE 10 compatible as it doesn't implement the proper interface
jakarta.servlet.ServletContextListener
You need to upgrade your code/dependency there

Emmanuel
> --
> You received this message because you are subscribed to the Google Groups "WildFly" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to wildfly+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/wildfly/3e5903d4-6d2b-4261-803c-245a5b1aee82n%40googlegroups.com
> <https://groups.google.com/d/msgid/wildfly/3e5903d4-6d2b-4261-803c-245a5b1aee82n%40googlegroups.com?utm_medium=email&utm_source=footer>.

VIJAYABHASKARA REDDY

unread,
Mar 27, 2024, 5:46:40 AM3/27/24
to WildFly
Hi Emmanuel,

Thanks for your response.

I have updated code to use Jakarta EE compatible and removed unwanted servlet mapping and servlet tag in web xml. added dependency for jakarta.servlet-api jar in jboss-deployment-structure.xml. The war got deployed fine but i dont see any service getting created \started. the war file has one web service which supposed to start as soon as we start wildfly. i also has deployed another war which has many services but I am not able to access those services in browser. could you please let me know what could be the issue here?

Thanks
--Vijay
Reply all
Reply to author
Forward
0 new messages