• 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

Purpose or j2ee and ejb

 
Ranch Hand
Posts: 1170
Hibernate Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What purpose does j2ee server. what purpose do EJBs serve?
I just dont understand what they are supposed to offer above basic java and jdbc.
Also if one knows and feels like offering supplimentary info, what role does the app server play? why do I need one? When do I need one? etc...
Thanks!
 
Sheriff
Posts: 3063
12
Mac IntelliJ IDE Python VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That's a big question! There's no clear agreement on what exactly an app server does, but there are some basic things that most give you, and which help when developing large-scale client-server applications:
1. Transactions. Multiple database updates can be treated as one unit, so that if they don't all succeed, they are all rolled back.
2. Database pooling. You can keep a set of open connections to your database and share them among processes that need access.
3. Security. Parts of your application can be restricted to particular users, based on roles.
4. Clustering. Your application can be distributed to multiple servers, to increase availability to a large number of clients.

So if you're writing a stand-alone application, you keep using regular Java. If you are writing a simple client-server application with a browser interface, you go for Tomcat or other servlet runner. However, if you are writing a complex, mission-critical, client-server app., then an app server is the way to go.
 
reply
    Bookmark Topic Watch Topic
  • New Topic