WAR and EJB-JAR in Seperated Server

Discussion in 'Java' started by steven, Oct 22, 2003.

  1. steven

    steven Guest

    Hi, group

    In the sample of Sun's J2EE 1.3 tutorial, WAR and EJB-JAR are combined
    into an EAR and deployed. For some reasons, however, I have to deploy
    the EJBs part of a application into Sun's J2EE RI while deploy the
    WARs part of the same application into another server such as TomCat.
    Of course, the classes in WARs need to communicate with EJBs in J2EE
    RI.

    My questions are,

    1, Is it possible to deployee only EJBs onto the J2EE RI? In this
    case, what file form I need to creat, a EJB-JAR or a EAR in which an
    EJB-JAR is hold?

    2, Should I write a two seperated runtime descriptor, one of which in
    the WAR, another of which in the EJB-JAR?

    Thanks in advance.

    --
    Steven Woody
    steven, Oct 22, 2003
    #1
    1. Advertising

  2. "steven" <> wrote in message
    news:...
    > Hi, group
    >
    > In the sample of Sun's J2EE 1.3 tutorial, WAR and EJB-JAR are combined
    > into an EAR and deployed. For some reasons, however, I have to deploy
    > the EJBs part of a application into Sun's J2EE RI while deploy the
    > WARs part of the same application into another server such as TomCat.
    > Of course, the classes in WARs need to communicate with EJBs in J2EE
    > RI.
    >
    > My questions are,
    >
    > 1, Is it possible to deployee only EJBs onto the J2EE RI? In this
    > case, what file form I need to creat, a EJB-JAR or a EAR in which an
    > EJB-JAR is hold?


    EAR

    > 2, Should I write a two seperated runtime descriptor, one of which in
    > the WAR, another of which in the EJB-JAR?


    Deployment descriptor you mean?
    You already have web.xml for the WAR file and ejb-jar.xml for the EJB,
    and you will need 2 application.xml files, one for the EAR containing the
    WAR, another for the EAR containing the EJB.

    Most of the servers will allow you to deploy WAR or EJB without being inside
    EAR, although I believe this is against the spec.
    To compesate for the missing application.xml they will force you to add some
    server specific deployment descriptor to the WAR or EJB.
    Just for example if you deploy a WAR file by itself there is no standard way
    to specify context root - it normally comes from the application.xml.

    Regards,
    Dobromir
    Dobromir Gaydarov, Oct 25, 2003
    #2
    1. Advertising

  3. steven

    steven Guest

    Thank you!

    "Dobromir Gaydarov" <-THIS.com> wrote in message news:<>...
    > "steven" <> wrote in message
    > news:...
    > > Hi, group
    > >
    > > In the sample of Sun's J2EE 1.3 tutorial, WAR and EJB-JAR are combined
    > > into an EAR and deployed. For some reasons, however, I have to deploy
    > > the EJBs part of a application into Sun's J2EE RI while deploy the
    > > WARs part of the same application into another server such as TomCat.
    > > Of course, the classes in WARs need to communicate with EJBs in J2EE
    > > RI.
    > >
    > > My questions are,
    > >
    > > 1, Is it possible to deployee only EJBs onto the J2EE RI? In this
    > > case, what file form I need to creat, a EJB-JAR or a EAR in which an
    > > EJB-JAR is hold?

    >
    > EAR
    >
    > > 2, Should I write a two seperated runtime descriptor, one of which in
    > > the WAR, another of which in the EJB-JAR?

    >
    > Deployment descriptor you mean?
    > You already have web.xml for the WAR file and ejb-jar.xml for the EJB,
    > and you will need 2 application.xml files, one for the EAR containing the
    > WAR, another for the EAR containing the EJB.
    >
    > Most of the servers will allow you to deploy WAR or EJB without being inside
    > EAR, although I believe this is against the spec.
    > To compesate for the missing application.xml they will force you to add some
    > server specific deployment descriptor to the WAR or EJB.
    > Just for example if you deploy a WAR file by itself there is no standard way
    > to specify context root - it normally comes from the application.xml.
    >
    > Regards,
    > Dobromir
    steven, Oct 26, 2003
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Tobias Merler
    Replies:
    0
    Views:
    403
    Tobias Merler
    Oct 9, 2004
  2. Pmb
    Replies:
    2
    Views:
    375
  3. Stan R.
    Replies:
    6
    Views:
    447
    Joe Kesselman
    Jun 5, 2006
  4. gk
    Replies:
    2
    Views:
    950
  5. Raymond Schanks
    Replies:
    0
    Views:
    643
    Raymond Schanks
    Aug 3, 2010
Loading...

Share This Page