How to handle Jetty exception - a long running HTTP request times out, but the process it calls never terminates and Jetty is unhappy

后端 未结 2 672
灰色年华
灰色年华 2021-02-14 13:05

I have a Jetty server handling long running HTTP requests- the responses are generated by an a different process X and end up in a collector hash which Jetty requests periodical

2条回答
  •  感动是毒
    2021-02-14 13:48

    Using try catch block might help in this case.

       try{
          ctx.complete()
       } catch (IllegalStateException e){
          //Handle it the way you prefer.
       }
    

提交回复
热议问题