tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Struberg <strub...@yahoo.de>
Subject Re: Hibernate Vs OpenJPA
Date Tue, 24 Sep 2013 10:57:11 GMT

>>  nothing or weaving too (to support blobs for instance or some lazy loading
>>  on 1-1 IIRC)  ??????????
With hibernate you will by default get native Java objects from the PersistenceManager. Pretty
much the only 'special' thing about them is that all Collections are replaced with proxying
variants, e.g. (class names are just examples) instead of List<User> you will get a
LazyLoadingList<User>. 

Other members like String, byte[] etc will _not_ get some proxies but will be accessed natively.

Please note that this is fine from a JPA spec perspective as the spec defines that LAZY fetching
is only a 'hint' to the JPA container, but not a command.

LieGrue,
strub




----- Original Message -----
> From: Romain Manni-Bucau <rmannibucau@gmail.com>
> To: "users@tomee.apache.org" <users@tomee.apache.org>
> Cc: OpenEJB Users <users@openejb.apache.org>
> Sent: Tuesday, 24 September 2013, 12:35
> Subject: Re: Hibernate Vs OpenJPA
> 
> one to one relationships
> 
> *Romain Manni-Bucau*
> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
> *Blog: 
> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
> *Github: https://github.com/rmannibucau*
> 
> 
> 
> 2013/9/24 mauro2java2011 <mauro2java2011@gmail.com>
> 
>>  escuse me but i not understand :
>>  -------------------------------------------------------------------
>>  nothing or weaving too (to support blobs for instance or some lazy loading
>>  on 1-1 IIRC)  ??????????
>>  -----------------------------------------------------------
>>  A) escuse me but i not have understand what it is 1-1 IIRC  ......
>> 
>>  B)Without weaving hibernate not support blobs for example or lazy loading ?
>>  Romain Manni-Bucau wrote
>>  > Hi
>>  >
>>  > i answered inline
>>  >
>>  > *Romain Manni-Bucau*
>>  > *Twitter: @rmannibucau &lt;https://twitter.com/rmannibucau>*
>>  > *Blog:
>>  > **
>>  http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
>>  ;
>>  > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
>>  > *Github: https://github.com/rmannibucau*
>>  >
>>  >
>>  >
>>  > 2013/9/24 mauro2java2011 &lt;
>> 
>>  > mauro2java2011@
>> 
>>  > &gt;
>>  >
>>  >> I know that OpenJPA weaving entity statically or dinamitically 
> with a
>>  >> java
>>  >> agent true ??????
>>  >>
>>  >>
>>  >> I make 3 ask :
>>  >>
>>  >> 1) HIbernate not weave the entities???
>>  >> OR what mechanosme it use ????
>>  >>
>>  >
>>  > nothing or weaving too (to support blobs for instance or some lazy
>>  loading
>>  > on 1-1 IIRC)
>>  >
>>  >
>>  >>
>>  >> 2) If i use a project client that make call remote at a tomee
>>  application
>>  >> and i get entities like value return of EJb methods , i have to 
> have
>>  into
>>  >> classpath of client the entities weave.
>>  >> SO how i can get statically the entities at build time with 
> netbeans ?
>>  >> for
>>  >> incluede it int othe client project .
>>  >>
>>  >
>>  > using DTO avoids it otherwise yes cause of serialization mecanisms, on
>>  > trunk you can use another serializer than java default mecanism so it
>>  > would
>>  > solve it
>>  >
>>  >
>>  >>
>>  >> 3) With hibernate is not  mandatory  weaving entity ? SO i can 
> compile
>>  >> without weaving entity for place into the classpath of client ?
>>  >>
>>  >>
>>  >>
>>  > same with openjpa using the javaagent (openejb-javaagent)
>>  >
>>  >
>>  >>
>>  >>
>>  >>
>>  >> --
>>  >> View this message in context:
>>  >> 
> http://openejb.979440.n4.nabble.com/Hibernate-Vs-OpenJPA-tp4665234.html
>>  >> Sent from the OpenEJB User mailing list archive at Nabble.com.
>>  >>
>> 
>> 
>>  Romain Manni-Bucau wrote
>>  > Hi
>>  >
>>  > i answered inline
>>  >
>>  > *Romain Manni-Bucau*
>>  > *Twitter: @rmannibucau &lt;https://twitter.com/rmannibucau>*
>>  > *Blog:
>>  > **
>>  http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
>>  ;
>>  > *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
>>  > *Github: https://github.com/rmannibucau*
>>  >
>>  >
>>  >
>>  > 2013/9/24 mauro2java2011 &lt;
>> 
>>  > mauro2java2011@
>> 
>>  > &gt;
>>  >
>>  >> I know that OpenJPA weaving entity statically or dinamitically 
> with a
>>  >> java
>>  >> agent true ??????
>>  >>
>>  >>
>>  >> I make 3 ask :
>>  >>
>>  >> 1) HIbernate not weave the entities???
>>  >> OR what mechanosme it use ????
>>  >>
>>  >
>>  > nothing or weaving too (to support blobs for instance or some lazy
>>  loading
>>  > on 1-1 IIRC)
>>  >
>>  >
>>  >>
>>  >> 2) If i use a project client that make call remote at a tomee
>>  application
>>  >> and i get entities like value return of EJb methods , i have to 
> have
>>  into
>>  >> classpath of client the entities weave.
>>  >> SO how i can get statically the entities at build time with 
> netbeans ?
>>  >> for
>>  >> incluede it int othe client project .
>>  >>
>>  >
>>  > using DTO avoids it otherwise yes cause of serialization mecanisms, on
>>  > trunk you can use another serializer than java default mecanism so it
>>  > would
>>  > solve it
>>  >
>>  >
>>  >>
>>  >> 3) With hibernate is not  mandatory  weaving entity ? SO i can 
> compile
>>  >> without weaving entity for place into the classpath of client ?
>>  >>
>>  >>
>>  >>
>>  > same with openjpa using the javaagent (openejb-javaagent)
>>  >
>>  >
>>  >>
>>  >>
>>  >>
>>  >> --
>>  >> View this message in context:
>>  >> 
> http://openejb.979440.n4.nabble.com/Hibernate-Vs-OpenJPA-tp4665234.html
>>  >> Sent from the OpenEJB User mailing list archive at Nabble.com.
>>  >>
>> 
>> 
>> 
>> 
>> 
>>  --
>>  View this message in context:
>> 
> http://openejb.979440.n4.nabble.com/Hibernate-Vs-OpenJPA-tp4665234p4665240.html
>>  Sent from the OpenEJB User mailing list archive at Nabble.com.
>> 
> 

Mime
View raw message