Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Gemini » [JPA] Using exclude-unlisted-classes(Is this feature supported? How to use it?)
[JPA] Using exclude-unlisted-classes [message #890406] Fri, 22 June 2012 08:49 Go to next message
Thomas Gillet is currently offline Thomas GilletFriend
Messages: 14
Registered: May 2011
Junior Member
Hello,

I'm trying to use <exclude-unlisted-classes>false</exclude-unlisted-classes> so I don't have to explicitly list all my entities. But without any luck so far.

I didn't find any precise documentation about this feature, just bug #356509 which leaves the question open.

So does someone know if classpath scanning is supported at all? Or will be supported soon?
Is there something else to do than setting exclude-unlisted-classes to false?
And if it's working, is it with entities from fragment bundles too?

Any explanation or a place to look for it would be appreciated.

-- Thomas

[Updated on: Fri, 22 June 2012 13:12]

Report message to a moderator

Re: [JPA] Using exclude-unlisted-classes [message #890620 is a reply to message #890406] Fri, 22 June 2012 17:21 Go to previous messageGo to next message
Michael Keith is currently offline Michael KeithFriend
Messages: 243
Registered: July 2009
Senior Member
Hi Thomas,

Setting the exclude-unlisted-classes element to false should allow scanning to occur to detect entities and managed classes within the persistence unit bundle. Are you seeing any problems with it?

Unfortunately, support for fragments is not supported by Gemini JPA (see bug 335698), so if your problem is related to using fragments that is a different beast.

-Mike
Re: [JPA] Using exclude-unlisted-classes [message #891594 is a reply to message #890620] Mon, 25 June 2012 10:11 Go to previous messageGo to next message
Thomas Gillet is currently offline Thomas GilletFriend
Messages: 14
Registered: May 2011
Junior Member
Hi Mike,

I indeed wanted to use fragments (trying to modularize my PUs, as discussed in my other post "Dynamic persistence units").
But, even with a regular bundle I don't manage to use entities not explicitly listed in my persistence.xml.

I started with a test bundle with one entity (using annotations, no xml mapping). This bundle was working.
Then I removed the "class" tag from the persistence.xml, and set the value of the "exclude-unlisted-classes" tag to "false". And it's not working anymore.

Did I miss something there?

-- Thomas
Re: [JPA] Using exclude-unlisted-classes [message #891946 is a reply to message #891594] Tue, 26 June 2012 16:13 Go to previous messageGo to next message
Michael Keith is currently offline Michael KeithFriend
Messages: 243
Registered: July 2009
Senior Member
No, you haven't missed anything. That should work. Can you enter a bug against that and I will take a look at it? Thanks. When the feature was added no test accompanied it, so we are owed a test case. I might go ahead and put one of those in as well while I am at it.

-Mike
Re: [JPA] Using exclude-unlisted-classes [message #892486 is a reply to message #891946] Thu, 28 June 2012 12:27 Go to previous messageGo to next message
Thomas Gillet is currently offline Thomas GilletFriend
Messages: 14
Registered: May 2011
Junior Member
Done! Submitted bug #383784 with a test bundle.

Also, when creating this test bundle I found a very strange behavior: when the bundle includes the sources, deployment triggers an infinite start stop loop, until the bundle is uninstalled. It's happening only for PU bundles when Gemini JPA is started.

Do you know something about that or should I fill a bug for it as well?

-- Thomas
Re: [JPA] Using exclude-unlisted-classes [message #893546 is a reply to message #892486] Wed, 04 July 2012 14:03 Go to previous messageGo to next message
Michael Keith is currently offline Michael KeithFriend
Messages: 243
Registered: July 2009
Senior Member
No, I have never seen that happen. If you have a test bundle for which that occurs please do enter a bug and attach the test bundle. Thanks!

-Mike
Re: [JPA] Using exclude-unlisted-classes [message #893659 is a reply to message #893546] Thu, 05 July 2012 07:06 Go to previous messageGo to next message
Thomas Gillet is currently offline Thomas GilletFriend
Messages: 14
Registered: May 2011
Junior Member
Submitted bug #384323, but it was in fact not caused by sources. It's about the absence of the persistence.xml file (side-effect of adding a <resource> section in the POM).

-- Thomas
Re: [JPA] Using exclude-unlisted-classes [message #893757 is a reply to message #893659] Thu, 05 July 2012 13:15 Go to previous message
Michael Keith is currently offline Michael KeithFriend
Messages: 243
Registered: July 2009
Senior Member
Ah, ok. I'll take a look at it. Thanks.

-Mike
Previous Topic:How do I include gemini/virgo support in my own tomcat
Next Topic:Gemini Blueprint p2 update site available?
Goto Forum:
  


Current Time: Fri Mar 29 13:08:17 GMT 2024

Powered by FUDForum. Page generated in 0.02267 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top