• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Which is faster?

 
Nirvan Sagar
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
For a given hardware size , which will be faster a J2EE application or the same application built using JSP and JAVA where the EJBs are replaced by ordinary classes.
Thanks in advance
 
Pradeep bhatt
Ranch Hand
Posts: 8927
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JSP/servlets app without app
 
Lasse Koskela
author
Sheriff
Posts: 11962
5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As a side note, servlets plus plain old Java objects are J2EE as well...
 
Prakash Dwivedi
Ranch Hand
Posts: 452
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I think it depends upon the nature of application if u have to work with large collection of data(300-400 records to 1000 records at a time). when doing this entity bean slows down ur application considerably.
where as if ur application resembles application for banking or Healthcare where application use less number of records at a time,(user will be dealing with his own records only). I think entity beans can be very helpful and increase the speed.
I am just saying from my personal experiece, and could be wrong
thanx
 
Nirvan Sagar
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Prakash Dwivedi:
Hi,
I think it depends upon the nature of application if u have to work with large collection of data(300-400 records to 1000 records at a time). when doing this entity bean slows down ur application considerably.
where as if ur application resembles application for banking or Healthcare where application use less number of records at a time,(user will be dealing with his own records only). I think entity beans can be very helpful and increase the speed.
I am just saying from my personal experiece, and could be wrong
thanx

What if I am calling stored procedures to access data from backend but using session beans to expose business logic as resuable components.
Will it be faster than if I use ordinary Javabeans (though I may not be able to expose them to outside parties)
 
Nagendra Prasad
Ranch Hand
Posts: 219
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
While all these arguments probably hold good for an application deployed over a single application server and probably not much reqmts of scalability, using EJBs makes the entire application lend itself to a distributed architecture.
So the fundamental driver should be if your application can grow into one where dist. arch. is necessary, now or in the future..
performance and scalability can be achieved with choice of technology both on s/w and h/w side.
To use EJB or not would need to be derived from an amalgamation of such considerations rather than just one or two of them.
 
siqi zhang
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Nirvan Sagar:
For a given hardware size , which will be faster a J2EE application or the same application built using JSP and JAVA where the EJBs are replaced by ordinary classes.
Thanks in advance

There are different combination for
constructing J2EE based applications:
Servlet/JSP -> JDBC (Hibernate)
Servlet/JSP -> JDO
Servlet/JSP -> EJB but stateless EJB only, or using local interface for entity beans.
Servlet/JSP -> EJB with remote interface.
EJB benefites are primarily for transaction
management and scaleability. For small scale
web applications, it is not worthy of using
EJB.
with local interface, it is said the performance
is not that bad. But no personal experience.
With EJB 1.x, entity should really be avoided.
 
James Ward
Ranch Hand
Posts: 263
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am wondering why no one has answered the question straight ...
The jsp/servlet + java classes will be faster, inspite of whatever specs etc. might say.
Where it is good for scalability etc... depends. You will not be able to make it distributed when the need arises.
The one big reasons EJBs are useful are : distributed computing (Imagine using RMI instead hell !) not performance ...
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic