2 Replies Latest reply on Mar 31, 2003 3:21 AM by markuspr

    JBoss doesn't notice DB updates

    markuspr

      Hi,

      I've got the following problem: I want to cluster my CMP beans. That's why I have to use database clustering, because JBoss doesn't cluster the CMP on DB level. I use MySQL and JBoss on every node.
      Updates on the master-node of my DB work fine: JBoss updates or creates the beans right. Now every DB entry is replicated to my other nodes. But JBoss seems to cache the data somewhere.
      Example: I modify a bean on my master-node. The values on DB level are changed on every node. Now I read out this bean on one of the other nodes (I have to do this very quickly, within 20 sec.). The values are the old ones!

      Can someone tell how to prevent this?

      Thanks for your help,
      Markus

        • 1. Re: JBoss doesn't notice DB updates
          hunterhillegas

          First off, are you sure you know what's up with the clustering? I haven't used it in JBoss but it sounds like you should be able to do what you want from inside the app-server, not at the DB level.

          Anyway, you need to look at your commit option. Basically you need to set it to the one that checks the DB at each EJB call, since you have what amounts to an external process changing your data.

          This is gonna kill performance though, since JBoss won't be able to do much in the way of caching your CMP beans.

          Honestly, if you can I would try to put the clustering at the JBoss level, not at the DB... I would suggest buying the clustering docs and seeing if you really can't cluster CMP beans... The messages I have seen on the dev list suggest that you *can* do that.

          • 2. Re: JBoss doesn't notice DB updates
            markuspr

            I've got the whole docs here. It is not possible to cluster at JBoss level at the moment.
            So I'll try to change the commit option. Perhaps it will work....

            Greetings,
            Markus