7 Replies Latest reply on Nov 25, 2008 8:51 PM by hudson.2010

    How to configure Jbpm in non-distributed tomcat cluster?

    hudson.2010

      Our project is on non-distributed tomcat cluster (There're several tomcat web server clustered by F5 Networks). We want to use Jbpm in the environment which is not a standard J2EE cluster. How can I configure Jbpm?
      Millions of thanks for your reply.

        • 1. Re: How to configure Jbpm in non-distributed tomcat cluster?
          salaboy21

          I think that you must use the JbpmContext to handle your transaction and take a look if you are using Hibernate Second Level cache.. But if you not.. I think the basic configuration works fine to you..

          Hope it helps

          • 2. Re: How to configure Jbpm in non-distributed tomcat cluster?
            salaboy21

            Also you have this document to take a look:

            http://www.jboss.org/community/docs/DOC-11161

            • 3. Re: How to configure Jbpm in non-distributed tomcat cluster?
              hudson.2010

              Salaboy, thank you for your reply. I'm a beginner of Jbpm. I'm sorry that I'm still not clear about:
              1. How to "use the JbpmContext to handle your transaction"? Can you give an example?
              2. Why the basic configuration works for me if no Hibernate second level cache? I have maybe 3 Jbpm engines run on 3 different machine, don't I need any special cluster configuration? How Jbpm engines synchronize (for example, the status of JbpmContext) with each other?

              Looking forward your further help!

              • 4. Re: How to configure Jbpm in non-distributed tomcat cluster?
                kukeltje

                 

                1. How to "use the JbpmContext to handle your transaction"? Can you give an example?

                Just basic jBPM usage. Closing the JbpmContext will commit the transaction in the default jBPM configuration. Only if you have configured another transaction manager in the hibernate config, this transactionmanager will do it.

                This all is in the docs btw.

                2. Why the basic configuration works for me if no Hibernate second level cache?


                Because there is no caching then on that level in a tomcat 'node' and the DB is what they share

                I have maybe 3 Jbpm engines run on 3 different machine, don't I need any special cluster configuration?

                No, because they share a database

                How Jbpm engines synchronize (for example, the status of JbpmContext) with each other?

                They do not 'synchronize', they share a database

                And it might even be that a second-level cache is not a realy problem if just configured to only cache the processdefinitions... Not sure how to do that though

                • 5. Re: How to configure Jbpm in non-distributed tomcat cluster?
                  hudson.2010

                  kukeltje, thank you very much for your reply.
                  As per your answer, can I understand that: jBPM haven't any session level talk. Then I have 2 questions (please excuse me that I'm a very beginer of jBPM):
                  1. How can jBPM adapt into J2EE cluster environment?
                  2. jBPM may lock 1 DB record for a very long time or have some tricky mechanism?

                  • 6. Re: How to configure Jbpm in non-distributed tomcat cluster?
                    kukeltje

                    1: by using it in a server that provides functionality for this. e.g. if JBoss AS supports hibernate caching across a cluster jBPM will use that if you configure it to use e.g. the datasource of your appserver. You should also use ejb timers then instead of the jBPM timer solution (although both have some issues)
                    2: If a process is in a certain state and nothing is happening, nothing is locked. If you have long running actions, make them async. That way nothing is locked either

                    • 7. Re: How to configure Jbpm in non-distributed tomcat cluster?
                      hudson.2010

                      Thank you very much for your kindly help and explanation!