users@glassfish.java.net

Re: timerpool on cluster

From: <glassfish_at_javadesktop.org>
Date: Fri, 19 Sep 2008 07:12:19 PDT

It works!

But I discover a problem:
I try to explain.

My EAR refers to a jdbc resoruce (for mysql connection pool to DB1) called RES1.

So, First, In order to resolve the timer problem I think to make a new jdbc resource calling it TIMER_RES (this resource is connected with a new connection pool(mysql connection pool to TIMER_DB (a new database with only the timer table: ejb__timer__tbl)

When I ran the application I got different exception:

1) Unexpected exception in resource pooling java.lang.IllegalStateException: Local transaction already has 1 non-XA Resource: cannot add more resources.

2) poolmgr.err_enlisting_res_in_getconn

3) Failed to obtain/create connection from connection pool [ mysqlPool ]. Reason : java.lang.IllegalStateException: Local transaction already has 1 non-XA Resource: cannot add more resources.

4) Error allocating connection : [Error in allocating a connection. Cause: java.lang.IllegalStateException: Local transaction already has 1 non-XA Resource: cannot add more resources. ]

I try to change the pool datasource in xa-datsource but it doesn't work.

I solve by use only the first jdbc resoruce (RES1) by put inside the database DB1 the timer table.

This solution in my opinion is not clean, how can I make 2 different resources ones for applications and one for timer?!
[Message sent by forum member 'peppeme' (peppeme)]

http://forums.java.net/jive/thread.jspa?messageID=300390