IllegalStateException

2002-01-28 Thread Magnus Hoem
Hi!
I have a strange problem which I can't find a solution to. I am running a system with a two message-driven beans and a couple of entity beans. They are all listening to (and able to publish messages to) the same Topic. One of the entity beans contains a Timer with a couple of TimerTasks that publish messages to the topic that tells to mdb:s to do different things. I also have a jsp that refreshes itself every couple of minutes. When the system has been up and running for a while I suddenly get a very strange error. When the self-refreshing jsp-page (or load any other jsp-page connected to the system) is loaded I get  "java.lang.IllegalStateException: Transaction expired (Committed)" and a reference to the line in the jsp where I try to connect to the Home interface and run the create(), findByPrimaryKey() or findAll() methods. Does anybody know why this happens and have a sollution?
I log all the messages sent to the topic, and the timer-bean keeps sending messages after the error occurs...

Thanks,
Magnus

------
Magnus Hoem
[EMAIL PROTECTED]

Phone: +46-8-343206
Cell: +46-733-343206

Re: Job Scheduler pattern

2002-01-25 Thread Magnus Hoem

I'm using a TImer and TimerTasks in my system, and it works perfectly 
well (even though one is not supposed to use threads in an EJB).

What kind of RemoteException are you getting?

Cheers,
Magnus

On fredag, januari 25, 2002, at 10:02 , Justin Crosbie wrote:

 Hi,

 I'm not sure if I've asked this before, or if I should be asking on a
 general EJB list.

 I'd like to implement a job scheduler in J2EE. This would shcedule the
 execution of EJB methods at a specified time in the future. It would 
 have to
 be persistent, and jobsd would be rescheduled upon appserver restart.

 Is it as simple as using the Timer and TimerTask in java.util to 
 implement
 an app that is started with the client-module tag?

 Does it matter as far as Orion goes whether I use a java.util.Timer as a
 daemon or not?

 What can I do if the app, or the Timer object dies at any stage?

 I've had problems where after some time something goes wrong I get a 
 strange
 Remote Exception, and the only solution is to restart the VM. What might
 cause this?

 Any opinions on this? How do I make this solution robust is what I am
 asking.

 Thanks for any help,
 Justin