Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 646E9200C88 for ; Fri, 2 Jun 2017 13:15:13 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 63780160BD2; Fri, 2 Jun 2017 11:15:13 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id A6BB5160BD1 for ; Fri, 2 Jun 2017 13:15:12 +0200 (CEST) Received: (qmail 21934 invoked by uid 500); 2 Jun 2017 11:15:11 -0000 Mailing-List: contact commits-help@tomee.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@tomee.apache.org Delivered-To: mailing list commits@tomee.apache.org Received: (qmail 21925 invoked by uid 500); 2 Jun 2017 11:15:11 -0000 Delivered-To: apmail-openejb-commits@openejb.apache.org Received: (qmail 21922 invoked by uid 99); 2 Jun 2017 11:15:11 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd2-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Jun 2017 11:15:11 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd2-us-west.apache.org (ASF Mail Server at spamd2-us-west.apache.org) with ESMTP id 2B09B1A02FF for ; Fri, 2 Jun 2017 11:15:10 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd2-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd2-us-west.apache.org [10.40.0.9]) (amavisd-new, port 10024) with ESMTP id DkhmG4Hc4Ayc for ; Fri, 2 Jun 2017 11:15:09 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 2AE765FB80 for ; Fri, 2 Jun 2017 11:15:08 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id A35D7E09F4 for ; Fri, 2 Jun 2017 11:15:06 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 2F1B821B57 for ; Fri, 2 Jun 2017 11:15:05 +0000 (UTC) Date: Fri, 2 Jun 2017 11:15:05 +0000 (UTC) From: "Svetlin Zarev (JIRA)" To: commits@openejb.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (TOMEE-2050) JTA 1.2 compliance: Calling UserTransaction methods from @Transactional bean MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 02 Jun 2017 11:15:13 -0000 [ https://issues.apache.org/jira/browse/TOMEE-2050?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16034515#comment-16034515 ] Svetlin Zarev commented on TOMEE-2050: -------------------------------------- No, I do not: {code} @WebServlet("/userTransaction") public final class CdiTransactionaltest extends HttpServlet { @Inject TransactionalBean transactionalBean; @Override protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException { final PrintWriter out = resp.getWriter(); resp.setContentType("text/plain"); try { out.println("Testing with UserTransaction inside transactional bean..."); transactionalBean.testWithTxRequiredAndUserTransaction(); } catch (Exception ex) { out.println("Exception: " + ex); ex.printStackTrace(out); } } } {code} The main transaction is initiated by the transactional intervceptor > JTA 1.2 compliance: Calling UserTransaction methods from @Transactional bean > ---------------------------------------------------------------------------- > > Key: TOMEE-2050 > URL: https://issues.apache.org/jira/browse/TOMEE-2050 > Project: TomEE > Issue Type: Bug > Reporter: Svetlin Zarev > Attachments: ROOT.war, sample.zip, sample.zip > > > JTA 1.2, section 3.7: > {code} > If an attempt is made to call any method of the UserTransaction interface from within the scope of a bean or method annotated with @Transactional and a Transactional.TxType other than NOT_SUPPORTED or NEVER, an IllegalStateException must be thrown. > {code} > Instead TomEE throws: > {code} > 13:38:03.710 [http-nio-8080-exec-7] ERROR java.lang.Throwable - javax.transaction.NotSupportedException: Nested Transactions are not supported > 13:38:03.713 [http-nio-8080-exec-7] ERROR java.lang.Throwable - at org.apache.geronimo.transaction.manager.TransactionManagerImpl.begin(TransactionManagerImpl.java:157) > 13:38:03.716 [http-nio-8080-exec-7] ERROR java.lang.Throwable - at org.apache.geronimo.transaction.manager.TransactionManagerImpl.begin(TransactionManagerImpl.java:152) > ... > ... > ... > 13:38:03.737 [http-nio-8080-exec-7] ERROR java.lang.Throwable - at org.apache.webbeans.intercept.AbstractInvocationContext.directProceed(AbstractInvocationContext.java:113) > 13:38:03.758 [http-nio-8080-exec-7] ERROR java.lang.Throwable - at org.apache.webbeans.intercept.AbstractInvocationContext.proceed(AbstractInvocationContext.java:106) > 13:38:03.761 [http-nio-8080-exec-7] ERROR java.lang.Throwable - at org.apache.webbeans.intercept.InterceptorInvocationContext.proceed(InterceptorInvocationContext.java:67) > 13:38:03.766 [http-nio-8080-exec-7] ERROR java.lang.Throwable - at org.apache.openejb.cdi.transactional.InterceptorBase.intercept(InterceptorBase.java:67) > 13:38:03.770 [http-nio-8080-exec-7] ERROR java.lang.Throwable - at org.apache.openejb.cdi.transactional.RequiredInterceptor.intercept(RequiredInterceptor.java:35) > {code} -- This message was sent by Atlassian JIRA (v6.3.15#6346)