RE: [JBoss-dev] client libraries on EJB3

2006-02-14 Thread Kabir Khan
The hibernate-client.jar is being created by the ejb3 build, but should
really be done by hibernate.

Can you send me or let me know where the testcase is, so I can update the
files that go in there?
 

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Clebert Suconic
> Sent: 14 February 2006 19:10
> To: jboss-development@lists.sourceforge.net
> Subject: [JBoss-dev] client libraries on EJB3
> 
> 
> If you write an EJB3 remote application application, it's 
> very likely you will have to add cglib, asm and hibernate3 to 
> the classpath of your application.
> 
> I don't know if we already had a discussion about this, but 
> shouldn't these jars be under /client in our distribution.
> 
> I know we have hibernate-client.jar, but in case an 
> application uses lazy attributes it will be required cg-lib, 
> asm and hibernate.proxy, and these classes are not available 
> at hibernate-client.jar. I guess I realized this because I 
> just wrote an ejb3 testcase for lazy attributes and had to 
> add these jars in order to have it working.
> 
> 
> Clebert
> 
> 
> ---
> This SF.net email is sponsored by: Splunk Inc. Do you grep 
> through log files for problems?  Stop!  Download the new AJAX 
> search engine that makes searching your log files as easy as 
> surfing the  web.  DOWNLOAD SPLUNK!
> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
> ___
> JBoss-Development mailing list
> JBoss-Development@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jboss-development
> 



---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-14 Thread Clebert Suconic
Look at this issue, on CVS history:

http://jira.jboss.com/jira/browse/EJBTHREE-440?page=vcs

I had to change build.xml to add the libraries on the client-path for
ejb3 testsuite.

I have added the test on Branch-4.0.

Meanshile, take a look at this user's thread. It's quite interesting.
http://www.jboss.com/index.html?module=bb&op=viewtopic&t=76737&postdays=
0&postorder=asc&start=20

When you have a Lazy attribute over inheritance you can get a proxy
serialization problem over CGLib.

The testcase I created is the testcase created by the user but removing
everything was not causing the issue. Only left the inheritance and Lazy
ManyToOne attribute.


EJBTHREE-440 also has a comment in how to replicate it.


Clebert

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Kabir Khan
Sent: Tuesday, February 14, 2006 12:22 PM
To: jboss-development@lists.sourceforge.net
Subject: RE: [JBoss-dev] client libraries on EJB3

The hibernate-client.jar is being created by the ejb3 build, but should
really be done by hibernate.

Can you send me or let me know where the testcase is, so I can update
the
files that go in there?
 

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Clebert Suconic
> Sent: 14 February 2006 19:10
> To: jboss-development@lists.sourceforge.net
> Subject: [JBoss-dev] client libraries on EJB3
> 
> 
> If you write an EJB3 remote application application, it's 
> very likely you will have to add cglib, asm and hibernate3 to 
> the classpath of your application.
> 
> I don't know if we already had a discussion about this, but 
> shouldn't these jars be under /client in our distribution.
> 
> I know we have hibernate-client.jar, but in case an 
> application uses lazy attributes it will be required cg-lib, 
> asm and hibernate.proxy, and these classes are not available 
> at hibernate-client.jar. I guess I realized this because I 
> just wrote an ejb3 testcase for lazy attributes and had to 
> add these jars in order to have it working.
> 
> 
> Clebert
> 
> 
> ---
> This SF.net email is sponsored by: Splunk Inc. Do you grep 
> through log files for problems?  Stop!  Download the new AJAX 
> search engine that makes searching your log files as easy as 
> surfing the  web.  DOWNLOAD SPLUNK!
> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
> ___
> JBoss-Development mailing list
> JBoss-Development@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jboss-development
> 



