aspose file tools*
The moose likes Spring and the fly likes distributed application in Spring Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "distributed application in Spring" Watch "distributed application in Spring" New topic
Author

distributed application in Spring

vikas sharmaa
Ranch Hand

Joined: Jun 28, 2007
Posts: 191
As per my knowledge, Application Server handles all the load balancing, failover kind of stuff in the distributed application..

then how working in clustered environment is different if we are using Spring instead of EJB? Do we require to do some extra configuration or coding in Spring? why some people say, EJB is more suitable for distributed environment?
Saifuddin Merchant
Ranch Hand

Joined: Feb 08, 2009
Posts: 606

EJB is more suitable for distributed environment

Who said that? any reference/context in which you read that?


Cheers - Sam.
Twisters - The new age Java Quiz || My Blog
vikas sharmaa
Ranch Hand

Joined: Jun 28, 2007
Posts: 191
no Sam, I didnt find reference to what i said in the first post about distributed application.

still, my main question is how Spring implementation is different in distributed application (or there is no difference?)..

for example, i have written an application that is running perfectly on the server. later, I added 2 more nodes using clustering in weblogic. now, do i require to do any changes in spring configuration or code... or, it will automatically take advantage of clustering.
Saifuddin Merchant
Ranch Hand

Joined: Feb 08, 2009
Posts: 606

I've not really worked a lot on EJB's or clustering for that matter, so I'm going to have too pass out this questions ..

I did find a lot of material when I googled for ejb v s spring and ejb Distributed Computing. Give it a try!
Hussein Baghdadi
clojure forum advocate
Bartender

Joined: Nov 08, 2003
Posts: 3479

Sam Mercs wrote:
EJB is more suitable for distributed environment

Who said that? any reference/context in which you read that?

Enterprise JavaBeans (EJB) technology is the server-side component architecture for Java Platform, Enterprise Edition (Java EE). EJB technology enables rapid and simplified development of distributed, transactional, secure and portable applications based on Java technology.

Enterprise JavaBeans Technology
Saifuddin Merchant
Ranch Hand

Joined: Feb 08, 2009
Posts: 606

Hussein - I agree EJB is useful for
development of distributed, transactional, secure and portable applications based on Java technology.

The original question & even mine was for the more. Is EJB more suited for distributed computing compared to Spring?

From what I know Spring is a pretty good replacement for EJB supporting (most/all) EJB features in a more simplified manner.
I personally haven't worked on any EJB to Spring migration or distributed computing features of either. So I don't have any first hand experience to talk about the topic.
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17257
    
    6

No, and EJBs don't do distributed applications themselves either. Meaning it is the server that is responsible, and you can run Spring anywhere in any server, and even Tomcat can do clustering. If you write clean POJO classes then they can run in distributed environments with no code change at all. It is all about your servers configuration, not your applications. That is why I said EJBs don't do distributed/clustering, because EJBs are the code, not the server. Now to be an EJB container following the spec, then you have more than just code, but that is J2EE stuff in which EJB is just one part of the spec.

So, the answer is Yes, Spring can run in a distributed environment without any code changes or repackaging. It runs the same regardless of what environment it is running in.

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: distributed application in Spring