-
1. Re: Scheduler in run-time
pawelj. Feb 19, 2002 2:29 PM (in response to daudus)Hi,
I have a similar dilemma. I implemented the following to try to start a certain schedule during runtime:
Scheduler newScheduler = new Scheduler(
"server=Scheduler",
"org.jboss.util.Scheduler$SchedulableExample",
"Run-time test,2002",
"java.lang.String,int",
0,
5000,
20);
try{
newScheduler.start();
} catch (Exception e){
e.printStackTrace();
}
and fiddled around with the first parameter by trying out "service=Scheduler" as well as preceding this with a ":" among a multitude of other combinations. I always get the following error:
JBoss Scheduler Service 'scheduler:server=Scheduler' bound to scheduler:server=Scheduler
java.lang.NullPointerException:
at org.jboss.util.Scheduler.startService(Scheduler.java:607)
at org.jboss.util.ServiceMBeanSupport.start(ServiceMBeanSupport.java:103)
From the above, I reckon that the MBean server is unknown, however JBoss 2.4.4 is running and the time service, as well as other services have been started. Should the jboss.jcml file start the scheduler service, regardless of whether I am trying to do this during run-time?
Any comments would be greatly appreciated.
Pawel -
2. Re: Scheduler in run-time
hchirino Feb 19, 2002 11:26 PM (in response to daudus)Your post is off topic, please move to anoother forum.
This forum is for JMS and JBossMQ topics.