---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log
files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Kabir Khan
I've added the required files to hibernate-client.jar, and updated the build
to use hibernate3.jar for just the "entity" test. I've not had a stab at
looking at the real problem though.

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Clebert Suconic
> Sent: 14 February 2006 21:09
> To: jboss-development@lists.sourceforge.net
> Subject: RE: [JBoss-dev] client libraries on EJB3
> 
> Look at this issue, on CVS history:
> 
> http://jira.jboss.com/jira/browse/EJBTHREE-440?page=vcs
> 
> I had to change build.xml to add the libraries on the client-path for
> ejb3 testsuite.
> 
> I have added the test on Branch-4.0.
> 
> Meanshile, take a look at this user's thread. It's quite interesting.
> http://www.jboss.com/index.html?module=bb&op=viewtopic&t=76737
> &postdays=
> 0&postorder=asc&start=20
> 
> When you have a Lazy attribute over inheritance you can get a 
> proxy serialization problem over CGLib.
> 
> The testcase I created is the testcase created by the user 
> but removing everything was not causing the issue. Only left 
> the inheritance and Lazy ManyToOne attribute.
> 
> 
> EJBTHREE-440 also has a comment in how to replicate it.
> 
> 
> Clebert
> 
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Kabir Khan
> Sent: Tuesday, February 14, 2006 12:22 PM
> To: jboss-development@lists.sourceforge.net
> Subject: RE: [JBoss-dev] client libraries on EJB3
> 
> The hibernate-client.jar is being created by the ejb3 build, 
> but should really be done by hibernate.
> 
> Can you send me or let me know where the testcase is, so I 
> can update the files that go in there?
>  
> 
> > -Original Message-
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] On Behalf Of 
> > Clebert Suconic
> > Sent: 14 February 2006 19:10
> > To: jboss-development@lists.sourceforge.net
> > Subject: [JBoss-dev] client libraries on EJB3
> > 
> > 
> > If you write an EJB3 remote application application, it's 
> very likely 
> > you will have to add cglib, asm and hibernate3 to the classpath of 
> > your application.
> > 
> > I don't know if we already had a discussion about this, but 
> shouldn't 
> > these jars be under /client in our distribution.
> > 
> > I know we have hibernate-client.jar, but in case an 
> application uses 
> > lazy attributes it will be required cg-lib, asm and 
> hibernate.proxy, 
> > and these classes are not available at 
> hibernate-client.jar. I guess I 
> > realized this because I just wrote an ejb3 testcase for lazy 
> > attributes and had to add these jars in order to have it working.
> > 
> > 
> > Clebert
> > 
> > 
> > ---
> > This SF.net email is sponsored by: Splunk Inc. Do you grep 
> > through log files for problems?  Stop!  Download the new AJAX 
> > search engine that makes searching your log files as easy as 
> > surfing the  web.  DOWNLOAD SPLUNK!
> > http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
> > ___
> > JBoss-Development mailing list
> > JBoss-Development@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/jboss-development
> > 
> 
> 
> 
> ---
> This SF.net email is sponsored by: Splunk Inc. Do you grep through log
> files
> for problems?  Stop!  Download the new AJAX search engine that makes
> searching your log files as easy as surfing the  web.  
> DOWNLOAD SPLUNK!
> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
> ___
> JBoss-Development mailing list
> JBoss-Development@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jboss-development
> 
> 
> ---
> This SF.net email is sponsored by: Splunk Inc. Do you grep 
> through log files
> for problems?  Stop!  Download the new AJAX search engine that makes
> searching your log files as easy as surfing the  web.  
> DOWNLOAD SPLUNK!
> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
> ___
> JBoss-Development mailing list
> JBoss-Development@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jboss-development
> 



---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


Re: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Heiko W. Rupp
On Tue, Feb 14, 2006 at 12:09:59PM -0600, Clebert Suconic wrote:
> 
> If you write an EJB3 remote application application, it's very likely
> you will have to add cglib, asm and hibernate3 to the classpath of your
> application.

This sounds extremely fat. Can this be reduced to the absolutely
needed clases please?

-- 
Heiko W.Rupp  http://www.pilhuhn.de/hwr/ http://mcntp.sf.net/

JBoss Buch: http://www.dpunkt.de/buch/3-89864-318-2.html



signature.asc
Description: Digital signature


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Clebert Suconic
IMO we need to add the whole asm, cglib and hibernate.proxy into
hibernate3-client.
These packages are required on any lazy relationship.


Clebert
 
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Heiko W. Rupp
Sent: Wednesday, February 15, 2006 2:36 PM
To: jboss-development@lists.sourceforge.net
Subject: Re: [JBoss-dev] client libraries on EJB3

On Tue, Feb 14, 2006 at 12:09:59PM -0600, Clebert Suconic wrote:
> 
> If you write an EJB3 remote application application, it's very likely
> you will have to add cglib, asm and hibernate3 to the classpath of
your
> application.

This sounds extremely fat. Can this be reduced to the absolutely
needed clases please?

-- 
Heiko W.Rupp  http://www.pilhuhn.de/hwr/ http://mcntp.sf.net/

JBoss Buch: http://www.dpunkt.de/buch/3-89864-318-2.html



---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Scott M Stark
Huh? We are propagating relationships across jvm boundaries? That does
not make sense.

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Clebert Suconic
> Sent: Wednesday, February 15, 2006 1:22 PM
> To: jboss-development@lists.sourceforge.net
> Subject: RE: [JBoss-dev] client libraries on EJB3
> 
> IMO we need to add the whole asm, cglib and hibernate.proxy 
> into hibernate3-client.
> These packages are required on any lazy relationship.
> 
> 
> Clebert


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


Re: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Bill Burke
Unloaded relationships throw a lazy-loaded exception if accessed after 
the entity is detached.


Scott M Stark wrote:

Huh? We are propagating relationships across jvm boundaries? That does
not make sense.



