J2EE / .Net Smackdown

Cedric Beust
November 19th, 2002

I attended the "J2EE / .Net" Smackdown, organized by the Software Development Forum, an independent organization.  Sun and Microsoft were each represented by three panelists (note that the name of the even is misleading, it should really be called "SunONE / .Net Smackdown".

The format is simple:  ten questions have been submitted to the participants a month ago and they will answer them all in turn in five minutes.  Each party has the right to three rebuttals if they feel like contesting what the other boxer, I mean, participant, just said.

What follows is a summary of the questions and their answers.  Whenever I feel like adding a personal remark, I will do so with a particular color.

Opening statements

Sun Microsoft
Choice, trust, open standards, quality. MS is trying to divide the developer community and abuse their monopoly, "embrace, extend, extinguish". Sun wants to help us build open systems by defining open standards, as opposed to MS who is trying to corrupt standards and promote tools that support lock-ins in their technology.


Emphasis on Web Services.  Gates announced Visual Studio.NET beta at Comdex.



1) Net/J2EE: what are they exactly?

Standard J2EE presentation.  Talk about JCP, JSR, etc...  One vote per participant, community effort.  2.5 million programmers as of 2001, predicted 4 million in 2003, Java is taught in a lot of universities and available on all types of platforms and OS.

.Net is not standards based and nothing more than a set of Microsoft products.  ASP.net and ADO.net not in ECMA.

MS creates oftware for connecting information, people, systems and devices built on a foundation of XML Web services (UDDI, WSDL, etc...). Web services support across the Microsoft platform (interesting they would admit this on a slide.)

Their offer relies on:  Visual Studio, Office XP, Windows server family, Windows XP, which all have a proven track record in the enterprise, multi-language support.

Sun rebuttal:

Gates quote: ".Net is simply our implementation of these XML Web services across all the different MS products."  What happens when you have a Solaris or Linux box?  This is not the real world.

Another Gates quote:  "A lot of people like flexibility in choices, so what are the choices here in terms of what .Net means?  Well we want the choices all to be exactly the same".

2) What is your platform's level of support for Web services?  Can you show us using your platform and tools?

Sun Microsoft
3 phases of adoption of Web services:
  1. Simple (now)
  2. EAI (begun)
  3. Business (2004?)

Sun's offer is standard based:  ebXML and UBL, Liberty project.  Standards should be developed through open and inclusive process, and should be royalty free.

Anyone who is involved in a JSR process knows that the openness is far from being a reality.


Now:  .Net framework, Visual Studio, SQL server WSTK, Biztalk server, Exchange WSTK, Content management server, SOAP toolkit, Office WSTK, Project server.

Coming soon: WSE, Windows.Net server.

The speaker then started a demo of Visual C#.Net calling a Java Web service (unfortunately interrupted by the clock).

Quotes from Gartner saying good things about .Net (it's easy to find everything and its contrary in Gartner's literature).

Microsoft rebuttal:  problem with licensing problem.  J2EE is not a free and open standard, and if it were, JBoss and Apache would have the ability to license freely.  Much more important than open API's are:  open wire protocols that enable interoperability

Microsoft did their homework, I am impressed they know about JBoss, but this might come from one of their three panelists who is a former J2EE professional.

3) How does your platform address complexities related to scalability and how does it empower organizations to build such applications quickly and with minimal expense?  Can you show us using your platform and tools?

Sun Microsoft
Collaboration is made through the open JCP process.  The participants compete on quality, not interfaces. 

How do you gain confidence in the .Net platform without peer review, when MS changes API's to consistently ensure their revenue stream, when they don't have a proven "Enterprise platform"?

Not very convincing, and not showing any tools.


Highly-productive, award-winning IDE, custom extensions through macros or add-ins, debug/trace framework support.

Support large scale deployment, reliability, XML config files everywhere, easy scripting and editing.

Some scalability stories:  major insurance company (200 tps, 700,000 tx/day), Merrill Lynch: 21,000 tps (yup, twenty-one thousand), 75M tx/day, CNET 4400 tps, 1.5M tx/day.

.Net is not vaporware.

Source code control supported by the tool, no classpath hell, metadata and attributes are part of the code syntax (but they mention JSR 175), fewer lines of code (1/3rd to 1/7th of the code).

Interoperability demo:  Java application (GLUE) connecting to a .Net server.


Sun rebuttal:  it's not really interoperability.  They are eschewing away Apache, Solaris and using interoperability to cloud it.  But where are you going to write your code?  You have to reimplement it.  Portability and interoperability are different things.  Sun has both, MS only has interoperability.

4) Why would a developer choose one Web Services architecture over another?  Which will prove to be the most flexible/useful moving forward and why?

Sun Microsoft
Two models:  RPC and Document-driven.

WS is just one of many service delivery channels of J2EE.  Many benefits of J2EE are preserved for WS (portability, scalability, reliability, no single-vendor lock-in).

Standard Java API's for WS are available right now (WSDP, JAXM, JAX-RPC, JAXR, etc...).  More are coming, tools are also available now (BEA, Sun Oracle, IBM, Boland, Systinet).

