Multi tier web architecture

It is easy to build an application these days. You can find kids developing mobile apps, websites, etc, and playing around with them. Running an application, with a business logic, and a nice, cool look, would make the application interesting. But there is the element of engineering is missing in it. And it is inevitable in case of large applications, especially distributed ones. 

When you are building an application, a large system, say for managing a company’s employees’ details or a search engine like Google, or even a student management system in a University, etc, the development is no more just the logic and the looks. There are so many more details to be considered. How many people can use the system at the same time? What is the maximum server load? How do you perform software updates while the site is already running? How to connect  the server,  the database, the user? How to handle multiple servers, shutdown one without affecting the other? What to do in case of a catastrophic failure of a system ?etc … It is found that software developers prefer component based frameworks, where a component is a separate element, which could be used for executing an abstract functionality. There are some techniques used by the web tier to handle the distributed application by dividing the whole application to multiple components, and interacting with each other using interfaces, and remote method invocations. 

Multi-tier deployment
Multi-tier deployment

Enterprise JavaBeans, or EJBs are used for deploying server side distributed components meant to perform server side operations.  It performs tasks different from the client side operations like rendering GUI’s, performing client side validations, deal directly with end user or end application. EJB’s on the other hand, perform activities like executing complex algorithms, access the database (eg: JDBC API), integrate with other systems etc. A distributed component, also called as a remote object is callable from a remote system. It means that it is not only accessable to an in-process client but also to an out-of process client that is located somewhere in the network. Some of the clients that access distributed objects are : 

  • Application clients that execute on users desktop and connect to EJB though network.
  • Web servers, that manage dynamically generated web pages. These web servers need to connect to the EJB server to get the actual business logic to generate the web page. 
  • Web services – There are no human users, but instead there is a system trying to access the distributed components via a web application. Here, the EJB’s can act as a web service client. 

My next post explains more about remote method invocations, and distributed components. 


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s