-Original Message-
From: [EMAIL PROTECTED] 
[mailto:[EMAIL PROTECTED] On 
Behalf Of Clebert Suconic

Sent: Wednesday, February 15, 2006 1:22 PM
To: jboss-development@lists.sourceforge.net
Subject: RE: [JBoss-dev] client libraries on EJB3

IMO we need to add the whole asm, cglib and hibernate.proxy 
into hibernate3-client.

These packages are required on any lazy relationship.


Clebert




---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development



--
Bill Burke
Chief Architect
JBoss Inc.


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Clebert Suconic
Title: Re: [JBoss-dev] client libraries on EJB3






we are not propagating 
relationships across JVM boundaries.
 
But if you have a lazy relationship, you 
need CGLIB and ASM on the client side.
 
So, if you don't have CGLib, ASM and 
Hibernate and using a lazy relationship you will get a ClassNotFoundException 
when deserializing the POJO on the client side.
 
My point was should we add these libraries 
to /client, or should we add the classes to hibernate-client.jar?
 


From: 
[EMAIL PROTECTED] on behalf of Bill 
BurkeSent: Wed 2/15/2006 5:34 PMTo: 
jboss-development@lists.sourceforge.netSubject: Re: [JBoss-dev] 
client libraries on EJB3

Unloaded relationships throw a lazy-loaded exception if accessed 
afterthe entity is detached.Scott M Stark wrote:> Huh? We are 
propagating relationships across jvm boundaries? That does> not make 
sense.>>>>-Original Message->>From: 
[EMAIL PROTECTED]>>[mailto:[EMAIL PROTECTED]] 
On>>Behalf Of Clebert Suconic>>Sent: Wednesday, February 15, 
2006 1:22 PM>>To: 
jboss-development@lists.sourceforge.net>>Subject: RE: [JBoss-dev] 
client libraries on EJB3>>>>IMO we need to add the whole 
asm, cglib and hibernate.proxy>>into 
hibernate3-client.>>These packages are required on any lazy 
relationship.>>>>>>Clebert>>>> 
---> This SF.net 
email is sponsored by: Splunk Inc. Do you grep through log files> for 
problems?  Stop!  Download the new AJAX search engine that 
makes> searching your log files as easy as surfing the  web.  
DOWNLOAD SPLUNK!> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642> 
___> JBoss-Development 
mailing list> JBoss-Development@lists.sourceforge.net> https://lists.sourceforge.net/lists/listinfo/jboss-development>--Bill 
BurkeChief ArchitectJBoss 
Inc.---This 
SF.net email is sponsored by: Splunk Inc. Do you grep through log filesfor 
problems?  Stop!  Download the new AJAX search engine that 
makessearching your log files as easy as surfing the  web.  
DOWNLOAD SPLUNK!http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642___JBoss-Development 
mailing listJBoss-Development@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/jboss-development




RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Scott M Stark
Title: Re: [JBoss-dev] client libraries on EJB3



Can this enhanced proxy be replaced during 
serialization to avoid this? If these classes cannot be used in a functional 
manner by a client, they should not be exposed to the client. Just replace the 
proxy with a wrapper around the lazy load exception.

  
  
  From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  Clebert SuconicSent: Wednesday, February 15, 2006 4:31 
  PMTo: jboss-development@lists.sourceforge.net; 
  jboss-development@lists.sourceforge.netSubject: RE: [JBoss-dev] 
  client libraries on EJB3
  
  
  we are not propagating 
  relationships across JVM boundaries.
   
  But if you have a lazy relationship, you 
  need CGLIB and ASM on the client side.
   
  So, if you don't have CGLib, ASM and 
  Hibernate and using a lazy relationship you will get a ClassNotFoundException 
  when deserializing the POJO on the client side.
   
  My point was should we add these 
  libraries to /client, or should we add the classes to 
  hibernate-client.jar?
   
  
  
  From: 
  [EMAIL PROTECTED] on behalf of Bill 
  BurkeSent: Wed 2/15/2006 5:34 PMTo: 
  jboss-development@lists.sourceforge.netSubject: Re: [JBoss-dev] 
  client libraries on EJB3
  
  Unloaded relationships throw a lazy-loaded exception if 
  accessed afterthe entity is detached.Scott M Stark wrote:> 
  Huh? We are propagating relationships across jvm boundaries? That does> 
  not make sense.>>>>-Original 
  Message->>From: 
  [EMAIL PROTECTED]>>[mailto:[EMAIL PROTECTED]] 
  On>>Behalf Of Clebert Suconic>>Sent: Wednesday, February 
  15, 2006 1:22 PM>>To: 
  jboss-development@lists.sourceforge.net>>Subject: RE: [JBoss-dev] 
  client libraries on EJB3>>>>IMO we need to add the whole 
  asm, cglib and hibernate.proxy>>into 
  hibernate3-client.>>These packages are required on any lazy 
  relationship.>>>>>>Clebert>>>> 
  ---> This SF.net 
  email is sponsored by: Splunk Inc. Do you grep through log files> for 
  problems?  Stop!  Download the new AJAX search engine that 
  makes> searching your log files as easy as surfing the  web.  
  DOWNLOAD SPLUNK!> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642> 
  ___> JBoss-Development 
  mailing list> JBoss-Development@lists.sourceforge.net> https://lists.sourceforge.net/lists/listinfo/jboss-development>--Bill 
  BurkeChief ArchitectJBoss 
  Inc.---This 
  SF.net email is sponsored by: Splunk Inc. Do you grep through log filesfor 
  problems?  Stop!  Download the new AJAX search engine that 
  makessearching your log files as easy as surfing the  web.  
  DOWNLOAD SPLUNK!http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642___JBoss-Development 
  mailing listJBoss-Development@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Clebert Suconic
Title: Re: [JBoss-dev] client libraries on EJB3





Well...
I'm not sure what would happen if the lazy 
relationship is filled. 
I guess you would get the 
ClassNotFoundException on any Lazy Relationship if hibernate.proxy is not 
availble. Bill? Kabir?
I only tested without activating a Lazy 
Relationships.


From: 
[EMAIL PROTECTED] on behalf of Scott M 
StarkSent: Wed 2/15/2006 7:12 PMTo: 
jboss-development@lists.sourceforge.netSubject: RE: [JBoss-dev] 
client libraries on EJB3

Can this enhanced proxy be replaced during 
serialization to avoid this? If these classes cannot be used in a functional 
manner by a client, they should not be exposed to the client. Just replace the 
proxy with a wrapper around the lazy load exception.

  
  
  From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  Clebert SuconicSent: Wednesday, February 15, 2006 4:31 
  PMTo: jboss-development@lists.sourceforge.net; 
  jboss-development@lists.sourceforge.netSubject: RE: [JBoss-dev] 
  client libraries on EJB3
  
  
  we are not propagating 
  relationships across JVM boundaries.
   
  But if you have a lazy relationship, you 
  need CGLIB and ASM on the client side.
   
  So, if you don't have CGLib, ASM and 
  Hibernate and using a lazy relationship you will get a ClassNotFoundException 
  when deserializing the POJO on the client side.
   
  My point was should we add these 
  libraries to /client, or should we add the classes to 
  hibernate-client.jar?
   
  
  
  From: 
  [EMAIL PROTECTED] on behalf of Bill 
  BurkeSent: Wed 2/15/2006 5:34 PMTo: 
  jboss-development@lists.sourceforge.netSubject: Re: [JBoss-dev] 
  client libraries on EJB3
  
  Unloaded relationships throw a lazy-loaded exception if 
  accessed afterthe entity is detached.Scott M Stark wrote:> 
  Huh? We are propagating relationships across jvm boundaries? That does> 
  not make sense.>>>>-Original 
  Message->>From: 
  [EMAIL PROTECTED]>>[mailto:[EMAIL PROTECTED]] 
  On>>Behalf Of Clebert Suconic>>Sent: Wednesday, February 
  15, 2006 1:22 PM>>To: 
  jboss-development@lists.sourceforge.net>>Subject: RE: [JBoss-dev] 
  client libraries on EJB3>>>>IMO we need to add the whole 
  asm, cglib and hibernate.proxy>>into 
  hibernate3-client.>>These packages are required on any lazy 
  relationship.>>>>>>Clebert>>>> 
  ---> This SF.net 
  email is sponsored by: Splunk Inc. Do you grep through log files> for 
  problems?  Stop!  Download the new AJAX search engine that 
  makes> searching your log files as easy as surfing the  web.  
  DOWNLOAD SPLUNK!> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&bid#0486&dat1642> 
  ___> JBoss-Development 
  mailing list> JBoss-Development@lists.sourceforge.net> https://lists.sourceforge.net/lists/listinfo/jboss-development>--Bill 
  BurkeChief ArchitectJBoss 
  Inc.---This 
  SF.net email is sponsored by: Splunk Inc. Do you grep through log filesfor 
  problems?  Stop!  Download the new AJAX search engine that 
  makessearching your log files as easy as surfing the  web.  
  DOWNLOAD SPLUNK!http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642___JBoss-Development 
  mailing listJBoss-Development@lists.sourceforge.nethttps://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Scott M Stark
Title: Re: [JBoss-dev] client libraries on EJB3



I'm asking if we can replace the proxy with one that throws 
the lazy loading exception on any method access without leaking dependencies on 
the proxy related classes.

  
  
  From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  Clebert SuconicSent: Wednesday, February 15, 2006 5:16 
  PMTo: jboss-development@lists.sourceforge.net; 
  jboss-development@lists.sourceforge.netSubject: RE: [JBoss-dev] 
  client libraries on EJB3
  
  
  Well...
  I'm not sure what would happen if the 
  lazy relationship is filled. 
  I guess you would get the 
  ClassNotFoundException on any Lazy Relationship if hibernate.proxy is not 
  availble. Bill? Kabir?
  I only tested without activating a Lazy 
  Relationships.
   


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Clebert Suconic
Title: Re: [JBoss-dev] client libraries on EJB3





we will need a proxy 
framework anyways, right?
 
if we replace cglib by something else (aop, 
javassist maybe) I guess it would be the same on that point, and besides it 
would require some work.
 


From: 
[EMAIL PROTECTED] on behalf of Scott M 
StarkSent: Wed 2/15/2006 7:22 PMTo: 
jboss-development@lists.sourceforge.netSubject: RE: [JBoss-dev] 
client libraries on EJB3

I'm asking if we can replace the proxy with one that throws 
the lazy loading exception on any method access without leaking dependencies on 
the proxy related classes.

  
  
  From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  Clebert SuconicSent: Wednesday, February 15, 2006 5:16 
  PMTo: jboss-development@lists.sourceforge.net; 
  jboss-development@lists.sourceforge.netSubject: RE: [JBoss-dev] 
  client libraries on EJB3
  
  
  Well...
  I'm not sure what would happen if the 
  lazy relationship is filled. 
  I guess you would get the 
  ClassNotFoundException on any Lazy Relationship if hibernate.proxy is not 
  availble. Bill? Kabir?
  I only tested without activating a Lazy 
  Relationships.
   


RE: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Scott M Stark
Title: Re: [JBoss-dev] client libraries on EJB3



For the remote proxies and associated aspects yes, but 
I don't want proxy stuff leaking for no good reason. A proxy that can only be 
used to cause an exception to be thrown is not a good reason to introduce a new 
library dependency on the client. If this was already javassist I would not have 
a problem since we likely want an aop container on the client. Leaking asm/cglib 
is not something I want to have to do.

  
  
  From: 
  [EMAIL PROTECTED] 
  [mailto:[EMAIL PROTECTED] On Behalf Of 
  Clebert SuconicSent: Wednesday, February 15, 2006 5:41 
  PMTo: jboss-development@lists.sourceforge.net; 
  jboss-development@lists.sourceforge.netSubject: RE: [JBoss-dev] 
  client libraries on EJB3
  
  
  we will need a proxy 
  framework anyways, right?
   
  if we replace cglib by something else 
  (aop, javassist maybe) I guess it would be the same on that point, and besides 
  it would require some work.
   
   


Re: [JBoss-dev] client libraries on EJB3

2006-02-15 Thread Max Rydahl Andersen

Hi guys,

Just bumping in here to tell the "whole" story about the needed  
dependencies.


Here are the reasons for ever neededing any hibernate specific stuff on a  
"client" side:


1. Managing persistent collections
   To track how a collection mutates so when the object comes back to the  
server

   hibernate can be more efficient when detecting and executing changes.

2. Handle lazy loaded objects
   If lazy="true" on a class (it is by default) the object can be a simple  
proxied
   shell only containing the id. This allows us to use the object in  
associations
   without loading it (e.g. child.setParent(proxiedParent);) and to throw  
an exception
   if it is accessed without being previously loaded or in a session (e.g.  
proxiedParent.getName() goes boom)


#1 does not require proxy libraries AFAIK but I have not tested it.

#2 requires the proxy libraries (in 3.2 either javaassist or cglib), I  
don't know if it is feasible
   to generate something that is not dependent on the proxy library and  
still be able to reassociate it

   when it comes back to the server.

These are important issues that should be handled in Hibernate 3.2 if at  
all possible. (cc'ed steve)


/max


For the remote proxies and associated aspects yes, but I don't want
proxy stuff leaking for no good reason. A proxy that can only be used to
cause an exception to be thrown is not a good reason to introduce a new
library dependency on the client. If this was already javassist I would
not have a problem since we likely want an aop container on the client.
Leaking asm/cglib is not something I want to have to do.




From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Clebert Suconic
Sent: Wednesday, February 15, 2006 5:41 PM
To: jboss-development@lists.sourceforge.net;
jboss-development@lists.sourceforge.net
    Subject: RE: [JBoss-dev] client libraries on EJB3


we will need a proxy framework anyways, right?

if we replace cglib by something else (aop, javassist maybe) I
guess it would be the same on that point, and besides it would require
some work.







--
--
Max Rydahl Andersen
callto://max.rydahl.andersen

Hibernate
[EMAIL PROTECTED]
http://hibernate.org

JBoss Inc
[EMAIL PROTECTED]


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-16 Thread Scott M Stark
But here we are talking about what exists after the object in question
has been serialized outside of the jvm. Does what your talking about
still apply in that situation? Regardless, I think this discussion just
further pushes for a unified javassist based proxy framework sometime
before ejb3 is finalized. 

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Max Rydahl Andersen
> Sent: Wednesday, February 15, 2006 11:56 PM
> To: jboss-development@lists.sourceforge.net
> Cc: Steve Ebersole
> Subject: Re: [JBoss-dev] client libraries on EJB3
> 
> Hi guys,
> 
> Just bumping in here to tell the "whole" story about the 
> needed dependencies.
> 
> Here are the reasons for ever neededing any hibernate 
> specific stuff on a "client" side:
> 
> 1. Managing persistent collections
> To track how a collection mutates so when the object 
> comes back to the server
> hibernate can be more efficient when detecting and 
> executing changes.
> 
> 2. Handle lazy loaded objects
> If lazy="true" on a class (it is by default) the object 
> can be a simple proxied
> shell only containing the id. This allows us to use the 
> object in associations
> without loading it (e.g. child.setParent(proxiedParent);) 
> and to throw an exception
> if it is accessed without being previously loaded or in a 
> session (e.g.  
> proxiedParent.getName() goes boom)
> 
> #1 does not require proxy libraries AFAIK but I have not tested it.
> 
> #2 requires the proxy libraries (in 3.2 either javaassist or 
> cglib), I don't know if it is feasible
> to generate something that is not dependent on the proxy 
> library and still be able to reassociate it
> when it comes back to the server.
> 
> These are important issues that should be handled in 
> Hibernate 3.2 if at all possible. (cc'ed steve)
> 
> /max


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


Re: [JBoss-dev] client libraries on EJB3

2006-02-16 Thread Max Rydahl Andersen
On Thu, 16 Feb 2006 10:29:46 +0100, Adrian Brock <[EMAIL PROTECTED]>  
wrote:



On Thu, 2006-02-16 at 03:26, Max Rydahl Andersen wrote:

> Regardless, I think this discussion just
> further pushes for a unified javassist based proxy framework sometime
> before ejb3 is finalized.


Hibernate 3.2 is fully working on javaassist now so that is good ;)

Doesn't jboss have client side aop based interceptors running ?
Do they work without the proxy framework (javaassist.jar) ?


The way AOP Remoting solves this issue (no proxy framework on the
client) is to use remote classloading on the client to download the
generated classes.

JBoss Remoting has a notion of remote classloading that does
not require all the baggage of the RMI solution, like opening an http
port to make the class downloadable.
It simply requests the class over the transport you are already using.


Can this remote classloading be done transaparently for ejb3/hibernate  
related

classes when running in "ejb3-clientmode" ?

--
--
Max Rydahl Andersen
callto://max.rydahl.andersen

Hibernate
[EMAIL PROTECTED]
http://hibernate.org

JBoss Inc
[EMAIL PROTECTED]


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


Re: [JBoss-dev] client libraries on EJB3

2006-02-16 Thread Adrian Brock
On Thu, 2006-02-16 at 04:37, Max Rydahl Andersen wrote:
> > JBoss Remoting has a notion of remote classloading that does
> > not require all the baggage of the RMI solution, like opening an http
> > port to make the class downloadable.
> > It simply requests the class over the transport you are already using.
> 
> Can this remote classloading be done transaparently for ejb3/hibernate  
> related
> classes when running in "ejb3-clientmode" ?

You'd have to ask Bill/Tom. JBoss Remoting has two layers
where you can plugin your own processing.
1) The low level marshalling
2) Component specific behaviour in the "subsystem" handling.
-- 
 
