• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Servlet As EJB Client

 
Ranch Hand
Posts: 327
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How should a servlet be packaged and what, if anything, should be included in its manifest if it is to be a client of an ejb that is deployed separately so that the servlet's application will not need to be redeployed if changes are made to the ejb and it is redeployed? Please help. Thanks.
 
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
//How should a servlet be packaged
However you'd like it to be - in a jar, in a war, as part of an ear or just as unpackaged class files. It's entirely up to you. You don't need anything in the manifest.
Assuming your ejb is in a seperate application (its normal to deploy the client as a war and the ejb layer seperately as whatever suits) all the servlet need do is lookup a reference to the ejb to use it. You can redeploy the ejb to your heart's content without having to redeploy the servlet.
 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think you should also add a reference to your EJB in your web.xml descriptor with the help of the <ejb-ref></ejb-ref>tag.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic