Bug 1613424 - [GSS](6.4.z) JBJCA-1371 - Deadlock for threads executing org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.isEqual
Summary: [GSS](6.4.z) JBJCA-1371 - Deadlock for threads executing org.jboss.jca.adapte...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: JCA
Version: 6.4.20
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: CR1
: EAP 6.4.21
Assignee: Jiri Ondrusek
QA Contact: Peter Mackay
URL:
Whiteboard:
Depends On:
Blocks: 1614027 eap6421-payload 1611770
TreeView+ depends on / blocked
 
Reported: 2018-08-07 14:08 UTC by Brad Maxwell
Modified: 2021-09-09 15:18 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1614027 (view as bug list)
Environment:
Last Closed: 2019-08-19 12:42:13 UTC
Type: Bug


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker JBEAP-14519 0 Major Closed [GSS](7.1.z) - WFLY-10181 Deadlock for threads executing org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.isEqu... 2019-10-31 22:21:23 UTC
Red Hat Issue Tracker JBEAP-14616 0 Major Closed [GSS](7.1.z) JBJCA-1371 - Deadlock for threads executing org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.isEqu... 2019-10-31 22:21:23 UTC
Red Hat Knowledge Base (Solution) 3393911 0 None None None 2018-08-07 16:35:30 UTC

Description Brad Maxwell 2018-08-07 14:08:54 UTC
Two or more threads hold one lock on an instance of java.util.Collections$SynchronizedMap and attempt to obtain a lock on a different instance (e.g. locks on 0x00000001d0d08bd8 and 0x00000001cea22628 in the example below)

"thread-one" ...
java.lang.Thread.State: BLOCKED (on object monitor)
at java.util.Collections$SynchronizedMap.get(Collections.java:2584)

    waiting to lock <0x00000001cea22628> (a java.util.Collections$SynchronizedMap)
    at java.util.AbstractMap.equals(AbstractMap.java:495)
    at java.util.Collections$SynchronizedMap.equals(Collections.java:2631)
    locked <0x00000001d0d08bd8> (a java.util.Collections$SynchronizedMap)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.isEqual(XAManagedConnectionFactory.java:563)
    locked <0x00000001d0d08bd8> (a java.util.Collections$SynchronizedMap)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.equals(XAManagedConnectionFactory.java:598)
    at org.jboss.jca.adapters.jdbc.BaseWrapperManagedConnectionFactory$SubjectActions.doCheck(BaseWrapperManagedConnectionFactory.java:1397)
    at org.jboss.jca.adapters.jdbc.BaseWrapperManagedConnectionFactory$SubjectActions.addMatchingProperties(BaseWrapperManagedConnectionFactory.java:1508)
    at org.jboss.jca.adapters.jdbc.BaseWrapperManagedConnectionFactory.getConnectionProperties(BaseWrapperManagedConnectionFactory.java:1135)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.matchManagedConnections(XAManagedConnectionFactory.java:533)
    ...
    at org.jboss.jca.adapters.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:138)
    at org.jboss.as.connector.subsystems.datasources.WildFlyDataSource.getConnection(WildFlyDataSource.java:66)
    ...

"thread-two" ...
java.lang.Thread.State: BLOCKED (on object monitor)
at java.util.Collections$SynchronizedMap.size(Collections.java:2572)

    waiting to lock <0x00000001d0d08bd8> (a java.util.Collections$SynchronizedMap)
    at java.util.AbstractMap.equals(AbstractMap.java:482)
    at java.util.Collections$SynchronizedMap.equals(Collections.java:2631)
    locked <0x00000001cea22628> (a java.util.Collections$SynchronizedMap)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.isEqual(XAManagedConnectionFactory.java:563)
    locked <0x00000001cea22628> (a java.util.Collections$SynchronizedMap)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnectionFactory.equals(XAManagedConnectionFactory.java:598)
    ... [same stack as thread-one above] ...
    at org.jboss.jca.adapters.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:138)
    at org.jboss.as.connector.subsystems.datasources.WildFlyDataSource.getConnection(WildFlyDataSource.java:66)
    ...


Note You need to log in before you can comment on or make changes to this bug.