• 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

Servlets communication on different host

 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My architecture is
- Browser Tier: for client
- Web server Tier: locate on hosting service provider, run jsp and servlet.
- Application and DB server Tier: locate on my company, run main servlet and EJB.
For web server tier I use jsp and servlet to process layout,
and must communicate to the main servlet and EJB on App & DB tier on my company's server.
I don't want servlet on web server to directly call an EJB on company's server, because of firewall problem. So I need to use servlet on web server call the main servlet on company's server instead.
My problem is how these two servlets on different server to communicate? And how to manage session? I try to use HttpURLConnection for servlet on web server to communicate, but I dno't know there's another way to do like this or not...
 
Saloon Keeper
Posts: 27763
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
HttpURLConnection is fine. It's designed for that kind of thing.
 
reply
    Bookmark Topic Watch Topic
  • New Topic