org.springframework.jms.connection

Class JmsTransactionManager

    • Constructor Detail

      • JmsTransactionManager

        public JmsTransactionManager()
        Create a new JmsTransactionManager for bean-style usage.

        Note: The ConnectionFactory has to be set before using the instance. This constructor can be used to prepare a JmsTemplate via a BeanFactory, typically setting the ConnectionFactory via setConnectionFactory.

        Turns off transaction synchronization by default, as this manager might be used alongside a datastore-based Spring transaction manager like DataSourceTransactionManager, which has stronger needs for synchronization. Only one manager is allowed to drive synchronization at any point of time.

        See Also:
        setConnectionFactory(javax.jms.ConnectionFactory), AbstractPlatformTransactionManager.setTransactionSynchronization(int)
      • JmsTransactionManager

        public JmsTransactionManager(ConnectionFactory connectionFactory)
        Create a new JmsTransactionManager, given a ConnectionFactory.
        Parameters:
        connectionFactory - the ConnectionFactory to obtain connections from