Getting abort after first request is successfully answered #4547
-
I built a simple web server (based essentially on this https://pocoproject.org/slides/200-Network.pdf) and I am getting an abort of the server on the second request (ie; after the first request is successfully received, processed and answered), in other words I don't see handleRequest() the second time. I am not sure what is happening as the abort message is not including any more diagnostic information with it. It's very similar behavior to this stack overflow (https://stackoverflow.com/questions/77883686/poco-httprequesthandler-handlerequest-aborting-after-multiple-requests) but I am not using the logger and I don't know what else it could be. I have simplified it down to responding to the request in the handleRequest() function and it still fails. Is there a way to make Poco give more detailed error messages? Anything I should be looking at? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
So I finally found the problem. The handler is destroyed by Poco and I have been passing in a handler that I assumed would survive from request to request. Thus it was not valid on the second request. Better error messages would have made this much clearer what was happening. Simply stating "Abort" is not useful. |
Beta Was this translation helpful? Give feedback.
So I finally found the problem. The handler is destroyed by Poco and I have been passing in a handler that I assumed would survive from request to request. Thus it was not valid on the second request. Better error messages would have made this much clearer what was happening. Simply stating "Abort" is not useful.