Kingsousse / myschedule

Automatically exported from code.google.com/p/myschedule
0 stars 0 forks source link

RMI Scheduler History #129

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Setup:

- Quartz deployed as RMI Server in one Tomcat
- myschedule-3.2.1 launched via ./myschedule-ui.sh

- both have the myschedule-quartz-extra-3.2.1.0 in their classpath
- both are configured to use their own H2 database

Behaviour:

- I can connect to the RMI Server and load and execute Jobs (e.g. 
myschedule.quartz.extra.job.OsCommandJob )
- clicking on Job Histories produces the following error in myschedule:

com.vaadin.event.ListenerMethod$MethodException: Invocation of method 
selectedTabChange in myschedule.web.ui.SchedulerScreen$SchedulerContent$1 
failed.
[...]
Caused by: org.quartz.SchedulerException: Error communicating with remote 
scheduler. [See nested exception: java.rmi.UnmarshalException: error 
unmarshalling return; nested exception is:
        java.io.WriteAbortedException: writing aborted; java.io.NotSerializableException: myschedule.quartz.extra.JdbcSchedulerHistoryPlugin]
        at myschedule.quartz.extra.SchedulerTemplate.getContext(SchedulerTemplate.java:140)
        at myschedule.web.ui.JobsHistoriesContent.reloadTableContent(JobsHistoriesContent.java:80)
        at myschedule.web.ui.JobsHistoriesContent.initJobsTable(JobsHistoriesContent.java:73)
        at myschedule.web.ui.JobsHistoriesContent.<init>(JobsHistoriesContent.java:31)
        at myschedule.web.ui.SchedulerScreen$SchedulerContent.switchJobsHistoriesContent(SchedulerScreen.java:155)
        at myschedule.web.ui.SchedulerScreen$SchedulerContent$1.selectedTabChange(SchedulerScreen.java:77)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:508)
        ... 17 more

I attached the quartz.properties of the RMI server and myschedule

Original issue reported on code.google.com by yddr...@gmail.com on 27 Mar 2014 at 3:08

Attachments:

GoogleCodeExporter commented 9 years ago
Hi,

I'm facing the exact same problem.
Did you find any workaround? 
Or do you know if someone is working on fixing this issue?

Many thanks in advance.

Original comment by dulguun....@gmail.com on 22 Jul 2014 at 1:57

GoogleCodeExporter commented 9 years ago
There is no update on this issue as far as I know I am afraid

Original comment by yddr...@gmail.com on 22 Jul 2014 at 2:52

GoogleCodeExporter commented 9 years ago
Hi again,
I found an other way to run the plugin in order to display the history on 
Myschedule.
To do that: you should create an instance of scheduler with in-memory-quartz 
configuration and add your datasource configuration and 
JdbcSchedulerHistoryPlugin.
You can also display the history in this scheduler (i know that it's not clean 
solution but works fine until update.)

Good luck :)

Original comment by dulguun....@gmail.com on 30 Jul 2014 at 9:34

GoogleCodeExporter commented 9 years ago
Hi, sorry haven't able to check on this project in a while. I will take a look 
in the next few days.

Original comment by saltnlight5 on 30 Jul 2014 at 2:19

GoogleCodeExporter commented 9 years ago
I am confused as what's the actual problem is for this issue. What are you 
trying to achieve here? Enable RMI Server and then a client to it? If that's 
the case, the two quartz.properties are not correct yet. (one is not setting 
proxy=true)

Also if you are doing RMI server and client, then there should be only one 
store. Why you have two?

The job history plugin should be configure and installed on the server only so 
it can record the job when it execute.

You can read more here: 
http://quartz-scheduler.org/documentation/quartz-2.x/configuration/ConfigRMI

Original comment by saltnlight5 on 31 Jul 2014 at 2:04

GoogleCodeExporter commented 9 years ago
Hi, 
in my setup there is 
- one Tomcat Server acting only as Quartz Server 
- and one Tomcat acting only as MySchedule Server

The setup/config itself seems to work just fine, meaning I can use the 
MySchedule GUI to control the Quartz instance (create Jobs /Triggers, start 
Jobs). 

But as soon as I try to access the job history via MySchedule GUI the exception 
mentioned in the initial post occurs.

Original comment by yddr...@gmail.com on 31 Jul 2014 at 11:57

GoogleCodeExporter commented 9 years ago
Hi yddrass,

The JdbcSchedulerHistoryPlugin is designed to record history data into DB where 
the server is running. So is JdbcSchedulerHistoryPlugin running in your quartz 
server?

Also my MySchedule GUI to view job history is designed to work only when 
JdbcSchedulerHistoryPlugin is in use. I have not test it to use as client UI to 
view data record only. Sounds like a interesting feature to have though.

Original comment by saltnlight5 on 1 Aug 2014 at 2:34