| Author |
Which is faster?
|
Nirvan Sagar
Greenhorn
Joined: May 01, 2003
Posts: 26
|
|
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
Joined: Feb 27, 2002
Posts: 8876
|
|
|
JSP/servlets app without app
|
Groovy
|
 |
Lasse Koskela
author
Sheriff
Joined: Jan 23, 2002
Posts: 11962
|
|
|
As a side note, servlets plus plain old Java objects are J2EE as well...
|
Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
|
 |
Prakash Dwivedi
Ranch Hand
Joined: Sep 28, 2002
Posts: 452
|
|
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
|
Prakash Dwivedi (SCJP2, SCWCD, SCBCD)
"Failure is not when you fall down, Its only when you don't get up again"
|
 |
Nirvan Sagar
Greenhorn
Joined: May 01, 2003
Posts: 26
|
|
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
Joined: Jul 11, 2002
Posts: 219
|
|
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.
|
Best Regards,<br />Nagendra Prasad.
|
 |
siqi zhang
Greenhorn
Joined: Jul 04, 2003
Posts: 3
|
|
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
Joined: Apr 27, 2003
Posts: 263
|
|
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 ...
|
 |
 |
|
|
subject: Which is faster?
|
|
|