java - Illegal access (Quartz with JBoss) -
I am running a scheduled job in a web application which can sometimes (not be able to report) results in the following exception Is:
[WebappClassLoader] Invalid access: This web application example has already been stopped. Org.quartz could not be loaded. Eventually the following stack trace is due to an error thrown for debugging purposes, as well as attempts to end the thread, which has illegal access, and has no functional effect org.apache.catalina.loader.WebappClassLoader .loadClass (WebappClassLoader.java:1204) java.lang.IllegalStateException on org.apache.catalina.loader.WebappClassLoader.loadClass (WebappClassLoader.java:1244) on java.lang.ClassLoader. On loadClassInternal (ClassLoader.java:319) java.lang.Class.forName (Class.java:169) on org.quartz.JobDetail.class $ on java.lang.Class.forName0 (Native Method) (JobDetail.java: 279) org.quartz.JobDetail.isStateful (JobDetail.java:425) org.quartz.simpl.RAMJobStore.triggerFired (RAMJobStore.java:1313) on org.quartz.core.QuartzSchedulerThread.run (QuartzSchedulerThread.java:342 ) 13: 41: 00,083 eRROR [STDERR] exception in thread "default QuartzScheduler_QuartzSchedulerThread" 13: 41: 00,083 eRROR [Steediiarar] java.lang.NoClassDefFound error: org.quartz.StatefulJob 13: 41: 00,083 eRROR [Steediaarar] at org.quartz .JobDetail .class $ (JobDetail.java:279) 13: 41: 00,083 Error [STDERR] at org.quartz.JobDetail.isStatefulJava: 425) 13: 41: 00,083 ERROR [STDERR] org.quartz.simpl.RAMJobStore.triggerFired (RAMJobStore.java:1313) 13: 41: 00,083 ERROR [STDERR] on org.quartz.core.QuartzSchedulerThread.run (Kwartjhsekyulrtredkjawaajhr 2)
There is also a nokladefound error, it says that org.quartz.StatefulJob is not found here how the job is fixed:
Scheduler shade = Stadding adeudalularfactor.gate default subdirectory (); If (! Sched.isStarted ()) {sched.start (); } String konf = MyConfigClass.getRow (25) .get configuration (); Calendar cal = calendar.justinstance (); Cal.setTime (MyParser.stf.parse (KONF)); String expression = "0" + cal.get (calendar.mindue) + "cal.get (calendar.HOUR_OF_DAY) +"? * MON-FRI "Krontrigr CT = new Krontrigr (Trigrnam group, Jobnam, group, expression); if (SchedkgetTrigger (trigger, name, scheduler. DEFAULT_GROUP)! = NULL) {sched.rescheduleJob (trigger, name, Group, CT);} Other {JobDetail jd = New JobDebate (JobName, Group, MyJob.Class); Sched.scheduleJob (JD, CT);}
I do not know what the problem is First of all I thought that the session dies before the execution of the job, but I try to do it The interesting thing is that after this exception, the job is no longer a problem.
Do you have any ideas?
It seems that your quartz job is trying to do something after your app is closed, because of your app, There may be an attempt to reach, but no more (as it is).
If you are posting more information It is: Stacktrace, your job code etc.
After the update: this is what I think is happening:
- You are successfully scheduling your job
- For whatever reason your webpage is closed I will search for a reason JBoss logs
- This time it comes to implementing your work (
org.quartz.simpl.RAMJobStore.triggerFired (RAMJobStore.java:1313)
) - This call goes under the
isStateful
methodJobDetail
class -
This code is returned in the code (StatefulJob.class. IsAssignableFrom (job class);
- StatefulJob class was not loaded before your classloader (
org.apache.catalina.loader.WebappClassLoader.loadClass (WebappClassLoader.java:1204)
) - Since your webapp has been stopped, then you are trying to load exceptions
the way I see it, your There are two options:
- Do not pay attention to this problem, because after your webpage, quartz has nothing to work on
- find out try the How to prevent your webpage and fix it
Comments
Post a Comment