1   /*
2    * $Id: JmsClientAcknowledgeTransactionFunctionalTestCase.java 7976 2007-08-21 14:26:13Z dirk.olmes $
3    * --------------------------------------------------------------------------------------
4    * Copyright (c) MuleSource, Inc.  All rights reserved.  http://www.mulesource.com
5    *
6    * The software in this package is published under the terms of the CPAL v1.0
7    * license, a copy of which has been included with this distribution in the
8    * LICENSE.txt file.
9    */
10  
11  package org.mule.test.integration.providers.jms.activemq;
12  
13  import org.mule.providers.jms.JmsClientAcknowledgeTransactionFactory;
14  import org.mule.providers.jms.JmsConnector;
15  import org.mule.providers.jms.activemq.ActiveMqJmsConnector;
16  import org.mule.umo.UMOTransactionFactory;
17  
18  import javax.jms.Session;
19  
20  public class JmsClientAcknowledgeTransactionFunctionalTestCase extends
21      ActiveMQJmsTransactionFunctionalTestCase
22  {
23      public UMOTransactionFactory getTransactionFactory()
24      {
25          return new JmsClientAcknowledgeTransactionFactory();
26      }
27  
28      public JmsConnector createConnector() throws Exception
29      {
30          ActiveMqJmsConnector connector = new ActiveMqJmsConnector();
31          connector.setName(CONNECTOR_NAME);
32          connector.setAcknowledgementMode(Session.CLIENT_ACKNOWLEDGE);
33          connector.getDispatcherThreadingProfile().setDoThreading(false);
34          return connector;
35      }
36  
37      protected int getAcknowledgementMode()
38      {
39          return Session.CLIENT_ACKNOWLEDGE;
40      }
41  
42      public void testSendTransactedRollback() throws Exception
43      {
44          // Rollback not allowed for client acknowledge
45      }
46  
47      public void testTransactedRedeliveryToDLDestination() throws Exception
48      {
49          // messages are not marked for redelivery in Client Ack mode
50      }
51  
52  }