My Oracle Support Banner

Java-level deadlock with 11.2 (Doc ID 1271651.1)

Last updated on FEBRUARY 03, 2019

Applies to:

JDBC - Version 11.2.0.1 and later
Information in this document applies to any platform.
***Checked for relevance on 07-May-2013***

Symptoms

JDBC application is running into a Java-level deadlock when trying to do the following scenario.

Scenario:-

Two different oracle.sql.ARRAY Objects were created using two different physical Connections
For example:
Con1: create oracle.sql.ARRAY A
Con2: create oracle.sql.ARRAY B

Then getting Connections later in the application in the inverse order and try to write
an Array on the Connection at the same time.
Con1: write oracle.sql.ARRAY B
Con2: write oracle.sql.ARRAY A

Stack trace:-


Found one Java-level deadlock:
=============================
"blobberThread-5":
waiting to lock monitor 0x01a86e78 (object 0xe33740e8, a oracle.jdbc.driver.T4CConnection),
which is held by "DeblobberThread-3"
"blobberThread-3":
waiting to lock monitor 0x02d1ba90 (object 0xe31729d8, a oracle.jdbc.driver.T4CConnection),
which is held by "DeblobberThread-5"

Java stack information for the threads listed above:
===================================================
"blobberThread-5":
at oracle.jdbc.oracore.OracleTypeADT.linearize(OracleTypeADT.java:1279)
- waiting to lock <0xe33740e8> (a oracle.jdbc.driver.T4CConnection)
at oracle.sql.ArrayDescriptor.toBytes(ArrayDescriptor.java:680)
at oracle.sql.ARRAY.toBytes(ARRAY.java:661)
- locked <0xe31729d8> (a oracle.jdbc.driver.T4CConnection)
at oracle.jdbc.driver.OraclePreparedStatement.setArrayCritical(OraclePreparedStatement.java:5829)
at oracle.jdbc.driver.OraclePreparedStatement.setARRAYInternal(OraclePreparedStatement.java:5788)
- locked <0xe31729d8> (a oracle.jdbc.driver.T4CConnection)
at oracle.jdbc.driver.OraclePreparedStatement.setArrayInternal(OraclePreparedStatement.java:5743)
at oracle.jdbc.driver.OracleCallableStatement.setArray(OracleCallableStatement.java:4788)
at oracle.jdbc.driver.OraclePreparedStatementWrapper.setArray(OraclePreparedStatementWrapper.java:110)

Changes

Upgraded the Oracle JDBC driver from 10.2 to 11.2.

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Changes
Cause
Solution
References


This document is being delivered to you via Oracle Support's Rapid Visibility (RaV) process and therefore has not been subject to an independent technical review.
My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.