Hi,

I want to overwrite the MetaDataFactory like described here: 
http://openjpa.apache.org/builds/1.0.2/apache-openjpa-1.0.2/docs/manual/ref_guide_meta.html

But it turned out it doesn't work. I managed to develop a test scenario 
which easily produces the behaviour I encountered.

What _does_ work is the following:

Adding 
<property name="openjpa.MetaDataFactory" value="jpa"/>
to persistence.xml.

When setting this property my junit test (persisting a simple association, 
using @Column Annotation to use differing column names) does work.


According to the document above, this property tag should be equivalent to 
the setting above:

<property name="openjpa.MetaDataFactory" 
value="org.apache.openjpa.persistence.PersistenceMetaDataFactory"/>

But when using this configuration my junit test fails. The differing 
Column Names set by the @Column.name Attribute are no longer found. 
Instead the Java Attribute-Names are used in the SQL.

My problem is, that I want to implement a custom MetaDataFactory and this 
doesn't work either (which is expected, because I extend 
PersistenceMetaDataFactory). Is there something I missed?

(I'm using openjpa 2.11)

Best regards Marcel


-- 
RSC Commercial Services GmbH & Co. OHG, Wanheimer Strasse 70, D-40468 
Duesseldorf - Sitz: Duesseldorf - Registergericht: Duesseldorf HRA 12655
Persoenlich haftende Gesellschafter:
C&A Retail GmbH - Sitz: Zug/Schweiz - Handelsregister Kanton Zug: 
CH-170.4.010.137-5
Geschaeftsfuehrer: Bart F. Brenninkmeijer, Martijn N. N. Brenninkmeijer, Tjeerd 
E. van der Zee, Robert H. A. M. Smeele, Anthony H. Stam,
FRM PARTICIPATIONS S.A. - Sitz: Luxemburg/Luxemburg - Handels- und 
Firmenregister Luxemburg: B 58158
Verwaltungsratsmitglieder: Rafael G. E. Bogaerts, John Drury, Michel de Groote, 
Johny Seré, Robert H. A. M. Smeele

Reply via email to