Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • 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
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

separate webserver and application server

 
Ranch Hand
Posts: 98
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
iam using webserver and application servers separatly what i have to write to communicate both the servlet and ejbs? can any one of you write the small code snippets for me pls..
thanks inadvance
 
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The only difference comes in the way you lookup your EJBs. Instead of

you need to lookup the context from the remote server as follows:
 
author
Posts: 3892
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You need to be very precise here. There are two possibilities; either you separate the Web server(something like Apache or IIS) from the Application Server (which contains both the Web Container and EJB Container) or you can separate the Web Container from the EJB Container. Which do you really mean?
Kyle
[ December 20, 2003: Message edited by: Kyle Brown ]
 
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i'd suspect as the other poster did that the application server == ejb (component) container, and web server == web container.
 
eswar kumar
Ranch Hand
Posts: 98
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Actually tomcat (Servlet container) is running in one system and EJBs are running in another system which are physically separate systems
 
author
Posts: 580
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Eswar,

In your particular scenario, I'd use Spring on Tomcat to inject the remote EJB (presumably EJB 3) instances. Look into Spring support for @EJB, @Resource and the <jee:jndi-lookup> element. Otherwise, you can have OpenEJB on Tomcat do the remote injection for you, but that is a little overkill in this case since all you really need is injection and not other EJB container services.

Hope it helps,
Reza
 
It's feeding time! Give me the food you were going to give to this tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic