5 Replies Latest reply on Mar 12, 2008 2:44 PM by wvreeven

    JBoss Tools and Oracle XE

    wvreeven

      Hi all,


      Last week I tried to generated entities using JBoss Tools 2.0.0 GA from an Oracle XE database using the ojdbc14.jar driver lib that is shipped with the Oracle XE database. Unfortunately, Eclipse hangs a little while after starting the wizard. Following the same procedure using PostGreSQL 8.3 (with an 8.2 driver by the way) works like a charm.

      I guess this is a DTP problem. Can anyone tell me how to see if there's any errors generated by Eclipse or JBoss Tools when Eclipse starts hanging? I am fairly new to Eclipse so please forgive my ignorance.


      Thanks in advance,

      Wouter van Reeven

        • 1. Re: JBoss Tools and Oracle XE
          maxandersen

          Hangs a little ...and then it works or ?

          If it just hangs a little and then works it is most likely because we by default scans the whole database metadata and on oracle that is slow.

          Set default_schema and default_catalog in your hibernate properties and it should reduce the time spent.

          • 2. Re: JBoss Tools and Oracle XE
            wvreeven

            As far as I tried, it hangs indefinately. CPU and disk load drop to 0 for both Eclipse and Oracle. I waited several minutes but I got no response. I need to kill Eclipse and make sure no Java processes remain. If I then startup Eclipse again I can continue working but no classes have been created.

            I noticed that seam-gen works from the command line. For now that solves my problem, since I can generate the project, all entities, actions and pages and then open up the project in Eclipse (or NetBeans for that matter).

            I tried all of this with Java6, not Java5. Can that be the problem? I haven't tried using Java5 yet since I have a deadlne for a demo using JBoss Tools next Thursday so I am glad I found out that seam-gen works.

            As for your suggestion to set default_schema, I tried that but it makes no difference. I know it doesn't since I set it wrong at first. I used lower case instead of upper case, which Oracle requires. Seam-gen wouldn't generate anything at first since I made the same mistake. Only when I entered it in upper case seam-gen would generate everything as I expected.


            Thanks, Wouter

            • 3. Re: JBoss Tools and Oracle XE
              maxandersen

              Java6 causes all sorts of issues.

              if it works with seam-gen it *must* also work here...its the same freaking code.

              • 4. Re: JBoss Tools and Oracle XE
                wvreeven

                OK I will try with Java5 during the weekend. And I will check and double check the settings used by Eclipse against the settings used by the command line seam-gen. Thanks for the pointers.

                • 5. Re: JBoss Tools and Oracle XE
                  wvreeven

                  I think I ran into this bug

                  http://jira.jboss.org/jira/browse/JBIDE-359

                  In hibernate-console.properties the line

                  hibernate.default_schema=<schema name>

                  was missing. After creating a new Seam Web Project and adding the line to that file, Entity generation works ok. Even with Java 6.


                  Thanks, Wouter