I'm devoloping a REST service by using spring boot running with embedded tomcat (9.0.33).I have a method reading a Blocking Queue populated by a websocket.At the moment just one thread calls the method.
As you can see by looking at the following stack trace the method is started by tomcat thread: http-nio-26579-exec-10
2020-11-26 18:58:46,325 INFOit.smartit.webdriver.chrome.controller.WebDriverController[http-nio-26579-exec-10] ON DOCUMENT COMPLETE START: InitDate<1606413524887> ComparatorType WaitUrl<postamef.tesoro.it/owa/#path=/mail> TimeOutMillis <20000>CaseSensitive LogUrl IgnoreCase TargetSourceType 2020-11-26 18:58:46,731 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A Received Event <Page.frameNavigated>Params:<{"frame":{"id":"5E0C699835BA52CD8CC3C79491D6D11A","loaderId":"C6A34E1346F6DD3EBC9A76829A1786AC","url":"https://postamef.tesoro.it/owa/","domainAndRegistry":"tesoro.it","securityOrigin":"https://postamef.tesoro.it","mimeType":"text/html","adFrameType":"none","secureContextType":"Secure","crossOriginIsolatedContextType":"NotIsolated"}}>2020-11-26 18:58:48,338 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A Received Event<Page.domContentEventFired> Params: <{"timestamp":1.4471599344378E7}>2020-11-26 18:58:48,402 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A Received Event <Page.loadEventFired>Params: <{"timestamp":1.4471599347438E7}> 2020-11-26 18:58:48,405 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A Received Event<Page.frameStoppedLoading> Params:<{"frameId":"5E0C699835BA52CD8CC3C79491D6D11A"}> 2020-11-2618:58:48,409 INFO it.smartit.chromiumclient.ChromiumDevToolsSession[http-nio-26579-exec-10] SessionID 5E0C699835BA52CD8CC3C79491D6D11A -Sent messagge{"id":46,"method":"Target.getTargetInfo","params":{"targetId":"5E0C699835BA52CD8CC3C79491D6D11A"}}to chromium 2020-11-26 18:58:48,409 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A ON Message<{"id":46,"result":{"targetInfo":{"targetId":"5E0C699835BA52CD8CC3C79491D6D11A","type":"page","title":"Caricamentoincorso...","url":"https://postamef.tesoro.it/owa/","attached":true,"canAccessOpener":false,"browserContextId":"FBB2F927C4A59A5405562E874642B8B8"}}}>2020-11-26 18:58:48,412 INFOit.smartit.commonwebdriver.AbstractChromiumWebDriver[http-nio-26579-exec-10] EventUrl https://postamef.tesoro.it/owa/2020-11-26 18:58:49,312 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A Received Event<Page.frameScheduledNavigation> Params:<{"frameId":"5E0C699835BA52CD8CC3C79491D6D11A","delay":0,"reason":"scriptInitiated","url":"https://postamef.tesoro.it/owa/#path=/mail"}>2020-11-26 18:58:49,317 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A Received Event<Page.navigatedWithinDocument> Params:<{"frameId":"5E0C699835BA52CD8CC3C79491D6D11A","url":"https://postamef.tesoro.it/owa/#path=/mail"}>2020-11-26 18:58:49,317 INFOit.smartit.chromiumclient.ChromiumWebsocketClient[WebSocketClient-AsyncIO-1] SessionID:5E0C699835BA52CD8CC3C79491D6D11A Received Event<Page.frameClearedScheduledNavigation> Params:<{"frameId":"5E0C699835BA52CD8CC3C79491D6D11A"}> 2020-11-2618:58:49,507 INFO it.smartit.commonwebdriver.AbstractChromiumWebDriver[Thread-7] Queue event found
The method calls another method on the class it.smartit.commonwebdriver.AbstractChromiumWebDriver.
The strange thing is that in some circumstaces (Most of times everything works fine), the queue is read by a thread named Thread-7 and no result arrives to the caller.Does someone know what thread-7 stand for? In haven't fond anything searching on the web about this problem.
I also tried to using jetty, but I faced on the same problem (a thread different the QTP is sometimes used). It looks like web server sometimes uses a thraed that is different than the pooling threads.