Adrian Brock
Chief Scientist
JBoss Inc.
 



---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


Re: [JBoss-dev] client libraries on EJB3

2006-02-16 Thread Adrian Brock
On Thu, 2006-02-16 at 03:26, Max Rydahl Andersen wrote:
> > Regardless, I think this discussion just
> > further pushes for a unified javassist based proxy framework sometime
> > before ejb3 is finalized.
> 
> 
> Hibernate 3.2 is fully working on javaassist now so that is good ;)
> 
> Doesn't jboss have client side aop based interceptors running ?
> Do they work without the proxy framework (javaassist.jar) ?

The way AOP Remoting solves this issue (no proxy framework on the
client) is to use remote classloading on the client to download the
generated classes.

JBoss Remoting has a notion of remote classloading that does
not require all the baggage of the RMI solution, like opening an http
port to make the class downloadable.
It simply requests the class over the transport you are already using.

-- 
 
Adrian Brock
Chief Scientist
JBoss Inc.
 



---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


Re: [JBoss-dev] client libraries on EJB3

2006-02-16 Thread Max Rydahl Andersen
On Thu, 16 Feb 2006 09:07:49 +0100, Scott M Stark <[EMAIL PROTECTED]>  
wrote:



But here we are talking about what exists after the object in question
has been serialized outside of the jvm. Does what your talking about
still apply in that situation?


