That seems to be a true statement.

Consider the following simple test case:

import org.jboss.varia.scheduler.Schedulable;
  | 
  | public class TestScheduler implements Schedulable {
  |     public TestScheduler() {
  |             super();
  |     }
  |  
  |     public void perform(java.util.Date date, long param) {
  |             try {
  |                     System.out.println("calling TestScheduler");
  |             }
  |             catch (Exception e) {
  |                     System.out.println("Exception " + 
e.getLocalizedMessage());
  |                     e.printStackTrace();
  |             }
  |     }
  | }
  | 
with the following in scheduler-services.xml:


  |   <mbean code="org.jboss.varia.scheduler.Scheduler" 
  |      name=":service=TestScheduler">
  |     <attribute name="StartAtStartup">true</attribute>
  |     <attribute name="SchedulableClass">TestScheduler</attribute>
  |     <attribute name="InitialStartDate">NOW</attribute>
  |     <attribute name="SchedulePeriod">1000</attribute>
  |     <attribute name="InitialRepetitions">1</attribute>
  |   </mbean>
  | 
Saving (deploying) the scheduler-services.xml file results in:

anonymous wrote : --- MBeans waiting for other MBeans ---
  | ObjectName: jboss:service=TestScheduler
  |   State: FAILED
  |   Reason: org.jboss.deployment.DeploymentException: Exception setting 
attribute [EMAIL PROTECTED] on mbean jboss:service=TestScheduler; - nested 
throwable: (java.security.InvalidParameterException: Given class TestScheduler 
is not  not found)
  | 
  | --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
  | ObjectName: jboss:service=TestScheduler
  |   State: FAILED
  |   Reason: org.jboss.deployment.DeploymentException: Exception setting 
attribute [EMAIL PROTECTED] on mbean jboss:service=TestScheduler; - nested 
throwable: (java.security.InvalidParameterException: Given class TestScheduler 
is not  not found)
  | 

which implies to me there's most likely a class loader issue, or that the 
Scheduler is deprecated.

So - I'm really confused. We have some fairly simple schedule operations where 
the Scheduler has worked well. Is the scheduler deprecated? Is this a bug? 
Should we be using Quartz or similar products? 





View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3884767#3884767

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3884767


-------------------------------------------------------
This SF.Net email is sponsored by the 'Do More With Dual!' webinar happening
July 14 at 8am PDT/11am EDT. We invite you to explore the latest in dual
core and dual graphics technology at this free one hour event hosted by HP,
AMD, and NVIDIA.  To register visit http://www.hp.com/go/dualwebinar
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to