Two app servers, WAR and EJB - Weblogic

This is a discussion on Two app servers, WAR and EJB - Weblogic ; Hello gurus There are 2 app servers (on different machines!), one with deployed EJB and another - with deployed WAR. WAR contains EJB client JAR (interfaces, you know, and other objects mentioned in signatures). In a servlet (in WAR), trying ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Two app servers, WAR and EJB

  1. Two app servers, WAR and EJB

    Hello gurus

    There are 2 app servers (on different machines!), one with deployed
    EJB and another - with deployed WAR. WAR contains EJB client JAR
    (interfaces, you know, and other objects mentioned in signatures). In
    a servlet (in WAR), trying to narrow MyEJBHome remote reference to
    actual MyEJBHome we get ClassCastException - because it uses local
    MyEJBHome interface (packed in WAR and loaded by WAR class loader),
    but remote MyEJBHome stub refers to remote MyEJBHome interface (loaded
    by RMI class loader). Is there any way around this?

    TIA,

    Sergey

  2. Re: Two app servers, WAR and EJB

    Hi Segey,

    Locals can be used to access EJBs only within the same
    appilcation - ejb-jar or EAR, so local is not going to work
    in your case.

    The solution to this problem is to make the EJB remote
    or package remote interfaces in the war.

    Regards,

    Slava Imeshev

    "Sergey V. Udaltsov" wrote in message
    news:6b2b18a6.0308060445.33026af3@posting.google.c om...
    > Hello gurus
    >
    > There are 2 app servers (on different machines!), one with deployed
    > EJB and another - with deployed WAR. WAR contains EJB client JAR
    > (interfaces, you know, and other objects mentioned in signatures). In
    > a servlet (in WAR), trying to narrow MyEJBHome remote reference to
    > actual MyEJBHome we get ClassCastException - because it uses local
    > MyEJBHome interface (packed in WAR and loaded by WAR class loader),
    > but remote MyEJBHome stub refers to remote MyEJBHome interface (loaded
    > by RMI class loader). Is there any way around this?
    >
    > TIA,
    >
    > Sergey




+ Reply to Thread