Re: DB2 OpenJMS: Peristence exception

Tim Anderson <[email protected]> Tue, 10 Apr 2007 09:06:15 +1000
Newsgroups gmane.comp.java.openjms.user
Message-ID <[email protected]>
Hemant Gaur wrote:
>
> I am using ActiveMQ-JMETER for the OpenJMS/DB2 performance. I have 
> done the test with many other databases but for the DB2 (latest 
> version 9), i can see lot of persistence exceptions reported at the 
> start time. The message throughput is high and comparable with other 
> DB's but unlike them this exception apprears in the logs (rite at the 
> start).
>
> Dont have the setup ready now but error is some thing like
> org.exolab.jms.server.ServerException: 
> org.exolab.jms.persistence.PersistenceException: 
> com.ibm.db2.jcc.c.SqlException: DB2 SQL error: SQLCODE: -301(?), 
> SQLSTATE: ?, SQLERRMC: DB2USER.SYSTEM_DATA
> AND
> org.exolab.jms.server.ServerException: 
> org.exolab.jms.persistence.PersistenceException: 
> com.ibm.db2.jcc.c.SqlException: DB2 SQL error: SQLCODE: -204, 
> SQLSTATE: 42704, SQLERRMC: DB2USER.SYSTEM_DATA
>
> The first SQL error I looked into DB2 meant that the table column data 
> type is not consistent with the value being inserted. (though many 
> messages are pub/sub). I have created the data base using the DB tool.
> What is the side effect of these persistence errors? Are the messages 
> lost ?
> Anything we need to do specially fro DB2?
>
> Thanks,
> Hemant
>
It should be a fatal error.
OpenJMS is trying to insert version information into the system_data table.
This should have a definition similar to:
CREATE TABLE SYSTEM_DATA (
  ID                           BIGINT NOT NULL,
  VERSION              VARCHAR(20) NOT NULL,
  CREATIONDATE DATE NOT NULL);

Try creating the schema with the contributed script for DB2
from $OPENJMS_HOME/db/sql/create_db2.sql

-Tim


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV