Support for Atlassian Server Products (and apps like BigPicture) is ending in February 2024.

Are you planning a migration to Cloud? Make sure you don't lose your BigPicture data/configurations in the process. Check out this page for information on how to migrate BigPicture's data to Cloud. If you have any questions please email

Thread stuck on SocketInputStream.socketRead0


  • Threads are timeouting waiting for a lock
  • DB's connections are held for a long time and there are exceptions on retrieving new connections - pool is exhausted

Problem identification

In order to properly identify a problem, thread dumps should be taken at the time it occurs. It is also possible to spot a problem after first symptoms were seen, as threads might be stuck indefinitely. 

Sample thread dump with a stuck thread looks as follows:

"SP-bigpicture-0000000.TaskSyncSingleJobExecutor-2791" prio=5 tid=0x0000000000000ae7 nid=0 runnable
java.lang.Thread.State: RUNNABLE
at java.base@11.0.15/ Method)
at java.base@11.0.15/
at java.base@11.0.15/
at java.base@11.0.15/
at java.base@11.0.15/
at java.base@11.0.15/
at java.base@11.0.15/
at java.base@11.0.15/
at java.base@11.0.15/$
at org.postgresql.core.VisibleBufferedInputStream.readMore(
at org.postgresql.core.VisibleBufferedInputStream.ensureBytes(
at org.postgresql.core.VisibleBufferedInputStream.ensureBytes(
at org.postgresql.core.PGStream.receiveChar(
at org.postgresql.core.v3.QueryExecutorImpl.processResults(
at org.postgresql.core.v3.QueryExecutorImpl.execute(

 - locked <0x000000001880e144> (a org.postgresql.core.v3.QueryExecutorImpl)
at org.postgresql.jdbc.PgStatement.executeInternal(
at org.postgresql.jdbc.PgStatement.execute(
at org.postgresql.jdbc.PgPreparedStatement.executeWithFlags(
at org.postgresql.jdbc.PgPreparedStatement.executeQuery(
at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeQuery(
at org.apache.commons.dbcp2.DelegatingPreparedStatement.executeQuery(

If few consecutive thread dumps (separated by several seconds) contain the same thread in RUNNABLE state at SocketInputStream.socketRead0 method, then the problem has been identified. 


This is a network problem with broken connection between Jira and Database. While connections are expected to break, there are some network setups that may inhibit information about one end of connection breaking being passed to other end. 
It has been identified that some proxies between Jira and Database might still keep Jira socket open. This socket, not knowing that database on the other end is no longer available, may keep waiting to receive last bytes of data infinitely. 

Atlassian is aware of the problem and proposes a solution:
This may not work for newer Jira versions. 

To solve the problem, one may: 

  • identify proxy that is not closing open socket and further investigate the reason, fixing the problem in network connectivity
  • contant Atlassian for further help as Jira is maintaining connection pool to database