[jboss-jira] [JBoss JIRA] (WFLY-3105) Container-managed EXTENDED persistence context is always joined with transaction even if UNSYNCHRONIZED

Scott Marlow (JIRA) issues at jboss.org
Thu Mar 20 12:48:11 EDT 2014


    [ https://issues.jboss.org/browse/WFLY-3105?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12954688#comment-12954688 ] 

Scott Marlow commented on WFLY-3105:
------------------------------------

The https://github.com/wildfly/wildfly/pull/6065 change is to not join the extended persistence context to the transaction (via EntityManager.joinTransaction()) for UNSYNCHRONIZED.

The added unit test failed before the change and passed after.  
                
> Container-managed EXTENDED persistence context is always joined with transaction even if UNSYNCHRONIZED
> -------------------------------------------------------------------------------------------------------
>
>                 Key: WFLY-3105
>                 URL: https://issues.jboss.org/browse/WFLY-3105
>             Project: WildFly
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: JPA / Hibernate
>    Affects Versions: 8.0.0.Final
>            Reporter: Christian Bauer
>            Assignee: Scott Marlow
>             Fix For: 8.0.1.Final
>
>
> https://github.com/weld/wildfly/blob/master/testsuite/integration/basic/src/test/java/org/jboss/as/test/integration/jpa/transaction/UnsynchronizedSFSB.jav
> Change this test to {code}@PersistenceContext(type = EXTENDED, synchronization = UNSYNCHRONIZED){code} and it will break. 
> Looks like an extended PC is always joined to the transaction and flushed on commit, the unsynchronized mode is ignored. From what I can see this is not specified and indeed would make the whole new UNSYNCHRONIZED feature kind of pointless. It's primary use case is propagation of unflushed/unsynchronized extended PC from a SFSB to other beans while keeping transactions intact.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list