If I understand your question correctly, then yes and maybe no ;)

yes, in the case of hibernate because the serialized object is detached and
thus can be sent back to the client for the purpose of being  
reattached/made persistent again,
here the PersistentCollection and proxied objects with its internal id is  
relevant.


maybe no, because EJB3 does not seem to have the possibility to reattach,  
it only
supports merge. But that still makes it required/needed that a lazy object  
can be represented
as something that looks and feels like an object (e.g. for  
child.setParent(proxiedParent) and to get

an exception for proxiedParent.getName())


Regardless, I think this discussion just
further pushes for a unified javassist based proxy framework sometime
before ejb3 is finalized.



Hibernate 3.2 is fully working on javaassist now so that is good ;)

Doesn't jboss have client side aop based interceptors running ?
Do they work without the proxy framework (javaassist.jar) ?

/max




-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On
Behalf Of Max Rydahl Andersen
Sent: Wednesday, February 15, 2006 11:56 PM
To: jboss-development@lists.sourceforge.net
Cc: Steve Ebersole
Subject: Re: [JBoss-dev] client libraries on EJB3

Hi guys,

Just bumping in here to tell the "whole" story about the
needed dependencies.

Here are the reasons for ever neededing any hibernate
specific stuff on a "client" side:

1. Managing persistent collections
To track how a collection mutates so when the object
comes back to the server
hibernate can be more efficient when detecting and
executing changes.

