[JBoss-user] [EJB 3.0] - Re: Transient members
Hello Milan, thank you for your hint. I switched on the EJB3EntityTreeCache and this cache works. One can check this via jmx-console - service=EJB3EntityTreeCache - java.lang.String printDetails() invoke But here is a catch in it! Only the data persistent via the hibernate mapping is cached. So this does not have the desired effect. I'm trying now the following: I create a reference from the JNDI to this bean. If I access the field transientText in the Node-bean, then I get the originally value. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3929424#3929424 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3929424 --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [EJB 3.0] - Re: Transient members
of course its correct. The spec says: anonymous wrote : 9.1.14 Transient Annotation | The Transient annotation is used to annotate a property or field of the entity class. It specifies that | the property or field is not persistent. | @Target({METHOD, FIELD}) @Retention(RUNTIME) | public @interface Transient {} | Example: | @Entity | public class Employee { | @Id int id; | @Transient User currentUser; | ... | } which means, that if u fetch a entity bean from the database, its transient members can not be initialized since they are not stored. regards, milan wölke View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3927480#3927480 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3927480 --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [EJB 3.0] - Re: Transient members
Hello Milan, thanks for your answer. Do you know wether the entity bean is always fetched from the database or is it possible that the entity bean exist as an object in the java virtual machine? Of course changes to the persistent fields must be in sync with the database. Best Regards Frank View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3927556#3927556 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3927556 --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [EJB 3.0] - Re: Transient members
U r referring to some kind of caching, dont u. Unfortunately a cache is not part of the ejb30 spec, but u can use the hibernate l2 cache. It keeps your entitybeans in memory, and keeps them in sync with the db. the drawback is, that u have to use hibernate annotations with your entity beans, which i personally dislike. -- hint: jboss-entity-cache dont ask me, is transient field would survive caching, u have to try that. but to answer the first question, if u dont use l2 caching, yes it will be fetched every time. View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3927561#3927561 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3927561 --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] [EJB 3.0] - Re: Transient members
Although the data is not persistent via the EJB3 persistence mechanism, I would like to keep some data in the entity beans. I will take a closer look at the the jboss-entity-cache! View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3927572#3927572 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=3927572 --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user