1 Reply Latest reply on Aug 11, 2009 10:41 AM by Dave Stanley

    How to - JMS Binding Components with Oracle persistence

    Angel Angel Newbie

      Hi everyone,

       

      Does anybody know how to use an Oracle database with JMS binding components?

      I need to use Oracle for persistence. Does anybody have an example? Where can I find one?

       

      Thanks!

        • 1. Re: How to - JMS Binding Components with Oracle persistence
          Dave Stanley Novice

          Hi Angel,

          Do you want to 1) use Oracle under the covers for the broker/jms message persistence or 2) do you want to persist your business data to Oracle?

           

          Assuming 1) i.e. you want to use Oracle as the persistent store for the underlying jms broker then you configure the persistence layer for the broker using /conf/activemq.xml

           

          You would disable the default file based persistence adapter and enable the pooled jdbc persistence adapter. I've pasted a sample oracle datasource below, which you need to reference:

           

          <!-- Oracle DataSource Sample Setup -->
              <bean id="oracle-ds" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
                <property name="driverClassName" value="oracle.jdbc.driver.OracleDriver"></property>
                <property name="url" value="jdbc:oracle:thin:@localhost:1521:AMQDB"></property>
                <property name="username" value="scott"></property>
                <property name="password" value="tiger"></property>
                <property name="maxActive" value="200"></property>
                <property name="poolPreparedStatements" value="true"></property>
              </bean>
          

           

          Hope this helps

          /Dave