Jira Data Center REST API thread persistence after abrupt client disconnect
0 reputation · 10 Jun 2022, 07:49 UTC
In Jira Data Center, long-running REST API operations such as bulk changes or large issue exports are often processed via background worker threads. While the jira.rest.http.connectionTimeout setting governs the duration of the HTTP connection, there is uncertainty regarding how the application handles the loss of the client-side connection.
When a client abruptly terminates a connection or a load balancer timeout occurs before a synchronous request completes, the server-side worker thread may continue to process the task. This creates a risk of orphaned threads that maintain database locks until the process naturally finishes or a hard database-level timeout is reached.
Does Jira provide a mechanism to terminate active worker threads when the associated HTTP request is cancelled? Furthermore, is there a configuration option to map connection-level timeouts to the cancellation of underlying background tasks to prevent thread exhaustion?