Jeff Ross - 2012-05-21

I've been running schema spy for over a year and mid-April it suddenly began hanging.  When I run it from the console I get this on the screen:

Gathering schema details………………………Exception in thread "Thread-171" java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
        at java.util.ArrayList.rangeCheck(
        at java.util.ArrayList.get(
        at org.postgresql.core.v3.QueryExecutorImpl.processResults(
        at org.postgresql.core.v3.QueryExecutorImpl.execute(
        at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(
        at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(
        at org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(
        at org.postgresql.jdbc2.AbstractJdbc2ResultSetMetaData.fetchFieldMetaData(
        at org.postgresql.jdbc2.AbstractJdbc2ResultSetMetaData.isAutoIncrement(
        at net.sourceforge.schemaspy.model.Table.initColumnAutoUpdate(
        at net.sourceforge.schemaspy.model.Table.initColumns(
        at net.sourceforge.schemaspy.model.Table.<init>(
        at net.sourceforge.schemaspy.model.Database$TableCreator.createImpl(
        at net.sourceforge.schemaspy.model.Database$ThreadedTableCreator$

A ktrace also shows this immediately prior to the exception:

3358 java     GIO   fd 7 read 131 bytes
       "E\0\0\0\M^BSERROR\0C08P01\0Mbind message supplies 1 parameters, but prepared statement "" requires 0\0Fpostgres.c\0L1493\0Rexec_bind_message\0\0"

If I run the last query logged from psql it runs just fine.

SchemaSpy 5.0.0, OpenBSD -current.

I'm calling schemaspy with this:

/usr/local/jdk-1.7.0/bin/java \ \
  -jar /home/jross/schemaSpy_5.0.0.jar \
  -t pgsql \
  -db wykids  \
  -s public \
  -dp /usr/local/share/postgresql/java/postgresql.jar \
  -u _postgresql \
  -host dukkha.internal \
  -o /var/www/stars/system_documentation/schemaspy/ \
  -gv /usr/local/

and as I said earlier, this has been working for at least a year.

Any help would be greatly appreciated!

Jeff Ross