This content has been marked as final.
Show 4 replies
-
1. Re: persistence.xml properties modification programatically in JaavEE Seam environment
luxspes Sep 9, 2009 4:52 PM (in response to balazska)AFAIK no
-
2. Re: persistence.xml properties modification programatically in JaavEE Seam environment
asookazian Sep 11, 2009 5:56 PM (in response to balazska)This would most likely be part of the Java EE 5/6 API (if it was possible, which I don't think it is). Are you trying to dynamically switch the persitence provider for a particular persistence unit from Hibernate to TopLink, for example? Or perhaps, set some properties for testing and set other properties for production?
It would be interesting if that entire persistence.xml file was optional (like ejb-jar.xml in EJB3) and we could simply use annotations on types/methods instead.
Here: http://java.sun.com/javaee/5/docs/api/javax/persistence/PersistenceUnit.html
we have an annotation, but it does not have the provider element, for example.
-
3. Re: persistence.xml properties modification programatically in JaavEE Seam environment
balazska Sep 15, 2009 11:53 PM (in response to balazska)Hi!
I only want to modify properties like show_sql, ect... from java code
thx.