Yes I saw the change so I have the following database entry...

<jdo-conf>
        <database name="HPPROD1" engine="oracle">
        
            <driver class-name="oracle.jdbc.driver.OracleDriver" 
url="jdbc:oracle:thin:@HOST:1526:HPPROD1">
              <param name="user" value="****" />
              <param name="password" value="****" />
            </driver>
            <mapping href="WEB-INF/mapping.xml" />
            <transaction-demarcation mode="local" />
        
        </database>          
</jdo-conf>


I don't use a custom castor.properties, I assume it is just using the one from 
the jar?

But I still recieve this error.

Caused by: org.xml.sax.SAXException: unable to add 'transaction-demarcation' to
database> due to the following exception:
>>>--- Begin Exception ---<<<
java.lang.IllegalStateException: java.lang.ClassCastException
        at org.exolab.castor.jdo.conf.JdoConfDescriptor$2.setValue(JdoConfDescri
tor.java:122)



Eric


>>> [EMAIL PROTECTED] 05/14/05 2:45 AM >>>
Hi Eric,

with release 0.9.6 the syntax of the database configuration changed as 
you found out yourself. You should have a look at the release notes 
where you will find informations about that change.

The second problem is that some new properties have been introduced with 
0.9.6. If you are using a custom castor.properies file you need to add 
the new properties (e.g. TransactionManagerFactory) to your file.

Hope that helps.

Ralf

Eric Anderson schrieb:
> I can't seem to get <transaction-demarcation mode="local" /> to read in
> correctly. I am receiving this error when calling my first jdo
> instance.
> 
> I get this error about a 100 times.
> 
> org.exolab.castor.jdo.DatabaseNotFoundException: Nested error: unable
> to add 'tr
> nsaction-demarcation' to <database> due to the following exception:
> 
>>>>--- Begin Exception ---<<<
> 
> java.lang.IllegalStateException: java.lang.ClassCastException
>         at
> org.exolab.castor.jdo.conf.JdoConfDescriptor$2.setValue(JdoConfDescri
> tor.java:122)
>         at
> org.exolab.castor.xml.UnmarshalHandler.endElement(UnmarshalHandler.ja
> a:1016)
>         at
> org.exolab.castor.xml.UnmarshalHandler.endElement(UnmarshalHandler.ja
> 
> 
> 
> <jdo-conf>
>                            
> <database name="HPPROD1" engine="oracle">
>   
>     <data-source class-name="oracle.jdbc.driver.OracleDriver">
>     <param name="user" value="**" />
>     <param name="password" value="**" />
>     <param name="port-number" value="1526" />
>     <param name="server-name" value="***" />
>     <param name="database-name" value="HPPROD1" />
>       </data-source>
> 
>     <mapping href="WEB-INF/mapping.xml" />
>     <transaction-demarcation mode="local" />
> 
> </database>
>                             
> </jdo-conf>  
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>>>>[EMAIL PROTECTED] 05/13/05 11:33 AM >>>
> 
> Problem was not starting with 
> 
> <jdo-conf> as the dtd now states.

-- 

Syscon Ingenieurb�ro f�r
Me�- und Datentechnik GmbH
Ralf Joachim
Raiffeisenstra�e 11
D-72127 Kusterdingen
Germany

Tel.   +49 7071 3690 52
Mobil: +49 173 9630135
Fax    +49 7071 3690 98

Email: [EMAIL PROTECTED] 
Web:   www.syscon-world.de

Reply via email to