Author: stliu
Date: 2011-10-16 10:23:41 -0400 (Sun, 16 Oct 2011)
New Revision: 20980
Added:
core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/transaction/JBossAS7TransactionManagerLookup.java
Log:
JBPAPP-7385 Hibernate 3 does not provide a LookupManager for EAP/AS7
Added:
core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/transaction/JBossAS7TransactionManagerLookup.java
===================================================================
---
core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/transaction/JBossAS7TransactionManagerLookup.java
(rev 0)
+++
core/branches/Branch_3_3_2_GA_CP/core/src/main/java/org/hibernate/transaction/JBossAS7TransactionManagerLookup.java 2011-10-16
14:23:41 UTC (rev 20980)
@@ -0,0 +1,42 @@
+/*
+ * Hibernate, Relational Persistence for Idiomatic Java
+ *
+ * Copyright (c) 2011, Red Hat Inc. or third-party contributors as
+ * indicated by the @author tags or express copyright attribution
+ * statements applied by the authors. All third-party contributions are
+ * distributed under license by Red Hat Inc..
+ *
+ * This copyrighted material is made available to anyone wishing to use, modify,
+ * copy, or redistribute it subject to the terms and conditions of the GNU
+ * Lesser General Public License, as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License
+ * for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this distribution; if not, write to:
+ * Free Software Foundation, Inc.
+ * 51 Franklin Street, Fifth Floor
+ * Boston, MA 02110-1301 USA
+ *
+ */
+package org.hibernate.transaction;
+
+/**
+ * A {@link TransactionManagerLookup} lookup strategy for JBoss AS 7.
+ *
+ * @author Strong Liu
+ */
+public final class JBossAS7TransactionManagerLookup extends JNDITransactionManagerLookup
{
+
+ protected String getName() {
+ return "java:jboss/TransactionManager";
+ }
+
+ public String getUserTransactionName() {
+ return "UserTransaction";
+ }
+
+}
Show replies by date