Mark Watson's Blog
I am the author of 13 published computer books and a consultant specializing in Java, C++, and Smalltalk development. Please check out my two Free Web Books at my main site www.markwatson.com

 



Subscribe to "Mark Watson's Blog" in Radio UserLand.

Click to see the XML version of this web page.

Click here to send an email to the editor of this weblog.

 

 

  Sunday, November 17, 2002


Java - a love/hate relationship

OK, this is a peculiar discusion from someone who usually shows up near the top of any listings when searching the web for "Java consultant", but I am feeling frustrated with several aspects of the Java platform today.

This frustration started this morning when I was writing new material for my (unreleased) web book The Software Design Book. I was basically casting a few mild dispersions on Sun and Microsoft, and that got me thinking of such issues as:

  • large memory footprint for Java applications
  • more emphasis on creating many new APIs rather than making the Java platform (JVM, compiler) tighter, more compact, faster, etc.
I then started doing some work on my virtual private server (I use a service that runs many instances of FreeBSD per physical server - for a small monthly cost, you get a machine on the internet that you have root control over. The only problem with this otherwise wonderful service is that they do limit the amount of virtual memory that your FreeBsd instance gets.

OK, now you see where I am going with this! Running Java under severe memory limitations...

Anyway, in the past, I have had really bad luck running Jakarta Tomcat on my virtual server because of out of memory errors. Tomcat is usually my favorite Java development and runtime platform. Love it. Can't run it on my virtual server. SOOoooo, I installed Jetty - much better, now I can run JSPs and servlets on my virtual server. But, the memory footprint is still huge.

As a comparison, I keep a demo web services application instance running all the time on my virtual server that is written with VisualWorks Smalltalk (version 7). This application has embedded servlet support and something very close to JSPs. I also have SOAP services built into the application (still working on this, but it will be both a SOAP server and use remote SOAP services). For you Java developers, I just don't want to tell you how small this memory footprint is. Really, it would make you feel bad. For non-Java users, email me, and I will let you know :-)

As long as I am ranting a little about Java's runtime memory footprint, let me also say that the Smalltalk web services application has been running a week, and its memory footprint has stayed absolutely constant (Smalltalk offers automatic garbage collection, etc., just like Java).

But, don't get me wrong. I do very much enjoy coding in Java. It just makes me sad to think how much better the Java platform would be if the emphasis was on the core platform and its efficiency.

To be fair, Smalltalk has been under development a long time. A similar situation exisits for Common Lisp - the language is old enough so that the compilers and runtime systems are very, very good.

On a happier note...

My wife Carol, our Italian Greyhound Kito, and I just had a great hike in Sedona, where we live. Yes, all is good in the world :-)
1:27:34 PM    



Click here to visit the Radio UserLand website. © Copyright 2003 Mark Watson.
Last update: 9/16/03; 7:34:02 AM.

November 2002
Sun Mon Tue Wed Thu Fri Sat
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
Oct   Dec