Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
    Bookmark Topic Watch Topic
  • New Topic

Quartz xml stuff

 
Sam Doder
Ranch Hand
Posts: 204
  • Mark post as helpful
  • send pies
  • Report post to moderator
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
Sheriff
Posts: 21107
32
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Report post to moderator
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
Posts: 204
  • Mark post as helpful
  • send pies
  • Report post to moderator
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
Sheriff
Posts: 21107
32
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Report post to moderator
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
Sheriff
Posts: 21107
32
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Report post to moderator
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.
 
    Bookmark Topic Watch Topic
  • New Topic