[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: JBoss 4.04GA and Hibernate Config error
I figured it out. It had to the with the java.lang.NoClassDefFoundError: org/apache/commons/collections/SequencedHashMap. This class is located in a jar in my war file. I copied this jar to jboss\server\default\lib and it seemed to take care of it. I still don't understand why since it is already in my war but oh well. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3956308#3956308 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3956308 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: IllegalAccessError initializing ehcache.CacheManager
I'm hitting the same problem. The line of code causing the problem is: manager = new CacheManager(); in EhCacheProvider... in the version of EHCache I've been using, CacheManager's constructors are private. In the EHCache lib found in Hibernate's 3.2 source tree (ehcache-1.2.jar), the constructors are public. So, assuming it doesn't break anything to move to that ehcache release, the fix is to move to that ehcache release. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3956004#3956004 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3956004 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: IllegalAccessError initializing ehcache.CacheManager
I didn't find any solution for this, unfortunately. I was able instead to clone an existing JBoss installation we had which was working, since I couldn't take the time to continue trying to debug this problem. I would still like to know what it was and how to fix it, though... View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955588#3955588 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955588 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: IllegalAccessError initializing ehcache.CacheManager
I am having the same problems. I am very interested in a solution. Does anyone know how to work around this? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955654#3955654 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955654 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to disable Hibernate's Auto session close?
1. Deploy your hibernate files as if they where running in jboss3.x (see wiki's) 2. you find the sources in jboss.org (fisheye or CVS). View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955227#3955227 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955227 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: using others DBMS in jboss
What kind of Exception? During deploy or when you use it? In which EJB do you use the DB-Connection? Session or Entity? Wolf View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955232#3955232 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955232 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: using others DBMS in jboss
Thank you fro your reply. i got exception in runtime when i try to use my ejb. but about ejb. i use BMP. i know that there is a jbosscmp-jdbc file for setting datasource in CMP but how about BMP. i try to add these setting in ejb-jar.xml but it was useless... :-( ... resource-ref res-ref-namejdbc/myjndi/res-ref-name res-typejavax.sql.DataSource/res-type res-authContainer/res-auth /resource-ref thakns View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955243#3955243 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955243 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: using others DBMS in jboss
When you use BMP you have to create your own connection like : | public class MyEntity implements EntityBean { | private Connection getConnection() { | Context ctx=new InitialContext(); | DataSource ds=(DataSource)ctx.lookup(java:/myEntityConnection); | return(ds.getConnection(); | } | | pubic void ejbStore() throws EJBException { | Connection con=null; | try { | con=getConnection(); | ... your Code | }finnaly{ | if(con!=null) { | con.close(); | } | } | } | This code should work, I test it a long time ago ;-) I use CMP 2.x, it's easier to implement and the performance is fortunately the same as BMP. Wolf View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955256#3955256 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955256 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: using others DBMS in jboss
Yes, its work, :-) Thank you so much. i have a error in my connection code. | DataSource ds=(DataSource)ctx.lookup(java:comp/env/jdbc/myjndi); | changed to | DataSource ds=(DataSource)ctx.lookup(java:/myjndi); | | Thank you again. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955265#3955265 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955265 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Data source lookup returns null for mysql
Check these: Isolation is set using flags in your configuration or jboss_web/app files. The benefit is that every application has its own class loding space and you can avoid lots of wierd problems. The down side is that isolation can affect jndi lookup in general, and lookup data source specifically. To read about isolation and class loding use the following: http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossClassLoadingUseCases http://wiki.jboss.org/wiki/Wiki.jsp?page=ClassLoadingConfiguration Please let me know if you can get both isolation and datasource lookup work at the same time. Thanks, TEFRON View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955272#3955272 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955272 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re:
I think i have found the problem: The jar file was deployed into the folder JBOSS_HOME\server\default\deploy\myfolder\ . It looks like that there is a bug with the 4.04 release which caused my problem. I just placed the jar file directly into the deploy folder: JBOSS_HOME\server\default\deploy\ and all problems were gone. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955283#3955283 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955283 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: IllegalAccessError initializing ehcache.CacheManager
I have similar problem on 4.0.4-GA (windows) View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955308#3955308 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955308 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re:
No it wasn't, just bullshit. This is the SQL-stacktrace: | 2006-07-04 16:33:14,610 ERROR [org.jboss.ejb.plugins.cmp.jdbc.JDBCCreateEntityCommand.VipaEntity] Error checking if entity exists | org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=chbbtpfs205/26, BranchQual=, localId=26]; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=chbbtpfs205/26, BranchQual=, localId=26]) | at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:94) | at org.jboss.ejb.plugins.cmp.jdbc.JDBCInsertPKCreateCommand.beforeInsert(JDBCInsertPKCreateCommand.java:84) | at org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand.execute(JDBCAbstractCreateCommand.java:150) | at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.createEntity(JDBCStoreManager.java:587) | at org.jboss.ejb.plugins.CMPPersistenceManager.createEntity(CMPPersistenceManager.java:237) | at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.createEntity(CachedConnectionInterceptor.java:225) | at org.jboss.ejb.EntityContainer.createLocalHome(EntityContainer.java:618) | at sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source) | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) | at java.lang.reflect.Method.invoke(Method.java:585) | at org.jboss.invocation.Invocation.performCall(Invocation.java:359) | at org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(EntityContainer.java:1130) | at org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:105) | at org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(EntitySynchronizationInterceptor.java:203) | at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invokeHome(CachedConnectionInterceptor.java:189) | at org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:105) | at org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityInstanceInterceptor.java:134) | at org.jboss.ejb.plugins.EntityLockInterceptor.invokeHome(EntityLockInterceptor.java:76) | at org.jboss.ejb.plugins.EntityCreationInterceptor.invokeHome(EntityCreationInterceptor.java:43) | at org.jboss.ejb.plugins.CallValidationInterceptor.invokeHome(CallValidationInterceptor.java:56) | at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:125) | at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350) | at org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:161) | at org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:145) | at org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:132) | at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invokeHome(ProxyFactoryFinderInterceptor.java:107) | at org.jboss.ejb.EntityContainer.internalInvokeHome(EntityContainer.java:514) | at org.jboss.ejb.Container.invoke(Container.java:975) | at org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invokeHome(BaseLocalProxyFactory.java:359) | at org.jboss.ejb.plugins.local.LocalHomeProxy.invoke(LocalHomeProxy.java:133) | at $Proxy61.create(Unknown Source) | at ch.eds.ipmonitor.server.CollectorSessionBean.startElement(CollectorSessionBean.java:235) | at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source) | at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(Unknown Source) | at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source) | at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) | at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) | at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) | at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) | at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) | at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) | at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) | at javax.xml.parsers.SAXParser.parse(Unknown Source) | at ch.eds.ipmonitor.server.CollectorSessionBean.saveMessage(CollectorSessionBean.java:190) | at sun.reflect.GeneratedMethodAccessor73.invoke(Unknown Source) | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) | at java.lang.reflect.Method.invoke(Method.java:585) | at org.jboss.invocation.Invocation.performCall(Invocation.java:359) | at
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: NamingException caught jdbc:mysql: not bound, what is wr
sorry, the .xml looks like: local-tx-datasource jndi-nameDefaultDS/jndi-name connection-urljdbc:mysql://localhost:3306/test/connection-url driver-classcom.mysql.jdbc.Driver/driver-class user-namejboss/user-name password /local-tx-datasource View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3954997#3954997 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3954997 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: NamingException caught jdbc:mysql: not bound, what is wr
seems like I can't type for security reasons.. but that is anyway what should be surrounding password View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3954999#3954999 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3954999 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to disable Hibernate's Auto session close?
Any ideas anybody? :( View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955079#3955079 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955079 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to disable Hibernate's Auto session close?
You can't, it is hard-coded in jboss-hibernate.jar. see : Hibernate.class, transferSettings() settings.setProperty(hibernate.transaction.auto_close_session, true); You can still use still the sar-approche for deploying you're hibernate files or roll you're own jboss-hibernate.jar View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955092#3955092 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955092 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to disable Hibernate's Auto session close?
Thank you for your reply. I have been looking for some infos about how to deploy a .sar, but I was unable to find it. Do you know where could I look for some ideas? Also, where can I dowload the jboss-hibernate.jar source code? Best regards Alejandro View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3955112#3955112 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3955112 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: IllegalAccessError initializing ehcache.CacheManager
Did you find a solution to this? I am having the same issue on a vanilla installation of the jBoss 4.0.4.GA and a vanilla build of jbpm 3.0.3. Let me know...thanks! Brad View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3954926#3954926 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3954926 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Hibernate and Lucene: Where is the index?
Debug. See if the listener is actually called on persist - or in your case probably why not? Rgds, Ales View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3954601#3954601 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3954601 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Hibernate and Lucene: Where is the index?
Could it be that the corresponding events arent fired, when persisting the entity from a simple client app outside the container? Further, i didnt find the events listed in the integrate lucene with hibernate docs in the docs of the entitymanager. compare these urls: http://docs.jboss.org/ejb3/app-server/HibernateEntityManager/reference/en/html_single/index.html#d0e488 http://docs.jboss.org/ejb3/app-server/HibernateAnnotations/reference/en/html_single/index.html#d0e2754 | package com.titan.clients; | | import com.titan.travelagent.TravelAgentRemote; | import com.titan.domain.Cabin; | | import javax.naming.InitialContext; | import javax.naming.Context; | import javax.naming.NamingException; | | import javax.rmi.PortableRemoteObject; | | public class Client | { | public static void main(String [] args) | { | try | { | Context jndiContext = getInitialContext(); | Object ref = jndiContext.lookup(TravelAgentBean/remote); | TravelAgentRemote dao = (TravelAgentRemote)ref; | | Cabin cabin_1 = new Cabin(); | cabin_1.setId(1); | cabin_1.setName(Master Suite); | cabin_1.setDeckLevel(1); | cabin_1.setShipId(1); | cabin_1.setBedCount(3); | | dao.createCabin(cabin_1); | | Cabin cabin_2 = dao.findCabin(1); | System.out.println(cabin_2.getName()); | System.out.println(cabin_2.getDeckLevel()); | System.out.println(cabin_2.getShipId()); | System.out.println(cabin_2.getBedCount()); | | } | catch (javax.naming.NamingException ne) | { | ne.printStackTrace(); | } | } | | public static Context getInitialContext() | throws javax.naming.NamingException | { | return new javax.naming.InitialContext(); | } | } | View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3954639#3954639 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3954639 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Data source lookup returns null for mysql
Do you have isolation on? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3954682#3954682 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3954682 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Data source lookup returns null for mysql
tefron wrote : Do you have isolation on? Sorry, I am not an expert user of JBoss. I don't know whether or not I have isolation enabled. How do I check and what effect would that have? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3954772#3954772 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3954772 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: NullPointerException at JDBCCMRFieldBridge.initializeFor
By the way, I'm using Jboss 4.0 on Windows 2000 Professional and MySQL 5.0. Thanks again. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3953707#3953707 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3953707 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Relationship and Foreing Key
No one know how to eliminate Foreing Key constraint with annotation? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3953343#3953343 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3953343 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: @OneToMany fails with FetchType.LAZY
I gues that your session was closed or you are using a different session to access the lazy property than the was that the entity belongs to. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3953525#3953525 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3953525 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: DerbyDatabase mbean in 4.0.3 missing?
I get the same error. ITS SO FINE TO SEE EVERYONE POSTING THE FIX WHEN THEY FINALLY FIND WHY THEIR ERROR OCCURED NOT ! please remember to post how you fixed it ! View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3953187#3953187 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3953187 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: identifier of an instance of ... was altered from 1 to 0
I do not exactly know what the problem is. I have changed the bean name to Vistit and the table to visit, this does work. When MySQL generates an error You get such a kind of error because the transcation is roll backed. Perhaps MySQL does not return an exact error message like in error cases. Or Hibernate suppress the MySQL error. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952967#3952967 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952967 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: M:N CMP Relationship with unknown Primay Key fails with
Has anyone got this same error, or has the author solved this problem already (I can't contact donjons via pm/email)? This because I get the very same error Both roles of a relation-table mapped relationship must have key fields:... but I can't figure out why, and this is one of the few places this error is mentioned. If anyone can point me in the right direction, I'd really appreciate it. Thanks View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3953119#3953119 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3953119 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: M:N CMP Relationship with unknown Primay Key fails with
I could not resolve the problem, finally removed the unknown-pk and did it by hand with a select max(id) and increment. Tried before almost all possible combinations of XDoclet attibutes. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3953122#3953122 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3953122 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Hibernate problem when deploying multiple .EAR files
Did you check the version of cglib.jar? (3th party lib for hibernate) View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952370#3952370 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952370 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Hibernate problem when deploying multiple .EAR files
Thank you very much for that suggestion! It was exactly what we needed - we were stuck on this problem for tha past few days. The problem was that we included two different cglib files (one in JBoss and the other in one of our ear files). Thanks again :-) View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952397#3952397 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952397 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Transaction not Active excetion
I got the excately the same problem with you. But still can't solve it. Could you please explain me in detail with your code. Many Thanks, View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3951879#3951879 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3951879 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: identifier of an instance of ... was altered from 1 to 0
Any resolution on this. I'm getting this on a bean also..it used towork before I started playing with some things and now I cant figure out what I've done wrong. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952062#3952062 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952062 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Problem in deployment order
This is what i use in applicationContext.xml And my oracle-ds.xml is local-tx-datasource jndi-nameCcpiDS/jndi-name connection-url{T}db.ccpi.url{/T}/connection-url driver-class{T}db.driver{/T}/driver-class user-name{T}db.ccpi.user{/T}/user-name {T}db.ccpi.password{/T} exception-sorter-class-nameorg.jboss.resource.adapter.jdbc.vendor.OracleExceptionSorter/exception-sorter-class-name min-pool-size2/min-pool-size max-pool-size5/max-pool-size /local-tx-datasource Also am accessing the JNDI in my ServletContextListener class. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952169#3952169 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952169 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Problem in deployment order
applicationContext.xml View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952170#3952170 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952170 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Problem in deployment order
are you sure that the problem is the order of deployment and not some other jndi configuration problem? you can try to hot deploy your application after the sever is already running... View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952171#3952171 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952171 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Problem in deployment order
actually i tried changing the order of deployment after i got the NameNotFoundException. I guess in default, the oracle-ds.xml will be deployed before the web app gets deployed, correct me if am wrong? If so why in my listener class it says NameNotException when i try to lookup the JNDI name(java:/CcpiDS). Pls help me out View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952173#3952173 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952173 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Problem in deployment order
This is what am using in the MainDeployer XML so that oracle-ds.xml gets deployed before the web app. Also if am not looking the JNDI in my app during the startup(ie in listener), everything is fine and the server gets started and app gets deployed, and if lookup the JNDI at this stage, am able to do it. So i think definitely the problem is with the order of deployment. web app getting deployed even before oracle-ds.xml is deployed. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952175#3952175 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952175 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Problem in deployment order
| attribute access='read-write' setMethod='setEnhancedSuffixOrder' getMethod='getEnhancedSuffixOrder' | descriptionAllows the override of the suffix order declared by subdeployers, using the syntax [order:]suffix | /description | nameEnhancedSuffixOrder/name | type[Ljava.lang.String;/type | !-- | Statically set one or more enhanced suffix orders, independent of the value proposed by subdeployers. | Some deployers may also allow the suffixes/orders to be set locally, so that's preferable too. | For reference, this is the list of enhanced suffixes likely to be set by deployers (it may not | be completely up-to-date, or there can be user-defined deployers). | | 050:.deployer,050:-deployer.xml,100:.aop,100:-aop.xml,150:.sar,150:-service.xml,200:.beans,250:.rar,300:-ds.xml,350:.har,400:.jar,450:.ejb3,450:.par,500:.war,600:.wsr,650:.ear,700:.jar,750:.zip,800:.bsh,900:.last | | Until we resolve some startup issues, we'll setup some static enhanced suffix orders bellow | and leave the rest of the suffixes contributed dynamically by registering deployers. | -- | descriptors | value value=100:-ds.xml,150:.sar,150:-service.xml,250:.rar,400:.jar,500:.war,650:.ear,800:.bsh,900:.last/ | /descriptors |/attribute View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3952176#3952176 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3952176 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to prevent ApplicationDeadlockException with READ-ON
ereze wrote : I have the same problem: methods marked with read-only but still lots of deadlocks which obviously make our customer mad. | I am not sure but the read only will be used in the optimization technique for the 2P-Protocol ..It will not help in deadlock situation . Regards Vicky View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3951824#3951824 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3951824 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to set another HSQLDB datasource beside DefaultDS?
For 4.0.4.GA you can try this: I installed jboss using the installer.jar, and selected the ejb3-clustered profile which I subsequently renamed as 'all' Delete jboss/server/all/deploy/hsqldb-ds.xml Create a new datasource by copying the template for your specific database from jboss/docs/examples/jca to jboss/server/all/deploy ie. COPY jboss/docs/examples/jca/mysql-ds.xml TO jboss/server/all/deploy/default-ds.xml Edit default-ds.xml Change the jndi-name to DefaultDS Provide your connection parameters, username password etc I used the same database name hsqldb-ds.xml used - 'localDB' here is what I used for mysql | datasources | local-tx-datasource | jndi-nameDefaultDS/jndi-name | connection-urljdbc:mysql://localhost:3306/localDB?createDatabaseIfNotExist=true/connection-url | driver-classcom.mysql.jdbc.Driver/driver-class | user-nameroot/user-name | password/password | exception-sorter-class-nameorg.jboss.resource.adapter.jdbc.vendor.MySQLExceptionSorter/exception-sorter-class-name | !-- sql to call when connection is created | new-connection-sqlsome arbitrary sql/new-connection-sql | -- | !-- sql to call on an existing pooled connection when it is obtained from pool | check-valid-connection-sqlsome arbitrary sql/check-valid-connection-sql | -- | | !-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -- | metadata |type-mappingmySQL/type-mapping | /metadata | /local-tx-datasource | /datasources | Edit jboss/server/all/conf/standardjaws.xml Change the type-mapping, in my case to 'mySQL' Now we have to make jms happy by copying a specific template for your database from jboss/docs/examples/jms to jboss/server/all/deploy/jms ie. COPY joss/docs/examples/jms/mysql-jdbc2-service.xml TO jboss/server/all/deploy/jms/mysql-jdbc2-service.xml Edit the file file and change the datasource name it uses. I had to change mine from MySqlDS to DefaultDS Delete jboss/server/all/deploy/jms/hsqldb-jdbc2-service.xml DO NOT delete hsqldb-jdbc-state-service.xml (I suspect this should be replaced also, but I couldn't figure out what to replace it with). I suspect that other changes might have to be made. The JBoss documentation didn't discuss this. After changing the default ds I was able to sucessfully deploy one ejb3 entity and exercise it thru a stateless session bean -the server boots without exceptions, the ejb3 deploys and works, and it used my database... I'll post again if I learn more. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3951442#3951442 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3951442 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to set another HSQLDB datasource beside DefaultDS?
It looks like I misunderstood your initial posting. The procedure I specified is how to change the default datasource. Not how to use a second hypersonic db. The mysql connector/mxj can embed, and start a mysql database when jboss boots. Then, if you need another datasource, just add another *-ds.xml file to the deploy dir and tell it to use another database name. I suspect this is easier than teaching a second instance of hypersonic where to put it's data. On the other hand, I looked for and found good hypersonic docs on the web once and found it to be quite powerful and the docs were very clear. Have fun, good luck! View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3951444#3951444 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3951444 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Hibernate exceptions and container managed transaction
An interceptor in JBoss is a possible solution. Joris View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950965#3950965 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950965 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: hibernate, saving and updating doesn't do anything
This seems to work.. Is this an acceptable way to do it, or will I encounter exceptions? | session.getTransaction().begin(); | session.saveOrUpdate( in ); | session.getTransaction().commit(); | View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950610#3950610 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950610 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Is it possible to change the associated table name for a
Actually I was able to solve this by extending the EJB3NamingStrategy and add this to the persistence.xml: | property name=hibernate.ejb.naming_strategy value=com.acme.MyCustomNamingStrategy/ | Thanks anyway. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950622#3950622 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950622 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Javassist errors with latest jboss
Well, like I said, using generics can cause this error, because it generates 2 different methods in runtime. Your example use the same principle of generics: u are redefining the returning type of a method to a subtype of original, and this produces the same two methods, one volatile, other concrete. Your code doesnt compile in JDK1.4 because there's no support to generics in it. My javassist mode will resolve your problem too. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950678#3950678 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950678 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Optimistic Locking Versioning
it should work fine. What you need in your hbm files is: . class name=com.canpay.gm.persistent.model.BankAccount table=BankAccount optimistic-lock=version xxx id name=id column=id type=long unsaved-value=null natural-id /natural-id other properties TEFRON View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950721#3950721 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950721 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Migration Woes...
Well looks like no one else knows what went wrong either. Am a little worried now as I fear this error could come back and bite me! Well thanks to thoese who gave it a read anyway Tim View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950398#3950398 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950398 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Accessing the dicriminator column
In most cases you don't need this property, all you have to do is find-select on the sub-class. We needed to use it when we had a collectioin of parent class objects that contain mix of sub-classes items and we needed to select objects of one sub-class. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950448#3950448 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950448 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Make hibernate ignore a certain getter method
you can use inheritance . i.e. have your mapped entity extends a java class that handle non persistent properties. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950449#3950449 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950449 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: identifier of an instance of ... was altered from 1 to 0
This is the source anonymous wrote : | import java.io.Serializable; | | import java.util.List; | | import javax.ejb.Remote; | import javax.ejb.Remove; | import javax.ejb.Stateful; | | import javax.persistence.EntityManager; | import javax.persistence.PersistenceContext; | import javax.persistence.Query; | | @Stateful | @Remote(Visitor.class) | public class VisitorSessionBean implements Visitor, Serializable { | | @PersistenceContext | private EntityManager manager; | | private Login login; | | public boolean login(String userName, String passWord) { | | String hql = from Login l where l.userName = :userName and l.passWord = :passWord; | Query query = manager.createQuery(hql); | query.setParameter(userName, userName); | query.setParameter(passWord, passWord); | List list = query.getResultList(); | | return list.size() == 1; | } | View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950529#3950529 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950529 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: identifier of an instance of ... was altered from 1 to 0
Prepared Statement has two states why? anonymous wrote : | 2006-06-13 00:17:41,578 DEBUG [org.hibernate.hql.ast.QueryTranslatorImpl] HQL: from org.person.ejb.Login l where l.userName = :userName and l.passWord = :passWord | 2006-06-13 00:17:41,578 DEBUG [org.hibernate.hql.ast.QueryTranslatorImpl] SQL: select login0_.loginid as loginid12_, login0_.username as username12_, login0_.password as password12_ from login login0_ where login0_.username=? and login0_.password=? | 2006-06-13 00:17:41,578 DEBUG [org.hibernate.hql.ast.ErrorCounter] throwQueryException() : no errors | 2006-06-13 00:17:41,609 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] New jmx UCL with url null | 2006-06-13 00:17:41,609 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, [EMAIL PROTECTED], [EMAIL PROTECTED] url=null ,addedOrder=0} | 2006-06-13 00:17:41,609 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] New jmx UCL with url null | 2006-06-13 00:17:41,609 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, [EMAIL PROTECTED], [EMAIL PROTECTED] url=null ,addedOrder=0} | 2006-06-13 00:17:41,625 DEBUG [org.hibernate.jdbc.AbstractBatcher] about to open PreparedStatement (open PreparedStatements: 0, globally: 0) | 2006-06-13 00:17:41,625 DEBUG [org.hibernate.jdbc.ConnectionManager] opening JDBC connection | 2006-06-13 00:17:41,625 DEBUG [org.hibernate.SQL] select login0_.loginid as loginid12_, login0_.username as username12_, login0_.password as password12_ from login login0_ where login0_.username=? and login0_.password=? | 2006-06-13 00:17:41,640 DEBUG [org.hibernate.loader.hql.QueryLoader] bindNamedParameters() urswag - userName [1] | 2006-06-13 00:17:41,640 DEBUG [org.hibernate.loader.hql.QueryLoader] bindNamedParameters() urs-1wag - passWord [2] | 2006-06-13 00:17:41,640 DEBUG [org.hibernate.jdbc.AbstractBatcher] about to open ResultSet (open ResultSets: 0, globally: 0) | 2006-06-13 00:17:41,640 DEBUG [org.hibernate.loader.Loader] result row: EntityKey[org.person.ejb.Login#1] | 2006-06-13 00:17:41,656 DEBUG [org.hibernate.jdbc.AbstractBatcher] about to close ResultSet (open ResultSets: 1, globally: 1) | 2006-06-13 00:17:41,656 DEBUG [org.hibernate.jdbc.AbstractBatcher] about to close PreparedStatement (open PreparedStatements: 1, globally: 1) | 2006-06-13 00:17:41,656 DEBUG [org.hibernate.jdbc.ConnectionManager] aggressively releasing JDBC connection | 2006-06-13 00:17:41,656 DEBUG [org.hibernate.jdbc.ConnectionManager] releasing JDBC connection [ (open PreparedStatements: 0, globally: 0) (open ResultSets: 0, globally: 0)] | 2006-06-13 00:17:41,656 DEBUG [org.hibernate.engine.TwoPhaseLoad] resolving associations for [org.person.ejb.Login#1] | 2006-06-13 00:17:41,671 DEBUG [org.hibernate.engine.TwoPhaseLoad] done materializing entity [org.person.ejb.Login#1] | 2006-06-13 00:17:41,671 DEBUG [org.hibernate.engine.StatefulPersistenceContext] initializing non-lazy collections | 2006-06-13 00:17:41,671 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] New jmx UCL with url null | 2006-06-13 00:17:41,671 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, [EMAIL PROTECTED], [EMAIL PROTECTED] url=null ,addedOrder=0} | 2006-06-13 00:17:41,671 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] New jmx UCL with url null | 2006-06-13 00:17:41,671 DEBUG [org.jboss.mx.loading.RepositoryClassLoader] setRepository, [EMAIL PROTECTED], [EMAIL PROTECTED] url=null ,addedOrder=0} | 2006-06-13 00:17:41,671 DEBUG [org.hibernate.event.def.AbstractFlushingEventListener] processing flush-time cascades | 2006-06-13 00:17:41,671 DEBUG [org.hibernate.event.def.AbstractFlushingEventListener] dirty checking collections | 2006-06-13 00:17:41,687 DEBUG [org.jboss.ejb3.entity.ManagedEntityManagerFactory] ** closing entity managersession ** | 2006-06-13 00:17:41,687 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/bank3].[Faces Servlet]] Servlet.service() for servlet Faces Servlet threw exception | View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950546#3950546 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950546 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Accessing the dicriminator column
Yes, I actually figured out this rather simple (and obvious!) workaround just after I posted - thanks for the info. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950305#3950305 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950305 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: About the Transaction rollback of the container manageme
Hello. 'org.jboss.tm.JBossRollbackException' is generated, and rollback cannot be done though RuntimeException came to be able to do in catche by using '@ApplicationException(rollback=true)' as advised. Is there a problem in the writing of the code? Or, is it a setting of Jboss and is there anything necessary? May I have the known person advice? It asks suitably. My Exception Class: | @ApplicationException(rollback=true) | public class MyAppException extends Exception{ | | public MyAppException(){} | public MyAppException(String msg){ | super(msg); | } | } | Stateless Session Bean Class: | @Stateless | @Local(TestSession.class) | @Remote(TestSession.class) | | public class TestSessionBean implements TestSession{ | @PersistenceContext | protected EntityManager em; | | @TransactionAttribute(TransactionAttributeType.REQUIRED) | public void insertTestUser(TestUserBean usrs) throws MyAppException{ | em.persist(usrs); | } | } | Servlet Class: | public Value doBiz(Hashtable param, HttpServletRequest req){ | String page = /jsp/test/TestEntryEnd.jsp; | Value value = new Value(); | | try{ | TestUserBean usrs = new TestUserBean(); | usrs.setTestUserId(1); | usrs.setTestName(test name); | | /* DB insert */ | TestService service = new TestService(); | service.insertTestUser(usrs); | | /* To cause the exception, the data of same ID is inserted again. */ | TestUserBean usrs2 = new TestUserBean(); | usrs2.setTestUserId(1); | usrs2.setTestName(test name2); | | service.insertTestUser(usrs2); | | value.setForwardPage(page); | }catch(Exception ex){ | System.out.println(* TestEntryEnd.doBiz catch ex = + ex); | value.addErrorMessage(TestEntryEnd Error); | value.setError(true); | } | return value; | } | Error stack trace 12:30:14,603 WARN [JDBCExceptionReporter] SQL Error: 0, SQLState: null 12:30:14,603 ERROR [JDBCExceptionReporter] Batch entry 0 insert into testmail (testMail, testUserId, testMailId) values (13, 13, 13) was aborted. Call getNextException to see the cause. 12:30:14,603 WARN [JDBCExceptionReporter] SQL Error: 0, SQLState: 23505 12:30:14,603 ERROR [JDBCExceptionReporter] ERROR: duplicate key violates unique constraint testmail_pkey 12:30:14,604 ERROR [AbstractFlushingEventListener] Could not synchronize database state with session org.hibernate.exception.ConstraintViolationException: Could not execute JDBC batch update at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:69) at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43) at org.hibernate.jdbc.AbstractBatcher.executeBatch(AbstractBatcher.java:202) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:230) at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:140) at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:296) at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27) at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1009) at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:356) at org.hibernate.transaction.CacheSynchronization.beforeCompletion(CacheSynchronization.java:59) at org.jboss.tm.TransactionImpl.doBeforeCompletion(TransactionImpl.java:1473) at org.jboss.tm.TransactionImpl.beforePrepare(TransactionImpl.java:1092) at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:306) at org.jboss.aspects.tx.TxPolicy.endTransaction(TxPolicy.java:175) at org.jboss.aspects.tx.TxPolicy.invokeInOurTx(TxPolicy.java:87) at org.jboss.aspects.tx.TxInterceptor$Required.invoke(TxInterceptor.java:192) at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:98) at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76) at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:98) at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:54) at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:98) at
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Exception setting property value with CGLIB
I forgot to mension version of JBoss: i use JBoss 4.0.4.GA.Patch1 installed from installer with EJB3 profile, database PostgreSQL ver. 8.0.4 with JDBC3 driver ver. 8.0.314 View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950068#3950068 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950068 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: About the Transaction rollback of the container manageme
SQLException extends Exception, not RuntimeException. EJB Specs say that if a RuntimeException is thrown in a transactional EJB method, the associated transaction is rolledback automatically. But for plain Exceptions (non RuntimeExceptions), like the one you are getting, the container doesn't rollback automatically (as there's a chance that the user might want to retry the operation). In order to cause the transaction to rollback, you need to call sessionContext.setRollbackOnly(), which will mark the transaction to avoid commital. Note: EJB Specs talk about System Exceptions and Application Exceptions, not about checked-unchecked nor runtime-nonruntime, I just explained quickly with runtime-nonruntime, but you should read the Specs anyway. Also, you might want to read the book Enterprise JavaBeans [Bill Burke, Sacha Labourey and Richard Monson-Haefel], specially chapter 16, part 6: Exceptions and Transactions. Kind regards, Guido Scalise View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950069#3950069 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950069 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Exception setting property value with CGLIB
Sorry, JBoss 4.0.4RC1 installed from installer with EJB3 profile View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950070#3950070 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950070 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: About the Transaction rollback of the container manageme
I should add that, in EJB3, there's an Annotation for business methods, in order to force Rollback if an ApplicationException is thrown from the method: @ApplicationException(rollback=true) Cheers, Guido Scalise View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950071#3950071 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950071 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: About the Transaction rollback of the container manageme
Thank you for the reply. Rollback cannot be still done though '@ApplicationException(rollback=true)' was added to SessionBean. Is this a cause though the method of the business is in servlet? Stateless Session Bean Class: | @Stateless | @Local(TestSession.class) | @Remote(TestSession.class) | @ApplicationException(rollback=true) | | public class TestSessionBean implements TestSession{ | @PersistenceContext | protected EntityManager em; | | @TransactionAttribute(TransactionAttributeType.REQUIRED) | public void insertTestUser(TestUserBean usrs){ | em.persist(usrs); | | /* When the exception is compulsorily caused here, the roll backing is done. */ | //throw new RuntimeException(!! RuntimeException !?); | } | } | View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950122#3950122 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950122 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Accessing the dicriminator column
I'm also looking for this functionality - anyone??? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950194#3950194 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950194 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Accessing the dicriminator column
assuming that you mean with hibernate... You can add a read-only property to your hbm mapping file with the column attribute set to the same name as the discriminator column. e.g. good luck. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3950196#3950196 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3950196 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to choose Oracle DEFAULT value over NULL value?
Thank you for confirming this one. I'm not happy with it though. -- Alex View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949780#3949780 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949780 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Javassist errors with latest jboss
I am getting the same error. I just wanted to add a little bit of information. For me my code worked fine with jboss-4.0.4.GA using the ejb3-clustered configuration. As soon as I updated to jboss-4.0.4-Patch1 with the same configuration and code, I began getting the errors described above. Similarily to the code listed by penczek I am using an inheritance hierarchy that inherits from a @MappedSuperclass, in which the getID method is defined, although my classes are not defined using generics a the class level. It seems as if the duplicate method error is always occurring on the member function that is annotated with the @Id annotation. It looks as if that is the case for penczek as well. Does this mean that the use of inheritance hierarchies with mapped superclasses is completely broken for this jboss release?? Is there any bug that was filed for this issue yet that anyone knows of?? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949961#3949961 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949961 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Javassist errors with latest jboss
I believe I figured out what the underlying issue is. see this post: http://www.jboss.com/index.html?module=bbop=viewtopict=84174 Apparently, when entities use inheritance and have a return type for an overridden method that is different form the base class the duplicate method exception occurrs. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949964#3949964 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949964 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: EJB3/EntityManager/Transactions and LazyInitializationEx
don't close your session, and if you do, just call update into a new session before you acceess a lazy property... View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949602#3949602 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949602 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Problems with em.persist() and query.getResultList()
Your entities should be mapped in your configuration file: e.g. classes/hibernate.cfg.xml: !DOCTYPE hibernate-configuration PUBLIC -//Hibernate/Hibernate Configuration DTD 3.0//EN http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd; hibernate-configuration session-factory org.gjt.mm.mysql.Driver jdbc:mysql://1.1.1.1:3306/yourdb you sss org.hibernate.dialect.MySQLDialect false /session-factory /hibernate-configuration good luck. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949611#3949611 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949611 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: EJB3/EntityManager/Transactions and LazyInitializationEx
tefron wrote : don't close your session, and if you do, just call update into a new session before you acceess a lazy property... That's just it, I don't want to close the transaction, but when I leave the ejb, the transaction is closed for me. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949621#3949621 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949621 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: EJB3/EntityManager/Transactions and LazyInitializationEx
You need to open a transaction via UserTransaction in your Struts-Action, so that the SessionBean-call will be inside your own transaction. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949634#3949634 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949634 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: EJB3/EntityManager/Transactions and LazyInitializationEx
I was hoping jboss would start the transaction for me, when my http request happened, and then close it when it was done. But no go. So I wrote the servlet filter below, and it all works. I just hoped the container would take care of it for me. Maybe in the future, when we have more time, I will try out Seam. | public class TransactionFilter implements Filter { |FilterConfig config = null; | | public void init(FilterConfig arg0) throws ServletException { |config=arg0; | } | | public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException { | | InitialContext ctx; | UserTransaction ut = null; | try { | ctx = new InitialContext(); | ut = (UserTransaction) ctx.lookup(UserTransaction); | if(Status.STATUS_NO_TRANSACTION == ut.getStatus()) { | ut.begin(); | } else { | ut = null; | } | } catch (Exception e) { | config.getServletContext().log(Error getting context and beginning transaction, e); | } | | | try { | chain.doFilter(request, response); | if((ut != null) (Status.STATUS_ACTIVE == ut.getStatus())) { | ut.commit(); | } | } catch (Exception e) { | config.getServletContext().log(Error in filter or commit, e); | try { | if((ut != null (Status.STATUS_ACTIVE == ut.getStatus( { |ut.rollback(); | } | } catch (Exception e1) { | config.getServletContext().log(Error rolling back exception, e1); | } | } finally { | | } |} | | public void destroy() { | } | } View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949670#3949670 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949670 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: How to choose Oracle DEFAULT value over NULL value?
No. Move the default value from database to entity bean. In ejbCreate() do this.setMycolumn( 1 ); View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949718#3949718 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949718 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Jboss 4.0.4 not closing SessionFactory? Redeploy fails
Please, isn't there anyone who can help with this? It's seriously annoying to have to restart the jboss server every time you redeploy your application. I've looked for a soloution for over a week now, but the problem still persists. some more info: This is how i use the sessionfactory: | package session; | | | import org.hibernate.HibernateException; | import org.hibernate.Session; | import org.hibernate.SessionFactory; | import org.hibernate.cfg.Configuration; | /** | * Configures and provides access to Hibernate sessions, tied to the | * current thread of execution. Follows the Thread Local Session | */ | public class HibernateSessionFactory { | | /** Holds a single instance of Session */ | private static final ThreadLocal threadLocal = new ThreadLocal(); | | /** The single instance of hibernate configuration */ | private static final Configuration cfg = new Configuration(); | | /** The single instance of hibernate SessionFactory */ | private static SessionFactory sessionFactory; | | /** | * Returns the ThreadLocal Session instance. Lazy initialize | * the codeSessionFactory/code if needed. | * | * @return Session | * @throws HibernateException | */ | @SuppressWarnings(unchecked) | public static Session currentSession() throws HibernateException { | Session session = (Session) threadLocal.get(); | | if (session == null) { | if(sessionFactory == null) { | try { | sessionFactory = cfg.configure().buildSessionFactory(); | } | catch (Exception e) { | System.err.println( Error building SessionFactory); | e.printStackTrace(); | } | } | try { | session = sessionFactory.openSession(); | threadLocal.set(session); | } | catch (Exception e) { | System.err.println( Error opening SessionFactory); | e.printStackTrace(); | } | | } | | /*if(!session.isConnected()) { | session.reconnect(); | }*/ | return session; | } | | /** | * Close the single hibernate session instance. | * | * @throws HibernateException | */ | public static void closeSession() throws HibernateException { | Session session = (Session) threadLocal.get(); | threadLocal.set(null); | //System.out.println(Closing the session in sessionfactory); | if (session != null) { | session.close(); | } | } | | /** | * Default constructor. | */ | private HibernateSessionFactory() { | } | | } | and this is my hibernate config: | ?xml version=1.0 encoding=UTF-8? | !DOCTYPE hibernate-configuration PUBLIC | -//Hibernate/Hibernate Configuration DTD 3.0//EN | http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd; | hibernate-configuration | session-factory | property name=hibernate.connection.driver_classorg.postgresql.Driver/property | property name=hibernate.connection.password123456/property | property name=hibernate.connection.urljdbc:postgresql://localhost:5432/TRIM/property | property name=hibernate.connection.usernameadmin/property | property name=hibernate.dialectorg.hibernate.dialect.PostgreSQLDialect/property | | !-- mapping files -- | | mapping resource=hibernate_xml/Users.hbm.xml / | mapping resource=hibernate_xml/Module.hbm.xml / | mapping resource=hibernate_xml/ModuleAccess.hbm.xml / | mapping resource=hibernate_xml/UserGroup.hbm.xml / | mapping resource=hibernate_xml/SystemDefault.hbm.xml / | mapping resource=hibernate_xml/RelationType.hbm.xml / | mapping resource=hibernate_xml/Relation.hbm.xml / | mapping resource=hibernate_xml/Resource.hbm.xml / | mapping resource=hibernate_xml/Contact.hbm.xml / | mapping resource=hibernate_xml/ResourceType.hbm.xml / | mapping resource=hibernate_xml/Unit.hbm.xml / | mapping resource=hibernate_xml/ResourceCategory.hbm.xml / | mapping resource=hibernate_xml/Activity.hbm.xml / | mapping
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Finder method returns internal error
Is open source always such a pain? I changed jbosscmp.xml exception. | entity | ejb-nameLoginEntityBean/ejb-name | table-namelogin/table-name | cmp-field | unknown-pk | unknow-pk-class | org.person.ejb.login.LoginKey | /unknow-pk-class | field-nameloginKey/field-name | column-nameloginid/column-name | auto-increment / | /unknown-pk | /cmp-field | cmp-field | field-nameuserName/field-name | column-nameusername/column-name | /cmp-field | cmp-field | field-namepassWord/field-name | column-namepassword/column-name | /cmp-field | /entity | I get now the following exception: anonymous wrote : | org.jboss.tm.JBossTransactionRolledbackException: Could not instantiate bean; nested exception is: | javax.ejb.EJBException: Could not instantiate bean; - nested throwable: (javax.ejb.EJBException: Could not instantiate bean) | at org.jboss.ejb.plugins.LogInterceptor.handleException(LogInterceptor.java:281) | at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:210) | at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:136) | at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:643) | at org.jboss.ejb.Container.invoke(Container.java:917) | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) | at java.lang.reflect.Method.invoke(Method.java:585) | at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) | at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) | at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) | at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:260) | at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) | at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:819) | at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:420) | at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) | at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) | at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) | at java.lang.reflect.Method.invoke(Method.java:585) | at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294) | at sun.rmi.transport.Transport$1.run(Transport.java:153) | at java.security.AccessController.doPrivileged(Native Method) | at sun.rmi.transport.Transport.serviceCall(Transport.java:149) | at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460) | at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701) | at java.lang.Thread.run(Thread.java:595) | Caused by: javax.ejb.EJBException: Could not instantiate bean | at org.jboss.ejb.plugins.AbstractInstancePool.get(AbstractInstancePool.java:206) | at org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityInstanceInterceptor.java:113) | at org.jboss.ejb.plugins.EntityLockInterceptor.invokeHome(EntityLockInterceptor.java:76) | at org.jboss.ejb.plugins.EntityCreationInterceptor.invokeHome(EntityCreationInterceptor.java:43) | at org.jboss.ejb.plugins.CallValidationInterceptor.invokeHome(CallValidationInterceptor.java:56) | at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:125) | at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350) | at org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:161) | at org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:145) | at org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:135) | at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invokeHome(ProxyFactoryFinderInterceptor.java:107) | at org.jboss.ejb.EntityContainer.internalInvokeHome(EntityContainer.java:525) | at org.jboss.ejb.Container.invoke(Container.java:938) | at
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Jboss 4.0.4 not closing SessionFactory? Redeploy fails
There are some problems/bugs with the jboss 4.0.4, but the ones I found were related to the web console. Actually some major problems were fixed too... When I ported my web applications + hibernate to 4.0.4 I had to remove/adjust the version of some .jar files that hibernate use, as 4.0.4 uses newer version. For hot redeployment to work I adjusted the perm memory settings, and update the jboss-tomcat jsf folder content (only if you need jsf) hope it helps... View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949397#3949397 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949397 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Jboss 4.0.4 not closing SessionFactory? Redeploy fails
Thanks for your reply. I ended up rewriting the sessionfactory to a mbean instead, and configured the postgresql db connection as a datasource in jboss. Now jboss handles the sessionFactory instead of the application, and the redeployment works as expected. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949451#3949451 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949451 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Finder method returns internal error
jbosscmp-jdbc.xml entry of the entity anonymous wrote : | | | ejb-nameLoginEntityBean/ejb-name | table-namelogin/table-name | cmp-field | field-nameloginKey/field-name | column-nameloginid/column-name | auto-increment / | /cmp-field | cmp-field | field-nameuserName/field-name | column-nameusername/column-name | /cmp-field | cmp-field | field-namepassWord/field-name | column-namepassword/column-name | /cmp-field | | View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949239#3949239 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3949239 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: What happens if you wait too long for a connection?
Answers: 1.) JBoss will attempt to handle all of the connections via the connection pool. But 2000 connections will most likely not be able to be handled and you will start getting exceptions. 2.) Configurable 3.) Yes. You should always code for a possible connection timeout or failure. 4.) Depends. Could be timout exception, or some other goofy non-related exception. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3948955#3948955 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3948955 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Automatic generation of primary key
Thank you for your reply. I've tried your solution using entity-command name=mysql-get-generated-keys/entity-command and autoincrement/ Unfortunatly, it doesn't solve my problem (I still get a null primary key). Did you do something else in order to find this class?(maybe adding a jar or a reference to a jar)? Thank you again View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3948631#3948631 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3948631 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Automatic generation of primary key
I don't know what it could be then :(. As far as i understand, general idea of pk generation is to tell EJB engine what type (class) of pk it will be, and tell details to jboss personally. Something about integer type should be mentioned in ejb-jar.xml and particular instructions in jbosscmp-jdbc.xml How your ejbCreate and ejbPostCreate looks like? It should not contain pk field in signature and no calls to pk inside i mean nothing of getId() (could be not assigned yet) and setId(id) will override autoincremented value. That is just my current understanding, it works for me. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3948702#3948702 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3948702 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Re: Single UPDATE instead of SELECT, then UPDATE
The problem has been solved. I'd like to share the story. The question was going from obivious lack of J2EE and JBoss experience and understanding. I was absolutely sure that dataSource.getConnection() returns free connection and this free connection means new transaction. I've had tried to use same datasource for cmp beans and session beans. Lets say it is registered as java:jdbc/cmp in global evinonent (possibly other depoyments use java:DefaultDS or java:MySqlDS). I've placed a ref link to it for my Session bean Cashier. In xdoclet attributes it looks like: | @ejb.resource-ref res-ref-name=dataSource ref-type=javax.sql.DataSource jndi-name=java:jdbc/cmp res-auth=Container | @jboss.resource-ref res-ref-name=dataSource jndi-name=java:jdbc/cmp | Cashier session bean has a private field of javax.sql.DataSource type dataSource. It is being initialized in ejbCreate() | public void ejbCreate() throws CreateException { |try { | InitialContext ctx = new InitialContext(); | this.dataSource = (DataSource) ctx.lookup(java:comp/env/dataSource); | // |} catch (NamingException nEx) { | throw new RuntimeException(nEx); |} | } | Now dataSource field is usable. So deposit() method from example above has changed to | public void deposit(Integer customerId, int value) throws RemoteException { | Connection conn = null; | try { |conn = this.dataSource.getConnection(); |PreparedStatement stmt = conn.prepareStatement(UPDATE customer SET credits=credits+? WHERE id =?); |stmt.setInt(1, value); |stmt.setObject(2, customerId); |stmt.executeUpdate(); | } catch { | /// bla bla. catch some common exceptions | } finally { |if(conn != null) { |try { | conn.close(); |} catch (SQLException sqlEx) { | // log error |} |} | } | } | That is really simple and was hard for me to believe. Queries generated inside new deposit method come inside transaction which is managed by container! (I've verified it from mysql query logs). It is forbidden to use conn.commit(), conn.rollback() and conn.setAutoComint(...) methods, an exception will be thrown and whole transaction will be rolled back. Similar solution has been applied to many methods for local edition of the Cashier bean. Total application has been stress tested with REPETABLE_READ isolation level for mysql. Works perfectly. At least one drawback indeed exist, now sql code moved to java code (or deployment descriptors). It is not very beautiful to my humble opinion. P.S. Next question of curiosity. Will other containers behave in the same way? I hope it will never come to find an answer myself :). View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3948785#3948785 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3948785 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Automatic generation of primary key
Thank you for your answer. It was the way I found. I use entity-command name=key-generator | class=org.jboss.ejb.plugins.cmp.jdbc.keygen.JDBCKeyGeneratorCreateCommand | attribute name=key-generator-factory | HiLoKeyGeneratorFactory | /attribute | | /entity-command Unfortunatly, I get a ClassCastException because it generates a Long and I need an Integer. Do you now the name of an appropriate factory? Thank you View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3948306#3948306 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3948306 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Automatic generation of primary key
Look for auto-increment and entity-command. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3948201#3948201 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3948201 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Is this a Java Or JBoss bug?
It's neither a bug in java or jboss, you shouldn't alternate a collection while running over it with an iterator. dirk View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3947613#3947613 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3947613 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Problem hot-deploying EJB/Spring/Hibernate app on JBoss
i am experiencing this problem too. I have jBoss4.0.3SP1 and my spring configuration of the session factory is below. On hot (re)deployment, the exception is thrown on startup saying that the cache manager lookup returns (null) etc. etc. Rebooting the server works! I think its likely a classpath / classloader issue. Reflection is not managing to instantiate either org.hibernate.transaction.JBossTransactionManagerLookup or it is not managing itself to instantiate something. Any ideas or solutions anyone? org.hibernate.dialect.Oracle9Dialect org.hibernate.cache.EhCacheProvider ppf.SessionFactory true org.hibernate.transaction.JTATransactionFactory org.hibernate.transaction.JBossTransactionManagerLookup true after_statement View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3947618#3947618 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3947618 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Jboss 4.0.4 not closing SessionFactory? Redeploy fails
Oh, and this is the error I get when I try to build a sessionfactory after I've redeployed: | org.hibernate.cache.CacheException: Attempt to restart an already started EhCacheProvider. Use sessionFactory.close() between repeated calls to buildSessionFactory. Consider using net.sf.ehcache.hibernate.SingletonEhCacheProvider. Error from ehcache was: Cannot parseConfiguration CacheManager. Attempt to create a new instance of CacheManager using the diskStorePath /tmp which is already used by an existing CacheManager. The source of the configuration was classpath. | View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3947267#3947267 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3947267 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Is there any way to define derived entity class to repre
Excuse me for I entered to long subject. I mean: Is there any way to define derived entity class to represent database view. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3947354#3947354 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3947354 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: redeploy har without restarting server?
1.delete your har file and the hibernate session factory will be closed; 2.copy your new har file in the ../deploy, then server will start the service. if you find more convinent way,please tell me! thank you! View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3947239#3947239 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3947239 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Transaction not Active excetion
Problem was in my own code. I had an exception on the transaction that was not rolledback so the connection had an uncleaned transaction on it. Since my other select was running on the same thread it got the same uncleaned connection with the transaction. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3947090#3947090 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3947090 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: How to force the Container to call ejbStore();
chaituu wrote : bhupendra.yaduvenshi wrote : their is tag in standerdjboss.xml in max bean age set this paramete as u want this will called ejb pasivate in 1 sec or wht do u want that is the proper way. | | | | Bhupendra | | after setting max bean age as 1 sec still container is not calling ejbStore() View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946722#3946722 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946722 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: NPE when looking up the Hibernate session factory in the
I have the same problem but I use the new version jboss-4.0.4 I even need change any thing , It work !! View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946727#3946727 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946727 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Regarding CMP
Hi Laliluna, I have the same kind of problem I have posted my message at http://www.jboss.org/index.html?module=bbop=viewtopict=83704 Please advice me on this how can sort this out. Thanks View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946776#3946776 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946776 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Is it possible to change the associated table name for a
No, and no. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946874#3946874 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946874 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: java.io.StreamCorruptedException: invalid stream header
I'm having the same problem, any luck with this one? View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946976#3946976 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946976 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: How to force the Container to call ejbStore();
bhupendra.yaduvenshi wrote : their is tag in standerdjboss.xml in max bean age set this paramete as u want this will called ejb pasivate in 1 sec or wht do u want that is the proper way. | | Bhupendra Is that is the only way to call ejbStore() immediately after set parameter View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946414#3946414 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946414 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: How to force the Container to call ejbStore();
bhupendra.yaduvenshi wrote : Simply called ejb passivate. | | | Bhupendra | how to ejbpassivate View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946066#3946066 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946066 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Problem with oracle-ds.xml
u r in the wrong path becaz this is put always in server/default/deploy. Bhupendra View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946073#3946073 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946073 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Warning: The return type must be the entity bean's prima
Always remeber in case of jboss ur return type in case of ejbcreate is primary ket write public ejbPK ejbCreate(String, String, String, String, String) { setters return null; } if any confusion than let me know View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946075#3946075 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946075 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: How to force the Container to call ejbStore();
their is tag in standerdjboss.xml in max bean age set this paramete as u want this will called ejb pasivate in 1 sec or wht do u want that is the proper way. Bhupendra View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946077#3946077 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946077 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Error: javax.naming.NamingException: Could not dereferen
first incluse ur jnpclient.jat in lib than tell me wht is the exact error. Bhupendra View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946079#3946079 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946079 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Re: Warning: The return type must be the entity bean's prima
Thank you the problem was that we didn't include the right class of primary key in the ejb-jar.xml Now Jboss deploys regularly...thank you View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3946178#3946178 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3946178 --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user