hi - i'm posting because i'm having major performance issues using the hibernate tools to reverse engineer a very modest oracle schema.
my basic configuration info:
JDK 1.5.0_06
Eclipse 3.1.1
JBoss-IDE 1.5.0RC2
Hibernate Tools 3.1.0 beta2
Oracle JDBC thin client 10.2.0.1.0
i'm trying to reverse engineer an oracle schema with 37 tables/~400 columns. the good news is that the reverse engineering process actually
does work, but the bad news is that it takes over 45 minutes to do the reverse engineering, which is performance that i find prohibitively slow.
at no point in the process do i encounter any meaningful errors/exceptions propagated up to the eclipse error log - all i see is one warning related to a missing primary key in one of my tables, but that is clearly my problem.
i have used the Hibernate Configuration File Wizard to create a config file, and i believe i have properly specified the relevant schema that i am interested in.
hibernate.cfg.xml:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<property name="hibernate.connection.driver_class">oracle.jdbc.driver.OracleDriver</property>
<property name="hibernate.connection.password">mypass</property>
<property name="hibernate.connection.url">jdbc:oracle:thin:@myserver.edu:1521:CHLDEV</property>
<property name="hibernate.connection.username">myusername</property>
<property name="hibernate.default_catalog">PMREG</property>
<property name="hibernate.default_schema">PMREG</property>
<property name="hibernate.dialect">org.hibernate.dialect.OracleDialect</property>
</session-factory>
</hibernate-configuration>
the user is the schema owner and has all appropriate permissions assigned to it.
i have also created a console configuration using the Hibernate Console Configuration Wizard wihout incident according to these slightly out-of-date instructions (
http://www.hibernate.org/hib_docs/tools/eclipse/index.html).
i have searched the forums and read posts (
http://forum.hibernate.org/viewtopic.php?t=953527) that have attributed slow oracle reverse engineering performance to calls to the oracle JDBC implementation of Connection.getMetaData(). in my case, i find that difficult to believe for two reasons:
1. i can use other JDBC-driven reverse engineering tools (DBVisualizer, CodeFutures FireStorm) with the same host, driver, and JVM without these performance issues.
2. i have tested out this call directly in a separate application and fetching the metadata for a single table takes about 0.2 seconds, which is roughly in line with performance in those other reverse-engineering applications.
i've seen this oracle reverse engineering performance issue mentioned before in the forums, but on the order of hundreds or thousands of tables, and never to this degree. i'm stumped, mostly because the reverse engineering actually does work, eventually, so i've clearly configured something correctly. if i had to guess, i would assume that the reverse engineering process is iterating over every table in every schema in the database despite my specifying the schema it should use in the hibernate.cfg.xml file - i'm not sure how i can go about logging the verbose output from the reverse engineering layer so i haven't been able to verify that hypothesis.
any input or suggestions would be most appreciated!