Wildfly Undertow request failed HttpServerExchange on Webservice

13,333

It seems to be WildFly defect: UNDERTOW-367: NullPointerException when POST method has no ordinary parameters

Share:
13,333
monimo
Author by

monimo

Updated on June 04, 2022

Comments

  • monimo
    monimo almost 2 years

    I am trying to reach a webservice running on my Wildfly instance. The webservice is annotated as Post and accepts JSON. When I try to call the service, my Wildfly throws an Nullpointerexception.

    The actual stack trace looks like this:

    15:23:40,324 ERROR [io.undertow.request] (default task-1) Undertow request  failed HttpServerExchange{ POST <path to my service>}: java.lang.NullPointerException
    at io.undertow.servlet.spec.ServletInputStreamImpl.readIntoBuffer(ServletInputStreamImpl.java:171)
    at io.undertow.servlet.spec.ServletInputStreamImpl.close(ServletInputStreamImpl.java:245)
    at io.undertow.servlet.spec.HttpServletRequestImpl.closeAndDrainRequest(HttpServletRequestImpl.java:602)
    at io.undertow.servlet.core.ServletBlockingHttpExchange.close(ServletBlockingHttpExchange.java:87)
    at io.undertow.server.HttpServerExchange.endExchange(HttpServerExchange.java:1444)
    at io.undertow.server.Connectors.executeRootHandler(Connectors.java:213)
    at io.undertow.server.HttpServerExchange$1.run(HttpServerExchange.java:759)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_75]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_75]
    at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_75]
    

    I don't really understand what evoked a Nullpointerexception as I am not very familiar with Wildfly development.