1 Reply Latest reply on Sep 2, 2008 9:58 AM by Wolf-Dieter Fink

    Can 2 unclustered JBoss instances share the same DB tables f

    Matthew Kennedy Newbie

      We have a configuration consisting of 2 JBoss instances (unclustered) and one database. Each instance runs the same application. The application includes an MDB. Is it possible for each JBoss instance to use the same DB tables for messaging queues? Would there be a risk that messages would be processed twice as they're take from the queue?

        • 1. Re: Can 2 unclustered JBoss instances share the same DB tabl
          Wolf-Dieter Fink Master

          we do this, but without JMS..
          just for CMP and EJB-Timers.
          For CMP it is not a risk if you aren't use CMP-caching.
          The timer tables must different (if you use timer), this can be configured in version 4.2. Otherwise ejbtimer services are started twice.

          JMS depends on what you using:
          JBossMQ -> deployed as HASingleton in a cluster
          not able to run in cluster or separated nodes like yours
          EXECPT: you ensure that the provider/consumer use a message-property to ensure it.
          I think that works but it is a dirty hack IMHO

          JBossMessaging -> is cluster ready.
          All nodes are useing the same DB (in a cluster) but each node needs it's unique id to handle the queue.
          I don't play around with it, so I'm not sure how it works. But my dirty hack should work as well.