.NET and J2EE – A Comparsion Study
This tutorial compares .NET and J2EE, discussing various features of both the technolgoies and summarising when and where these technologies are suitable to use for entriprise application.
Competitive or Complementary?
With the introduction of .NET technology Microsoft was focused to enjoy monopoly in market of development of enterprise applications. But later on J2EE even though being an open source technology fought back and made sure that most of enterprise applications are developed over the top of J2EE framework. In this article we are not going to take side of any of these two prominent and proven technologies. But we are going to discuss areas and scope of both technologies along with their suitability for enterprise applications.
.NET (Go Home Early)
.NET has proved that enterprise applications can be developed with an easy without bothering much about complex architectures and designs. It makes the job of developers easy and also it makes it possible to develop enterprise applications faster.
.NET comes with integrated development tool, which makes possible to develop applications really fast. Developer can do many things like web designing, server side programming, configuration etc to the application using the integrated development tool.
Also .NET is integrated with all components along. It comes with VB.NET and C# programming language run time environments so that developer does not need to find, download, install and configure any thing extra to start coding at server side. Similarly for persistence layer, ADO.net is integrated within the .NET framework itself. So the developer can directly start interacting with database from middle layer or business logic layer without worrying size of connection pool it maintains.
.NET framework comes with server-side components integrated within the .NET pack itself like plug-in for Crystal Reports, Web Calendar, Web time picker, popup windows etc. Not only this, but even IIS which is the only standard application server for .NET comes along with the .NET installation kit. Once the developer installs .NET on his Windows operating system he is set to develop entire web application without need of any third party plug-in or APIs. Integrated development environment of .NET technology is one of its advantage which helps developers to develop applications fast.
Easy to Code
Programming with languages like VB.NET is very easy and simple because the language itself is very human friendly. Also the development tools for .NET programming languages are very powerful and user friendly. They support many features like auto completion, auto correction, compile on fly, running applications from IDE, debugging facilities etc. Programming with such tools makes easy and possible to develop applications fast. With such tools programmers can concentrate more on functional and performance aspects of the application.
How About Linux and Solaris???
The major disadvantage of .NET technology comes when we think about independence of deploying and running application on operating systems other then windows. Even though .NET is claimed to be platform independent technology for now we cannot deploy and run .NET applications on other operating systems then Windows. People who have developed .NET claims that once run time environment for .NET is available on Linux and other platforms it can run over them. But still the world is waiting for such run time environment and no commitments are made when they will come to us.
Now lets analyze how far .NET is suitable development technology to develop enterprise applications. As we have discussed above, .NET is having major disadvantage of its dependency over the Windows operating system. Other disadvantages can be counted like less scalability, less customizable etc.
Sometimes especially while developing small enterprise applications most important factor considered for development is time taken for it. In such cases, choosing .NET as development technology makes sense because even though it is costly, it can be economic in the sense that it takes less time to develop applications.
We can safely conclude that for small and relatively simple enterprise applications .NET is suitable choice as a development technology.
J2EE (Scale The World)
Some people may find it difficult and complicated to develop enterprise applications over the top of J2EE but it is a fact that most of enterprise applications are being developed with J2EE. The reason why people go for J2EE despite of its complexities is that it comes with considerable advantages which are very crucial for enterprise applications.
It is a known fact that the application developed with J2EE can be deployed and run from most operating systems without or with minor changes. This makes J2EE technology of choice for enterprise application developers. Because of its platform independence, developer who is programming and unit testing on Windows operating system need not worry if his segment of program is going to work on Linux or not.
Applications developed with J2EE can be deployed on most available hardware. It offers flexibility of hardware to the end user also. Application can be deployed over an existing hardware without any extra cost. So applications developed with J2EE allows end users to deploy and run applications on operating system and hardware of their choice.
Java (on which J2EE is based) is an open source technology. It is developed and maintained by the Java community, which is controlled by Sun. And Sun has made Java available without any cost. Even development kit for J2EE is also available for free from Sun and some other vendors. So for people for whom cost is important factor while developing enterprise application, J2EE is the ultimate choice.
Moreover, Java plug-ins and tools are also available for free. E.g. Eclipse development tool, which provides almost all functionalities similar to .NET, IDE is available for free from IBM. So selection of J2EE as development technology can help to reduce const of such tools and plug-ins also.
There are some factors those are very important for large, complex enterprise systems and those should be considered while selecting appropriate development technology. Java offers almost all of them. Let us have glance at them in brief.
Scalability: Java applications are scalable because of its component-oriented architecture. It comes with components like Swing components, JavaBeans, Ejb etc. Because of such components, J2EE offers great level of reusability of code and functionalities. Also because of its component driven approach, it offers better control over common functionalities like authentication.
Maintainability: J2EE applications are easier to maintain because in most cases they are designed in multiple layers. So it becomes easy to place a bug and remove it during maintenance stage. Also it is easy to add new functionality or plug-in third party functionalities to J2EE applications because of its scalability feature.
Customization: Applications developed over the top of J2EE offers great level of flexibility. Developers can change implementation and behavior of Java language itself if it is necessary at any stage of development process.
Let us examine suitability of J2EE as development technology for enterprise applications. Considering above-mentioned points we can say that to develop large enterprise applications where there is a need of scaling application, reusing its functionalities, higher level of security, higher level of flexibility and great amount of maintainability J2EE should be technology of choice. For small applications where functionality is very simple and easy to maintain J2EE will prove to be very complex technology. The cost factor too plays a vital role here. If there is a requirement that the application will have to be deployed and run on platform other then Windows then it becomes necessary to develop the application with J2EE. One may go for J2EE simply because it is available for free. It is necessary to remember that to develop applications with J2EE is going to take more time then that with .NET. Ultimately one may require more human hours to develop the application, which can result in increased cost again.
Let us try to summarize cases where both technologies are suitable.NET:
- If there is need to develop the application within a short period of time.
- If the end user is ready or willing to bear the cost of .NET, Microsoft operating system and server licensing.
- If human hours cost more then licensing cost.
- If there is no need to reuse and scale functionality of application.
- If the system is having very complicated requirement and has very large scope of functionality.
- If there are requirement to reuse and scale system functionalities.
- If there are fewer constraints over time taken for development of application.
- If the end user if not willing to bear cost of licensing .NET and other related products.
- If there is requirement to deploy and run the application other then Windows platform.