2. Handle lazy loaded objects
If lazy="true" on a class (it is by default) the object
can be a simple proxied
shell only containing the id. This allows us to use the
object in associations
without loading it (e.g. child.setParent(proxiedParent);)
and to throw an exception
if it is accessed without being previously loaded or in a
session (e.g.
proxiedParent.getName() goes boom)

#1 does not require proxy libraries AFAIK but I have not tested it.

#2 requires the proxy libraries (in 3.2 either javaassist or
cglib), I don't know if it is feasible
to generate something that is not dependent on the proxy
library and still be able to reassociate it
when it comes back to the server.

These are important issues that should be handled in
Hibernate 3.2 if at all possible. (cc'ed steve)

/max



---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log  
files

for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development




--
--
Max Rydahl Andersen
callto://max.rydahl.andersen

Hibernate
[EMAIL PROTECTED]
http://hibernate.org

JBoss Inc
[EMAIL PROTECTED]


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-16 Thread Steve Ebersole
Well unfortunately serialization is used in two distinct scenarios that
have vastly different de-serialization needs.  The current code is
written to handle both scenarios.  

The first scenario is serialization of the Hibernate Session itself such
that when that Session is then de-serialized all the proxies are
properly re-attached and usable.  

The other scenario is serialization specifically to send across a
class-loader boundary.  Theoretically we could just replace the proxy
with some "stand-in" object that just always throws a
LazyInitializationException.  But "this thing" still needs to be typed
correctly upon de-serialization in order to fulfill this role, so not
sure how to do that without the library being used for lazy proxy
generation being available on the client-side anyway.

Hibernate 3.2 does have the ability to use Javassist as the bytecode
library instead of CGLIB.  Hibernate 3.2 is the version I am expecting
to be used in EJB3 moving forward, so there is no problem if you are
fine with requiring Javassist on the client-side...

BTW, even with collections there is a possibility to still need access
to the proxy generation library on de-serialization.  This is because it
is *possible* to have a collection containing proxies in the case of
many-to-many associations.

-Original Message-
From: Scott M Stark 
Sent: Thursday, February 16, 2006 2:08 AM
To: jboss-development@lists.sourceforge.net
Cc: Steve Ebersole
Subject: RE: [JBoss-dev] client libraries on EJB3

But here we are talking about what exists after the object in question
has been serialized outside of the jvm. Does what your talking about
still apply in that situation? Regardless, I think this discussion just
further pushes for a unified javassist based proxy framework sometime
before ejb3 is finalized. 

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Max Rydahl Andersen
> Sent: Wednesday, February 15, 2006 11:56 PM
> To: jboss-development@lists.sourceforge.net
> Cc: Steve Ebersole
> Subject: Re: [JBoss-dev] client libraries on EJB3
> 
> Hi guys,
> 
> Just bumping in here to tell the "whole" story about the 
> needed dependencies.
> 
> Here are the reasons for ever neededing any hibernate 
> specific stuff on a "client" side:
> 
> 1. Managing persistent collections
> To track how a collection mutates so when the object 
> comes back to the server
> hibernate can be more efficient when detecting and 
> executing changes.
> 
> 2. Handle lazy loaded objects
> If lazy="true" on a class (it is by default) the object 
> can be a simple proxied
> shell only containing the id. This allows us to use the 
> object in associations
> without loading it (e.g. child.setParent(proxiedParent);) 
> and to throw an exception
> if it is accessed without being previously loaded or in a 
> session (e.g.  
> proxiedParent.getName() goes boom)
> 
> #1 does not require proxy libraries AFAIK but I have not tested it.
> 
> #2 requires the proxy libraries (in 3.2 either javaassist or 
> cglib), I don't know if it is feasible
> to generate something that is not dependent on the proxy 
> library and still be able to reassociate it
> when it comes back to the server.
> 
> These are important issues that should be handled in 
> Hibernate 3.2 if at all possible. (cc'ed steve)
> 
> /max


---
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
___
JBoss-Development mailing list
JBoss-Development@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jboss-development


RE: [JBoss-dev] client libraries on EJB3

2006-02-16 Thread Scott M Stark
So I guess we need a discussion on aop proxies in general such that when
hibernate is combined with jboss ejb3/remoting/aop we know what the
behavior is and how it relates to any aop configuration that might exist
in the deserialization context.

> -Original Message-
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Steve Ebersole
> Sent: Thursday, February 16, 2006 10:10 AM
> To: jboss-development@lists.sourceforge.net
> Subject: RE: [JBoss-dev] client libraries on EJB3
> 
> Well unfortunately serialization is used in two distinct 
> scenarios that have vastly different de-serialization needs.  
> The current code is written to handle both scenarios.  
> 
> The first scenario is serialization of the Hibernate Session 
> itself such that when that Session is then de-serialized all 
> the proxies are properly re-attached and usable.  
> 
> The other scenario is serialization specifically to send 
> across a class-loader boundary.  Theoretically we could just 
> replace the proxy with some "stand-in" object that just 
> always throws a LazyInitializationException.  But "this 
> thing" still needs to be typed correctly upon 
> de-serialization in order to fulfill this role, so not sure 
> how to do that without the library being used for lazy proxy 
> generation being available on the client-side anyway.
> 
> Hibernate 3.2 does have the ability to use Javassist as the 
> bytecode library instead of CGLIB.  Hibernate 3.2 is the 
> version I am expecting to be used in EJB3 moving forward, so 
> there is no problem if you are fine with requiring Javassist 
> on the client-side...
> 
> BTW, even with collections there is a possibility to still 
> need access to the proxy generation library on 
> de-serialization.  This is because it is *possible* to have a 
> collection containing proxies in the case of many-to-many 
> associations.
> 
> -Original Message-
> From: Scott M Stark
> Sent: Thursday, February 16, 2006 2:08 AM
> To: jboss-development@lists.sourceforge.net
> Cc: Steve Ebersole
> Subject: RE: [JBoss-dev] client libraries on EJB3
> 
> But here we are talking about what exists after the object in 
> question has been serialized outside of the jvm. Does what 
> your talking about still apply in that situation? Regardless, 
> I think this discussion just further pushes for a unified 
> javassist based proxy framework sometime before ejb3 is finalized. 
> 
> > -Original Message-
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] On Behalf Of 
> > Max Rydahl Andersen
> > Sent: Wednesday, February 15, 2006 11:56 PM
> > To: jboss-development@lists.sourceforge.net
> > Cc: Steve Ebersole
> > Subject: Re: [JBoss-dev] client libraries on EJB3
> > 
> > Hi guys,
> > 
> > Just bumping in here to tell the "whole" story about the needed 
> > dependencies.
> > 
> > Here are the reasons for ever neededing any hibernate 
> specific stuff 
> > on a "client" side:
> > 
> > 1. Managing persistent collections
> > To track how a collection mutates so when the object 
> comes back to 
> > the server
> > hibernate can be more efficient when detecting and executing 
> > changes.
> > 
> > 2. Handle lazy loaded objects
> > If lazy="true" on a class (it is by default) the object 
> can be a 
> > simple proxied
> > shell only containing the id. This allows us to use the 
> object in 
> > associations
> > without loading it (e.g. 
> child.setParent(proxiedParent);) and to 
> > throw an exception
> > if it is accessed without being previously loaded or in 
> a session 
> > (e.g.
> > proxiedParent.getName() goes boom)
> > 
> > #1 does not require proxy libraries AFAIK but I have not tested it.
> > 
> > #2 requires the proxy libraries (in 3.2 either javaassist 
> or cglib), I 
> > don't know if it is feasible
> > to generate something that is not dependent on the 
> proxy library 
> > and still be able to reassociate it
> > when it comes back to the server.
> > 
> > These are important issues that should be handled in 
> Hibernate 3.2 if 
> > at all possible. (cc'ed steve)
> > 
> > /max
> 
> 
> ---
> This SF.net email is sponsored by: Splunk Inc. Do you grep 
> through log files for problems?  Stop!  Download the new AJAX 
> search engine that makes searching your log files as easy as 
> surfing the  web.  DOWNLOAD SPLUNK!
> http://sel.as-us.falkag.net/sel?cmd=k&kid3432&