9 Replies Latest reply on Nov 29, 2006 1:18 PM by jrojas_pb

    OutOfMemory error when running jbpm.db test suite

    jrojas_pb Newbie

      I am in the process of getting jBPM up and running with the hypersonic database and ran into an OutOfMemory exception while performing the build.xml junit tests.

      Setting VM arguments under the JRE tab in the eclipse run dialog was unsuccessful. These are the settings I tried.
      -Xms512M -Xmx512M
      and
      -Xms256M -Xmx1024M

      I am running
      eclipse 3.1.2
      jre1.5.0_09
      jbpm 3.1.2

      I know this is a pretty basic question, and I am really hoping someone here is kind enough to give me a little help.

      Thanks!

      John

      PS: Here is the last section of the console log...

       [junit] drop table JBPM_TASKCONTROLLER if exists
       [junit] drop table JBPM_TASKINSTANCE if exists
       [junit] drop table JBPM_TIMER if exists
       [junit] drop table JBPM_TOKEN if exists
       [junit] Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
       [junit] drop table JBPM_TOKENVARIABLEMAP if exists
       [junit] drop table JBPM_TRANSITION if exists
       [junit] drop table JBPM_VARIABLEACCESS if exists
       [junit] drop table JBPM_VARIABLEINSTANCE if exists
       [junit] 12:57:33,201 [main] INFO SchemaExport : schema export complete
       [junit] 12:57:33,201 [main] INFO DriverManagerConnectionProvider : cleaning up connection pool: jdbc:hsqldb:mem:.;sql.enforce_strict_size=true
       [junit] 12:57:33,201 [main] DEBUG JbpmContext : closing JbpmContext
       [junit] 12:57:33,892 [Finalizer] INFO DriverManagerConnectionProvider : cleaning up connection pool: jdbc:hsqldb:mem:.;sql.enforce_strict_size=true
       [junit] Tests run: 9, Failures: 0, Errors: 0, Time elapsed: 16.103 sec
       [junit] Tests FAILED
       [junit] Running org.jbpm.context.exe.HibernateCustomizationTest
       [junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0 sec
       [junit] Test org.jbpm.context.exe.HibernateCustomizationTest FAILED
      [junitreport] [Fatal Error] TEST-org.jbpm.scheduler.exe.TimerDbTest.xml:85:24: XML document structures must start and end within the same entity.
      [junitreport] The file D:\jbpm-starters-kit-3.1.2\jbpm-db\build\hsqldb\testresults\xml\TEST-org.jbpm.scheduler.exe.TimerDbTest.xml is not a valid XML document. It is possibly corrupted.
      [junitreport] Transform time: 4837ms
      BUILD SUCCESSFUL
      Total time: 2 minutes 29 seconds
      


        • 1. Re: OutOfMemory error when running jbpm.db test suite
          john feidaros Newbie

          Open the build.xml under jbpm-db with an editor.
          Find the target named "db.test".
          In both elements add the attribute: maxmemory="256M".
          Save and re-run the tests.
          I had exactly the same problem, this addition fixed the OutOfMemoryError but still the tests did not complete perfectly correct.

          John

          • 2. Re: OutOfMemory error when running jbpm.db test suite
            jrojas_pb Newbie

            John,

            Thank you so much for your reply. I really appreciate you taking the time to share this information with me....

            I have to wonder how many people who knew the answer read the post and never bothered to reply.

            All the best!

            John

            • 3. Re: OutOfMemory error when running jbpm.db test suite
              Ronald van Kuijk Master

              come one, don't be so pessimistic. 150 people read the post, lost of them probably had no clue, some probably would have suggested what you already tried (I would have) and then john came by...

              • 4. Re: OutOfMemory error when running jbpm.db test suite
                jrojas_pb Newbie

                Ronald,

                I suppose it does sound pessimistic. I have posted many times and this is the 1st time I get a reply.

                I don't think I am the first person to experience this either.

                Maybe there was something wrong with my questions. It would be really helpful if you shed some light on this.

                Thanks,

                john

                • 5. Re: OutOfMemory error when running jbpm.db test suite
                  Cutberto Ocampo Newbie

                  I think is kind of pessimistic, since you CAN'T really trust someone else is actually going to answer you every time you ask. I would like you to consider the following reasons why people don't answer:

                  - don't want to answer
                  - don't have time to answer at this moment
                  - they just come to learn and not to share their knowledge
                  - don't know the answer
                  - haven't had a problem like yours so they can't really answer
                  - they think you should RTFM/STFW
                  - you didn't provide enough information so they can answer
                  - etc.

                  If you take a look at the last 30 questions in the forum you could see that only 3 of them have not been answered and, unless they lack info, probably they would get an answer eventually. For a completely free (no fee) forum, the ratio is pretty good.

                  Just my two cents.

                  • 6. Re: OutOfMemory error when running jbpm.db test suite
                    Ronald van Kuijk Master

                    John,

                    I tried looking back at some of your posts.

                    The one about the taskinstances would fall into the category: parts of the code/process, create a unit tests that demonstrates the problem.

                    The one about the failure when ending a process falls in the categorie, to much info, not going to read al that.

                    The post for the schedulerthread is not clear to me. The schedulerthread is normally not supposed to stop when a process ends? It is separate and should run once for all processes together (as you can read in the docs. so this would be a 'need more info' as well.

                    Either way, these are the reasons I did not reply to them. (look at http://wiki.jboss.org/wiki/Wiki.jsp?page=BadPostBig) Maybe it's the same for other users.

                    Looking forward to your next question.

                    • 7. Re: OutOfMemory error when running jbpm.db test suite
                      jrojas_pb Newbie

                      Ronald,

                      Thanks so much for clarifying that for me. It really helps!

                      Just as an FYI... I resolved most, if not all of those issues by reading through the posts in the forum.

                      Thanks again,

                      John

                      • 8. Re: OutOfMemory error when running jbpm.db test suite
                        john feidaros Newbie

                        John,

                        I'm glad that my post helped you. Getting answers in a so specialized forum is really an issue.
                        Have you tried the tests with MySQL database configuration? If you have found any helpful links in the forum or anywhere else, pls post.

                        Thanx, John

                        • 9. Re: OutOfMemory error when running jbpm.db test suite
                          jrojas_pb Newbie

                          This is getting away from the original subject of this post... so it may be worth putting this conversation in a new post.

                          The application I deployed used the in-memory database. There was no need to use a full blown relational database. So this eventually became a non-issue.

                          There is a lot of useful information in this forum. During my reviews of many posts, I could identify general threads of needs and information through different posts. It would be really cool if the search function had a way of consolidating information based on the questions asked. So someone can come in asking a question and get the posts that would be most appropriate.

                          This is in contrast to a search that returns posts based on keyword matches.