my dog learned polymorphism*
The moose likes XML and Related Technologies and the fly likes Quartz xml stuff Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Reply locked New topic
Author

Quartz xml stuff

Sam Doder
Ranch Hand

Joined: Feb 06, 2008
Posts: 204
I am using the java package quartz with this package it allows you to
schedule jobs by using an xml file. The problem is when I do
processFileAndScheduleJobs(...job xml file... )

I get this

org.apache.commons.beanutils.ConversionException: HelloJob
at org.apache.commons.digester.Digester.createSAXException(Digester.java:2919)
at org.apache.commons.digester.Digester.createSAXException(Digester.java:2945)
at org.apache.commons.digester.Digester.endElement(Digester.java:1133)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.endElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at org.apache.commons.digester.Digester.parse(Digester.java:1647)
at org.quartz.xml.JobSchedulingDataProcessor.processFile(JobSchedulingDataProcessor.java:430)
at org.quartz.xml.JobSchedulingDataProcessor.processFileAndScheduleJobs(JobSchedulingDataProcessor.java:499)
at org.quartz.xml.JobSchedulingDataProcessor.processFileAndScheduleJobs(JobSchedulingDataProcessor.java:485)

I am using quartz version 1.5
I think it has to do with the <quartz ... > tag
I have

<?xml version="1.0" encoding="utf-8"?>
<quartz xmlns="http://www.opensymphony.com/quartz/JobSchedulingData" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.opensymphony.com/quartz/JobSchedulingData
http://www.opensymphony.com/quartz/xml/job_scheduling_data_1_5.xsd" version="1.5">


Any help would be great!
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

I think it has to do with the <quartz ... > tag
However since one of the methods in the stack trace is "endElement", it is quote possible that a tag that starts an element isn't the culprit. However that's all you posted so there isn't much that can be said about it. Would you like to post more details?
Sam Doder
Ranch Hand

Joined: Feb 06, 2008
Posts: 204
Here is the xml file




I don't know much about the dtd, xsd files.
But here they are


job_scheduling_data_1_5.dtd



job_scheduling_data_1_5.xsd



[Line endings inserted to reduce the extreme width of the post - PC]
[ June 20, 2008: Message edited by: Paul Clapham ]
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

The stack trace referred to "HelloJob". So it looks like this is the place where parsing stopped:

<job-class>HelloJob</job-class>

I googled for the name of the exception (org.apache.commons.beanutils.ConversionException) and the first link that came back was this article about Apache Digester and BeanUtils. Looks to me like there's something missing from your code, something that can create a HelloJob object. However I don't know much about Digester.
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

Ah, I see you have come to the same conclusion and repackaged your question into a new post. That's probably a better place for people to start from, so let's close this one.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Quartz xml stuff
 
Similar Threads
Exception using Quartz org.quartz.plugins.xml.JobInitializationPlugin
Parsing error processing resource path /WEB-INF/struts-config.xml
Tricky Mock Question
Expression Language Doubt
I need major help!