Page 3 of 3 FirstFirst 123
Results 21 to 25 of 25

Thread: Spring2 + EJB3 + JBoss405

  1. #21
    Join Date
    Jul 2005
    Location
    Nice, France
    Posts
    24

    Default

    Quote Originally Posted by dejanp View Post
    Classloading issues with local ejbs are an old, long and sad story. What it boils down to is that you have 2 classloaders for your local interface and you cannot assign instance created in one classloader to a variable in other classloader. (Classes in different classloaders can never be the same class, no matter if they have the same qname or not - that's exactly why we have different classloaders)

    Usually there is an option in your app server to turn off the local interface pass-by-ref optimization and use pass-by-value. (Let's ignore the fact that app server is fully aware of all the classloaders it created and could do this on it's own, if needed)
    Good catch! Would you know how to switch to "pass-by-value" on JBoss 4.x?

  2. #22
    Join Date
    Jan 2008
    Posts
    4

    Default

    Quote Originally Posted by tiago182 View Post
    Good catch! Would you know how to switch to "pass-by-value" on JBoss 4.x?
    Tiago,

    I'm still playing with this issue myself, but I think the answer probably lies in this Wiki entry on JBoss classloading:

    http://wiki.jboss.org/wiki/Wiki.jsp?...gConfiguration

    Glad I found that to better understand how classloading works in JBoss/EAR's/EJB's, as well as had dejanp reply and send me down that path.. hopefully I'm finally about to get this thing working...

  3. #23
    Join Date
    Jan 2008
    Posts
    4

    Default

    Changing the ear-deployer.xml file worked for me! I'm going to try and create EJB configs to accomplish the same thing however so I don't have to have this file changed in all of the various dev/qa/prod JBoss env's however.

  4. #24
    Join Date
    Jul 2005
    Location
    Nice, France
    Posts
    24

    Thumbs up

    Quote Originally Posted by devnulled View Post
    Changing the ear-deployer.xml file worked for me! I'm going to try and create EJB configs to accomplish the same thing however so I don't have to have this file changed in all of the various dev/qa/prod JBoss env's however.
    Great! I'll follow your path and I'll try this solution as well on the evening after work. Cheers!

  5. #25
    Join Date
    Jan 2008
    Posts
    8

    Default

    Hi tiago182,

    Let us know if you have found a solution to the prob by changing jboss xml file.

    Cheers!
    CK

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •