tesshucom / jpsonic

This is a repository for development. See https://github.com/jpsonic/jpsonic
GNU General Public License v3.0
13 stars 13 forks source link

AsyncRequestNotUsableException (Jetty) #2638

Closed tesshucom closed 1 month ago

tesshucom commented 1 month ago

Problem description

An unknown warning will be logged in the log. There is no problem with playing music.

Suppressed: org.springframework.web.context.request.async.AsyncRequestNotUsableException: Response not usable after response errors.
at org.springframework.web.context.request.async.StandardServletAsyncWebRequest$LifecycleHttpServletResponse.obtainLockAndCheckState(StandardServletAsyncWebRequest.java:314) ~[spring-web-6.1.6.jar!/:6.1.6]
at org.springframework.web.context.request.async.StandardServletAsyncWebRequest$LifecycleServletOutputStream.close(StandardServletAsyncWebRequest.java:401) ~[spring-web-6.1.6.jar!/:6.1.6]
at com.tesshu.jpsonic.controller.StreamController.handleRequest(StreamController.java:427) ~[!/:114.1.1]
... 125 common frames omitted
Caused by: org.eclipse.jetty.io.EofException: null
at org.eclipse.jetty.io.SocketChannelEndPoint.flush(SocketChannelEndPoint.java:117) ~[jetty-io-12.0.8.jar!/:12.0.8]
at org.eclipse.jetty.io.WriteFlusher.flush(WriteFlusher.java:422) ~[jetty-io-12.0.8.jar!/:12.0.8]
at org.eclipse.jetty.io.WriteFlusher.completeWrite(WriteFlusher.java:377) ~[jetty-io-12.0.8.jar!/:12.0.8]
at org.eclipse.jetty.io.SelectableChannelEndPoint$2.run(SelectableChannelEndPoint.java:67) ~[jetty-io-12.0.8.jar!/:12.0.8]
... 9 common frames omitted
Caused by: java.io.IOException: Broken pipe
at java.base/sun.nio.ch.SocketDispatcher.writev0(Native Method) ~[na:na]
at java.base/sun.nio.ch.SocketDispatcher.writev(Unknown Source) ~[na:na]
at java.base/sun.nio.ch.IOUtil.write(Unknown Source) ~[na:na]
at java.base/sun.nio.ch.IOUtil.write(Unknown Source) ~[na:na]
at java.base/sun.nio.ch.SocketChannelImpl.write(Unknown Source) ~[na:na]
at java.base/java.nio.channels.SocketChannel.write(Unknown Source) ~[na:na]
at org.eclipse.jetty.io.SocketChannelEndPoint.flush(SocketChannelEndPoint.java:111) ~[jetty-io-12.0.8.jar!/:12.0.8]

Steps to reproduce

  1. Not clear. Play music.

System information

Additional notes

Upgrading jetty-ee10-apache-jsp to 12.0.9 may worsen the symptoms. (There is a problem with playing music) An investigation would be necessary. If Revert of Jetty is possible, consider it.

Related : #2632

tesshucom commented 1 month ago

This problem can be avoided by reverting to 12.0.6 (jetty-io is actually the origin of the problem). It seems that similar issues have probably been reported, so it would be a good idea to revert and monitor the progress.

tesshucom commented 1 month ago

Create a pull request.