Demo using NetBeans and stateless session bean.  Interrupted by the clock as he was starting the J2ME application.

Not very impressive anyway, this is 2002, not 2000.


There are two SOAP styles but they are not in conflict:  RPC vs Document:
  • Exposed only in the WSDL
  • Programming model unchanged.

Then the speaker talks about encoding to conclude that it's not an issue.  Web Services support Request/Reponse models and HTTP binding for SOAP makes this easy.

Too technical an answer, and I couldn't really figure out how it promoted the Microsoft platform...


5) Explain your platform's security structure and how it differs from your competitor's

Sun Microsoft
Mentions worms, Code Red, billions of dollars lost to security breaches and viruses.  Security cannot be an afterthought, it must be built in.  Sun designed security in since the beginning.

Microsoft quote from Craig Mundie: "We started thinking about this three years ago".  Twenty-four years too late, according to Sun.

Emphasizes Microsoft's bad security record as illustrated by Gartner.  "Scan your Visual Studio.Net CD's, they might have a virus".

Vulnerabilities by OS reported in 2001:
  •  Mandrake:  33
  • SCO: 21
  • Windows 2000: 24
  • Solaris 8: 24
  • RedHat Linux: 28

We do sell more, we reach more customers.  Asked about sources of these numbers, doesn't have them.  Microsoft is secure by design, by default and in deployment.  If IIS is not needed, it can be turned off.

Then shows a diagram representing the security core of .Net.

Sun rebuttal:  Microsoft is breaking your software to fix their mistakes (another Mundie quote).  .Net is not even released yet and ASP.Net is alrady broken (security bulletin on Microsoft's Web site).  C# permits unsafe operations, sacrificing all language based safety and also allows  to mix managed and unmanaged code.

We are beginning to run late at this point and it's become clear to the organizers that they are going to have to cut down on the number of questions.  They ask for a show of hands and the crowd says "PetStore". They finally agree to have two more questions, one of them being about PetStore.

6) What is the cost of deployment and maintenance on your platform?

Sun Microsoft
Low cost tools:  NetBeans.  Other tools:  Eclipse, jDeveloper, JBuilder, ant Struts, Xerces, Apache SOAP, etc...

Low cost servers:  JBoss, JRun, SunONE AS, Apache/Tomcat.

The cost is maintenance and support.  Risk is a big cost.  When will .Net be fully shipping?  J2EE is stable and mature (enumerates versions of current application servers).

It's hard to tell what the development costs for the Microsoft platform are.

MSDN Universal: $2499, including Vistual Studio Enterprise Architect, SQL Server, BizTalk Server, Exchange, etc...

SunONE:  $1995, App Server:  $2000/cpu, App Server EE $19995/cpu, EAI Server $30,000  + $75,000/cpu.

SW + HW is 10-20% of the cost of a project, 80% is labor.

Proceeds to quote various happy .Net users.

7)What's going on with the Petstore benchmark?

Sun Microsoft
Benchmarks that you fund usually come out in your favor.  MS created a brand new application based on stored procedures.  Oracle tinkered with the SQL and ended up running faster than the Microsoft server application (that's news to me).

After modifications, J2EE scaled 400% better than .Net.  The Middleware Company engineers haven't used their expertise.

The Middleware Company apologized for what happened and a new round is planned.

Lines of code comparison is misleading.  .Net code is not object oriented, pricing is wrong and extremely limited.  They used JDK 1.3, not 1.4.  No database tuning, dubious hardware selection, doesn't use EJB 2.0, no disclosure and the vendors involved never gave their permission to use their software.

Still, there is some value in this exercise:  the same application was ported on two different servers, proving the portability of J2EE.

"They started it".  ( :-) )

Larry Ellison claimed Oracle had the best server so Microsoft decided to contest this claim.  .Net was 28 times faster, which actually turned out to be more like 10 times after reevaluating the benchmark.  In October 2002, Microsoft reprised.

Why did they choose PetStore?  Because SpecJAppServer excludes .Net and Java isn't present on TPC-C and TPC-W.

The Middleware Company approached MS to participate in re-test of J2EE vs. Net.  The results show that .Net bested the performances of two leading application servers.

.Net has a much lower price/performance ratio and delivers three times the performance of Java.

There are other factors to consider than performance.

Microsoft wants one more minute for a rebuttal:

Larry Ellison specifically targeted .Net as the contender to beat (this is absolutely not my recollection and I was present at that keynote at JavaOne.  I don't remember Ellison mentioning Microsoft, much less .Net.  He was clearly targeting BEA in his claims.).


Nobody ever comes out a winner in this kind of face off, but overall, the atmosphere was friendly even if the crowd seemed to be cheering J2EE more often than .Net (this is Silicon Valley after all).  However, I expected this crowd to be much more of a J2EE captive audience than it was.  While Sun's points were usually loudly acclaimed, the Microsoft representatives got their share of applauses as well.

I suspect that the success of this event came mostly from the PetStore controversy.  For anyone who has been even a little involved in this fiasco, there was little to be learned, but I believe that the show has served its purpose.

One last note:  Microsoft was giving away the book "C# for Java developers".

Back to my my weblog.