.NET and J2EE BATTLE for the Enterprise
Peter O'Kelly (from China System Analyst) March 01, 2003
Keeping track of the ongoing rivalry between Microsoft and Sun Microsystems as they seek to control the enterprise application development market can puzzle even the most dedicated developer. For the software architect, the competing "standards" can be bewildering. Yet would you believe that today's choices actually make it a relatively easier time for enterprise developers, compared to the previous generations of tools? Microsoft and Sun share compelling visions for a new enterprise architecture, and each vision features strong interoperability through Web services and various standards. It's certainly easier to deal with the .NET Framework and the Java 2 Platform Enterprise Edition (J2EE) now rather than handle five or ten largely incompatible visions, which is where the middleware industry was headed previously. One of the most widely debated questions in the industry today is whether to choose Microsoft .NET or J2EE. From an Enterprise Architectural Planning Perspective, .Net and J2EE have a great deal in common and developer skills transfer nicely between them. J2EE products from vendors such as BEA, IBM, Macromedia, Oracle, and Sun have matured to the point where it's necessary for enterprise architects to place bets on either .NET or J2EE or both;... the vast majority will place bets on both For these reasons, think of .NET and J2EE as complementary, not competitive It's not surprising that the J2EE / .NET domain has been controversial and confusing To begin with, both Represent The Culmination of Decades of Software Evolution. for instance, sun '
s J2EE 1.3 tutorial weighs in at more than 700 pages, and there are many books on J2EE and .NET that tip the scale at more than 1,300 pages. Such heft is not surprising, given that these documents attempt to address almost the entire computing spectrum , from enterprise middleware to handheld devices. J2EE and .NET are also dynamic and fast-moving projects, each building on a large number of standards initiatives, especially for XML and Web services. As these standards are thrown together with the usual software industry marketing and propaganda, J2EE / .NET competition is so intense that it's often difficult to remember what the software market was like before they arrived. (Anyone embarking on a career in IBM's CICS or BEA's Tuxedo these days?) Clear Up the Terminology The inconsistent use Of Terminology Has Complicated The Undering of Similarities And Differences Between The Two Models. Terms Such As Objects, Components, And Services Are Used in Both Models, for Example, But Ofte n with subtly different meanings. It does not help that the press and industry analysts often compare specifications with product releases, and are imprecise about what's included in current releases versus what's planned for the future. Even the scope of the competitive offerings is confusing. For example, J2EE products often include integration and portal services, while .NET is generally used as a blanket term to describe all future Microsoft software and services. Standing back from the hype and dynamic definitions, however, it's possible to discern many ways in which J2EE and .NET Are Converging Toward A Common Enterprise Architecture Model. At the core of an enterprise application, there '
s almost always a database management system (DBMS), transaction processing (TP) monitor, and message-oriented middleware (MOM) service included, such as IBM WebSphere MQ, Microsoft Message Queuing (MSMQ), or TIBCO. Indeed, in most enterprise contexts there are usually multiple instances of each, although they're increasingly morphing into platform services instead of distinct server product categories-a trend accelerated by the advent of Web application servers. In the J2EE / .NET model, both the underlying DBMS / TP / MOM services and the business application contexts are managed at an object-oriented (OO) level of abstraction. The J2EE / .NET model brings the OO approach to mainstream enterprise computing, with powerful OO frameworks (class libraries) for services such as object persistence, transactions, Web services, and more. This model greatly extends the scope of work that can be done declaratively (with little or no procedural coding), and often includes a page / form / layout-driven drag . -And-drop approach for application development Components are a key part of the J2EE / .NET model;. Think of them as collections of objects packaged and deployed together for simplicity, reusability, and flexibility On the Java side, think "component" whenever you see "bean." .NET Enterprise Services and J2EE's Enterprise JavaBean (EJB) features are especially powerful for enterprise components, offering object and connection pooling and robust load balancing services. UML-based tools are often used for J2EE / .NET application Analysis and design, Both Because UML's Object Orientation Is Ideal for the J2EE / .NET Implementation Model And Because of Today '
s enterprise endeavors. Although the approaches diverge at the coding / implementation phase, a common set of analysis and design techniques applies to both J2EE and .NET. The use of a virtual machine (VM) architecture is also common to J2EE and .NET. Application development tools-such as Borland JBuilder, Sun Forte for Java, and Microsoft Visual Studio .NET-produce intermediate-level code instead of platform-specific binary code, which means the VM interprets that code in real time or performs Just-In- Time (JIT) compilation;. the Microsoft VM always runs JIT-compiled code This VM-based model results in platform-independent applications and is conducive to the late-binding technique that's critical to the OO approach J2EE and .NET share an asynchronous. , loosely coupled, service-centric communication model, with application flow of control determined by messages among objects instead of sequential flow within monolithic programs. The newer model is more appropriate for the inherently ob ject-oriented natures of J2EE and .NET, but it leads to a potentially steep learning curve for developers who are accustomed to the more traditional program-flow approach. Finally, J2EE and .NET share a broad common foundation of standards, especially around XML and Web services. Web services are rapidly becoming the neutral zone between J2EE and .NET because they offer a self-describing, vendor- and technology-independent means of inter-application communication over the Internet. If it weren '
t for Web services, J2EE / .NET interoperability would be much more problematic and Internet-based communication among applications based entirely on either .NET or J2EE would be much more complex. The multi-tiered approach typically followed for J2EE and .NET applications helps separate presentation from structure (for example, HTML at the presentation layer and XML at the business logic layer, and transaction from user interaction [see Table 1]). Given the scope of the new enterprise model, it's important to follow an approach that supports role specialization so that all developers should not feel it's necessary to understand the entire big picture (see Table 2 for J2EE / .NET perspectives by enterprise application development role types). Here's Where They Differ Although there's much common ground between J2EE and .NET Significant Differences Remain. Before Moving Forward, You'll Need To Make Some Choices. First, DECIDE WHENER You Want To Program In a Language Other Than Java. J2E E naturally focuses on the Java programming language, while .NET supports multiple programming languages-primarily C # and Visual Basic .NET, but also many others, ranging from Cobol to Eiffel. Language developers must comply with the .NET common language interface to take full Advantage Of The .NET Common Language Runtime (CLR) And framework. (It's definitely not your faather's fortran or cobol.) there '
s nothing inherent to the JVM that precludes your using it with other programming languages, but at this point Sun is singularly focused on the Java programming language for its Java platform. Another question for you to answer is how many platforms your shop supports. Beyond run -almost-anywhere HTML / JavaScript client support, Microsoft addresses only Microsoft server platforms with .NET, while J2EE products are available on a wide variety of platforms (including Windows). At least one vendor, Ximian, is focused on porting more of. NET to non-Microsoft platforms, but it's by no means clear whether they will be successful (or if Microsoft will allow them to ship anything broader than the parts of .NET standardized by the European Computer Manufacturers Association [ECMA]). Interoperability is strong Thanks to Web Services, And Both .Net and J2ee Support Client Platforms Using HTML, JavaScript, And Macromedia Flash, But The Server- and Middle-Ware-Centric Parts of .Net Currently Run ONL y on Windows servers. Is multi-vendor support an important consideration for you? Only one vendor supports .NET, while multiple vendors support J2EE. However, cross-vendor portability for J2EE is definitely not the fabled "write once, run anywhere" scenario . This is due in part to its organic growth model, where vendors add their own Web service features and other ex-tensions ahead of the J2EE specification process. J2EE vendor portability can be achieved by focusing on the parts of J2EE that are fully covered in The J2EE Specification-Such As Servlets-But Doing So Is Currently Very Constraining And Even Impossible. for Example, EJB Deployment Dimensions Aren '
t completely addressed in the J2EE specification. Decide how important an in-market track record is to your organization. J2EE products have been available for years, while the first products incorporating the .NET CLR and Framework were released only at the beginning of 2002. Even though some key elements of .NET are based on Microsoft products and services that have been available for years (.NET Enterprise Services, built on the COM architecture, first appeared in 1996 as part of Microsoft Transaction Server), the J2EE product market is More mature. Whichever Way You Go, Be Assured That Both .Net and J2EE Are Rapidly Evolving, AS Are The Standards Upon Which They '
re based. Currently .NET leads in Web services, while J2EE has a broader overall scope. In general, you can expect both to evolve and expand very rapidly. So far, the J2EE EJB model is more elaborate than its .NET counterpart. EJB flavors include (stateless and stateful) session beans and entity beans (component- and bean-managed), while .NET currently only includes support for components similar to stateless session beans. This represents a difference in architectural vision between Microsoft and the Java Community Process (JCP). Debates will continue until more real-world experience is available to help determine which approach is most effective for enterprises. Determine whether ECMA standardization is important to your team. Sun controls the JCP and owns the Java specification. Although Microsoft maintains similar Control over .NET, IT HAS Submitted Key Parts. Despite ITS Reputation As a Predatory Competitor, Microsoft Could Well Out-Maneuver T ava camp in terms of creating and building on industry standards. Third-party support issues may have already made the decision for you. Component marketplaces are very practical for both J2EE and .NET. While such marketplaces have historically been limited primarily to Visual Basic add -ins, the rich component and Web service models supported in both J2EE and .NET are conducive to much broader component marketplaces. Support from application software vendors such as PeopleSoft, Siebel, and SAP will also contribute to the relative J2EE / .NET momentum.
If SAP, for example, were to introduce a new version of its application suite that can be used as components in J2EE but not .NET, such a move would influence the strategies and priorities of enterprise application architects worldwide. Finally, see for yourself. Sun, Microsoft, and other vendors have conveniently provided a set of resources that simplify the processes of exploring and comparing .NET and J2EE, and highlight both the common elements and the ways in which the approaches diverge. Sun created a Java Pet Store reference application as part of its Java blueprint. This sample application is representative of common enterprise applications. for example, it includes components for customer, order, product, and shopping cart implementations. It's a nontrivial reference, with more than 700 individual files in the 1.3 version NOT SURPRISINGLY, Microsoft and Other Vendors Have SEIZED UPON The PET Store Application To Showcase Their Products. Microsoft's Version Provides a Useful means of comparing the .NET and J2EE approaches, especially in terms of understanding the different component middleware approaches embodied in EJB and .NET components. Do not Worry, Make Users Happy If you're like most enterprises, you'll migrate gradually to J2EE and .NET. Especially during tight economic times, nobody is eager to "rip and replace" working applications, and most enterprises will wait for more case studies before placing strategic bets on either technology.
Enterprises that focus on common areas between J2EE and .NET will benefit most because they'll leverage the transferability of skills and produce more reusable application components by using analysis and design techniques that apply to both, such as OO analysis and design using UML. Clearly , enterprises should work with their application and service suppliers to ensure that the suppliers' J2EE / .NET priorities align with their own. It would be unfortunate, for example, if a .NET-committed shop learned that its leading application vendor was leaning toward J2 EE instead of .NET-although it would not exactly be the end of the world, thanks to XML Web services interoperability. Almost all organizations will use a mix of J2EE and .NET, in part because the underlying platform choices are often dictated IF Your Accounting Department IS Already Running Microsoft Great Plains, a J2EE Version ISN't Likely to Appear Soon. Also, Most Organizations Already Use AM ix of legacy Microsoft and Java-based tools and services, with the possible exceptions of Microsoft itself and some of the J2EE vendors, such as Sun. Overall, you should anticipate that the coming enterprise architecture model will result in a raised least common denominator for enterprise applications and middleware, which will simplify and extend what was previously possible. Perhaps most significantly, as back-end development tasks are simplified, you'll actually be able to devote more attention to areas that directly impact the user experience and productivity. Imagine The benefit.