Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] Verifying whether eclipselink-orm.xml is being picked up

You could add a named query to your el-orm.xml file and then try executing it. Really though, like any other mapping file or orm.xml, if you're missing critical metadata for any operation you'll know pretty quick. Also, turning the log level up to FINEST should give you some output to indicate what is being processed.

I'm not sure exactly why your el-orm.xml is not being picked up. If it is available at runtime from META-INF/eclipselink-orm.xml it should definitely be picked up.

Cheers,
Guy


On 14/06/2013 5:29 PM, Laird Nelson wrote:
I don't know how to verify whether META-INF/eclipselink-orm.xml is being processed.

An earlier message on this list indicated that META-INF/eclipselink-orm.xml resources should be processed automatically.  I am not seeing that.

I have a unit test with an entity class, and I've made alterations to the JPA information in META-INF/eclipselink-orm.xml.  I'm using Maven so I've placed this in my src/main/resources/META-INF directory, and I've verified that it is appearing in classes/META-INF/eclipselink-orm.xml.

Now, my test is reading from test-classes/META-INF/persistence.xml.

Note that the META-INF/persistence.xml resource is in one place and the META-INF/eclipselink-orm.xml is in another.  Both resources are on the classpath, however.

I have deliberately not referenced eclipselink-orm.xml in my persistence.xml.

I do not see the effects of my eclipselink-orm.xml changes in my test.

I see no output in the logs (FINEST level) that indicate EclipseLink has found it (grepping for "eclipselink" comes up empty).

When I copy it temporarily to test-classes/META-INF/eclipselink-orm.xml so that it is a file sibling of persistence.xml it IS picked up.

Is this expected behavior?

I'm using EclipseLink 2.3.2 (the version that ships with GlassFish 3.1.2.2).

Best,
Laird

--
http://about.me/lairdnelson


_______________________________________________
eclipselink-users mailing list
eclipselink-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-users

--

Oracle
Guy Pelletier

ORACLE Canada, 45 O'Connor Street Suite 400 Ottawa, Ontario Canada K1P 1A4

Green
            Oracle Oracle is committed to developing practices and products that help protect the environment


Back to the top