diff options
author | Jon Marius Venstad <venstad@gmail.com> | 2021-03-15 12:06:57 +0100 |
---|---|---|
committer | Jon Marius Venstad <venstad@gmail.com> | 2021-03-15 12:06:57 +0100 |
commit | 335bc1ee552115d659bb58c0cb8501b743c7df92 (patch) | |
tree | c8f0e6d1d4fbd27b17fa69e69bc804dd85975ab2 | |
parent | b7027ef7f782df562f60a74cf09d77aab2105193 (diff) |
Destroy visitor sessions after catching and handling exception
-rw-r--r-- | vespaclient-container-plugin/src/main/java/com/yahoo/document/restapi/resource/DocumentV1ApiHandler.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/vespaclient-container-plugin/src/main/java/com/yahoo/document/restapi/resource/DocumentV1ApiHandler.java b/vespaclient-container-plugin/src/main/java/com/yahoo/document/restapi/resource/DocumentV1ApiHandler.java index 9b198ce8df9..c43c79ab5e6 100644 --- a/vespaclient-container-plugin/src/main/java/com/yahoo/document/restapi/resource/DocumentV1ApiHandler.java +++ b/vespaclient-container-plugin/src/main/java/com/yahoo/document/restapi/resource/DocumentV1ApiHandler.java @@ -1102,10 +1102,10 @@ public class DocumentV1ApiHandler extends AbstractRequestHandler { response.respond(Response.Status.INTERNAL_SERVER_ERROR); } - visitDispatcher.execute(() -> { - phaser.arriveAndAwaitAdvance(); // We may get here while dispatching thread is still putting us in the map. - visits.remove(this).destroy(); - }); + }); + visitDispatcher.execute(() -> { + phaser.arriveAndAwaitAdvance(); // We may get here while dispatching thread is still putting us in the map. + visits.remove(this).destroy(); }); } }; |