Skip to content

Commit c3472a6

Browse files
committed
Adjust netty options
1 parent 81d8b61 commit c3472a6

File tree

1 file changed

+3
-0
lines changed
  • backend/src/main/scala/com/softwaremill/bootzooka/http

1 file changed

+3
-0
lines changed

backend/src/main/scala/com/softwaremill/bootzooka/http/HttpApi.scala

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ class HttpApi(
4747
.corsInterceptor(CORSInterceptor.default[Identity])
4848
.metricsInterceptor(OpenTelemetryMetrics.default[Identity](otel).metricsInterceptor())
4949
.options
50+
// when the frontend cancels a request, and the server-side logic is then interrupted, this often causes DB connections
51+
// to be marked as broken; re-establishing might be more costly, then just running the cancelled request to completion
52+
.copy(interruptServerLogicWhenRequestCancelled = false)
5053

5154
val allEndpoints: List[ServerEndpoint[Any, Identity]] =
5255
// The /api/v1 context path is added using Swagger's options, not to the endpoints.

0 commit comments

Comments
 (0)