[jboss-user] [EJB 3.0] - Re: Accessing EntityManagerFactory/SessionFactory via JNDI s

fiorenzino do-not-reply at jboss.com
Fri Sep 19 16:19:00 EDT 2008

Hi Matt,
i would read all named Queries presents in my SessionFactory.
I do not know how to retrieve this information using a entity manager.
(....Someone know a trick for this??...)

When I read your message, I thought you can use your solution. Read in the ClassMetadata, the names of persistent classes, to search for entries named Queries

You wrote:
- I can get a list of all PUs from JNDI, as well as references to the SessionFactory or EntityManagerFactory objects.
- I can get a list of all entity classes in each PU by calling SessionFactory.getAllClassMetadata() on the SessionFactory for each persistence unit. 


Thanks in advance


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4177749#4177749

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4177749

More information about the jboss-user mailing list