Hi,
I’m using Tamino 4.1.4.1 and like to access the Database through an TStreamObjectModel because I’d like to use the Stream for unmarshalling to an JaxB Object. But If I create the TXMLObjectAccessor with an TStreamObjectModel as parameter, I get an error executing an request. So I tried the same programm with the TSAXObjectModel. The same Error occured. Even If I tried the Example for SAX Access delivered with the Tamino bundle I got the same error. The Stacktrace of the Error is:
Going to insert Hello World
Nested Exception ( com.softwareag.tamino.db.API.response.TResponseBuildException, tag: JavaTaminoAPI_4_1_4_42_1_1, java: 1.4.2, os: Windows XP 5.1 ) stacktrace:
Nested Exception ( com.softwareag.tamino.db.API.response.TStreamInterpretException, tag: JavaTaminoAPI_4_1_4_42_1_1, java: 1.4.2, os: Windows XP 5.1 ) stacktrace:
Nested Exception ( com.softwareag.tamino.db.API.response.sax.helper.sodom.SODOMException, tag: JavaTaminoAPI_4_1_4_42_1_1, java: 1.4.2, os: Windows XP 5.1 ) stacktrace:
com.softwareag.tamino.db.API.response.sax.helper.sodom.SODOMException: Error in building: SAX2 driver class com.softwareag.tamino.db.API.response.sax.TXMLReaderDecorator not found: com/softwareag/tamino/db/API/response/sax/TXMLReaderDecorator
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.build(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.build(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.TSaxHelperInputStreamInterpreter.doInterpret(Unknown Source)
Access failed:Response could not be built
NestedException:Response could not be built for XML access.
NestedException:Interpreting the input stream for JDOM failed!
NestedException:Error in building: SAX2 driver class com.softwareag.tamino.db.API.response.sax.TXMLReaderDecorator not found: com/softwareag/tamino/db/API/response/sax/TXMLReaderDecorator
at com.softwareag.tamino.db.API.response.TInputStreamInterpreter.interpret(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.TSAXInputStreamInterpreter.doInterpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TInputStreamInterpreter.interpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TResponseBuilderImpl.doBuild(Unknown Source)
at com.softwareag.tamino.db.API.response.TResponseBuilderImpl.buildForXML(Unknown Source)
at com.softwareag.tamino.db.API.accessor.TXMLObjectAccessorImpl.insert(Unknown Source)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.performInsert(ProcessGreeting.java:82)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.show(ProcessGreeting.java:173)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.main(ProcessGreeting.java:196)
Caused by: java.lang.ClassNotFoundException: com/softwareag/tamino/db/API/response/sax/TXMLReaderDecorator
at org.xml.sax.helpers.XMLReaderFactory.createXMLReader(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.createParser(Unknown Source)
… 12 more
Caused by: java.lang.ClassNotFoundException: com/softwareag/tamino/db/API/response/sax/TXMLReaderDecorator
at org.xml.sax.helpers.XMLReaderFactory.createXMLReader(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.createParser(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.build(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.build(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.TSaxHelperInputStreamInterpreter.doInterpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TInputStreamInterpreter.interpret(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.TSAXInputStreamInterpreter.doInterpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TInputStreamInterpreter.interpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TResponseBuilderImpl.doBuild(Unknown Source)
at com.softwareag.tamino.db.API.response.TResponseBuilderImpl.buildForXML(Unknown Source)
at com.softwareag.tamino.db.API.accessor.TXMLObjectAccessorImpl.insert(Unknown Source)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.performInsert(ProcessGreeting.java:82)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.show(ProcessGreeting.java:173)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.main(ProcessGreeting.java:196)
Caused by: java.lang.ClassNotFoundException: com/softwareag/tamino/db/API/response/sax/TXMLReaderDecorator
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:141)
at org.xml.sax.helpers.XMLReaderFactory.createXMLReader(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.createParser(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.build(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.sodom.input.SAXBuilder.build(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.helper.TSaxHelperInputStreamInterpreter.doInterpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TInputStreamInterpreter.interpret(Unknown Source)
at com.softwareag.tamino.db.API.response.sax.TSAXInputStreamInterpreter.doInterpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TInputStreamInterpreter.interpret(Unknown Source)
at com.softwareag.tamino.db.API.response.TResponseBuilderImpl.doBuild(Unknown Source)
at com.softwareag.tamino.db.API.response.TResponseBuilderImpl.buildForXML(Unknown Source)
at com.softwareag.tamino.db.API.accessor.TXMLObjectAccessorImpl.insert(Unknown Source)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.performInsert(ProcessGreeting.java:82)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.show(ProcessGreeting.java:173)
at com.softwareag.tamino.db.API.examples.greeting.sax.ProcessGreeting.main(ProcessGreeting.java:196)
The Example with TDOMObjectModel is working fine. Could anybody please help me? What have I done wrong?
bye
Dirk Kaspar
Hello Dirk,
this looks rather strange! Initially I thought that perhaps the TaminoAPI4J.jar file was missing in your classpath, because of this:
Caused by: java.lang.ClassNotFoundException:
com/softwareag/tamino/db/api/response/sax/TXMLReaderDecorator
However, if I remove the TaminoAPI4J.jar from my environment then I get a completely different error!
Could you please post your full classpath?
Thanks,
Trevor.
Hi Trevor,
thanks for your Reply. The following is a list of all jar archives contained in my classpath in the mentioned order:
jdom.jar
log4j.jar
TaminoAPI4J.jar
TaminoJCA.jar
xercesImpl.jar
xmlParserAPIs.jar
JRE System Library
As you can see, the TaminoAPI4J is in the Classpath. Could there an Problem with the Database? Do I have to set an Classpath for the Tamino Databaseengine too or is all the Java stuff running on the client only?
Also I wonder why the example with the JDOMObjectModel is running, but the Example with SAX fails. Are both examples runable in your environment?
Thanks for your Help
Dirk Kaspar
Hi,
I found the problem! The problem is the XercesImpl endorsed with JDK1.4.2
If I use the JDK1.3 everything works fine.
ciao
Dirk Kaspar
Hi Dirk,
that was very good timing, as I was just about to test with the xercesImpl.jar and xmlParserAPIs.jar in my classpath!
When I tested last week I used JDK 1.4.2, but I did not put the xercesImpl or xmlParserAPIs Jar files in my classpath (because there are already enough parser classes in the JDK since 1.4).
The SAX example worked fine with that set up, though I did not try the JDOM example.
If you want to use a 1.4 JDK rather than 1.3, perhaps you should also try removing those two Jar files from your classpath and see if that helps.
Greetings,
Trevor.
Hi Trevor,
Thanks for your Help
Now everything works great. You are right! Using JDK1.4 you don’t have to have an XercesImpl in the Classpath. The alternative is using JDK1.3
Thx and Bye
Dirk Kaspar