0 Replies Latest reply on May 17, 2005 3:09 PM by Doron Rippel

    Scheduler/Timer problem

    Doron Rippel Newbie

      Hi,

      I am trying to activate the Scheduler on JBoss 4.
      I run:

      mbeanServer.invoke(objName, "restartSchedule", arguments, signature);
      

      where objName is an instance of class ObjectName, which I previously created with the proper service name.

      The problem is that the run fails where class Scheduler tries to run the startSchedule() method, where it tries to call:
      mActualSchedule = ((Integer) getServer().invoke( 
       mTimer,
       "addNotification",
       new Object[]{
       "Schedule",
       "Scheduler Notification",
       null, // User Object
       lStartDate,
       new Long(mActualSchedulePeriod),
       mRemainingRepetitions < 0 ?
       new Long(0) :
       new Long(mRemainingRepetitions)
       },
       new String[]{
       String.class.getName(),
       String.class.getName(),
       Object.class.getName(),
       Date.class.getName(),
       Long.TYPE.getName(),
       Long.TYPE.getName()
       }
       )).intValue();


      at line 349, and it fails because mTimer is null.

      I saw that the only place where the mTimer is set to an object is in the startService() method of Scheduler, but this is never called.

      What do I miss?

      Thanks

      Doron