Skip to content

Commit

Permalink
Addendum to #12395.
Browse files Browse the repository at this point in the history
Restored synchronous behavior for `HttpConnection.close()`.
This allows to send a response for suspended requests while the server is being stopped.

See also #12435.

Signed-off-by: Simone Bordet <simone.bordet@gmail.com>
  • Loading branch information
sbordet committed Nov 5, 2024
1 parent e2333ea commit 9875eb8
Showing 1 changed file with 1 addition and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -620,20 +620,7 @@ public void close()
{
Runnable task = _httpChannel.onClose();
if (task != null)
{
ThreadPool.executeImmediately(getExecutor(), () ->
{
try
{
task.run();
}
finally
{
super.close();
}
});
return;
}
task.run();
super.close();
}

Expand Down

0 comments on commit 9875eb8

Please sign in to comment.