Ratchet and Clank

My son and I pooled our money together and bought a PlayStation2 over the weekend.  The bundle came with a game called Ratchet and Clank by Insomniacs which my son and I took turns playing.  I am not too impressed with the graphics, but the game itself is very well done and a pleasure to play.  Since I am a cranky old man when it comes to quality of software, the fact that I like the game means quite a lot.

Why didn't I get an Xbox?  Becaues it's the application (games) that matter, not the platform.  Selection of available games for rent at BlockBuster is much bigger for PS2.

Sparkling Flash-Killer

Microsoft recently bought Hong Kong-based Creature House supposedly for the Expression technology, a vector renderer with some interesting features like soft-edge and reflection mapping.  One gripe I have had about Flash is it's lack of API.  If the rumor is right, Microsoft's Flash-killer (tentatively called Sparkle) will be primarily API-based.

XAML and Avalon might be interesting architecturally, but I predict that Sparkle will have the most impact on future Windows GUI.  I can't wait to get my hands on Sparkle.  I just hope Sparkle redistributables will be available for legacy platforms so I don't have to wait until the Longhorn marketshare grows big enough.

DBXML Weekend

I am dedicating this weekend to DBXML.  Early this morning, I saved all of my Radio blog posts (630) into a single RSS file and imported them into a DBXML database using the StAX-based RSS parser I started writing yesterday.  The parser is not ready for public consumption yet, but it's useful enough for me to extract <item> elements and serialize them back into strings so they can be inserted into DBXML.  Boy, it is fast!

A couple of hours later, I am having a blast querying my 'blog database' using XPath.  For example, "/item/title/text()" is all I need to list titles of my blog posts.  Neato.  On my to do lists are writing DBXML taglib for rendering the results from JSP, experimenting with indexes and Berkeley DB triggers to drive cascading network of XML documents stored in DBXML.  And then maybe throw in some recursive dependencies to watch DBXML thrash violently in pain.  Muhahaha!  Definitely a fun weekend.

You think maybe I should take up golf again?

StAX Fun

Last night I played with StAX, the new streaming XML parser API.  I am impressed with the performance and ease of use.  There are some weirdness in the API though.  For example, check out these overloaded methods:

 writeStartElement(String name);
writeStartElement(String ns, String name)
writeStartElement(String prefix, String name, String ns)

writeEmptyElement() is similarly overloaded , but writeAttribute() is not.

 writeAttribute(String name, String value)
 writeAttribute(String ns, String name, String value)
 writeAttribute(String prefix, String ns, String name, String value)

All I can say is this parameter order scrambling doesn't make sense to me.

BTW, I am building up a set of useful StAX functions and hope to share it with others soon.  For example, skipElement and exitElement are pretty handy for skipping over an element or exiting from within an element.

Tomcat and Windows Server 2003

Many server hosting companies are offering Windows Server 2003 these days at attractive prices.  If you use Tomcat and are thinking of using Windows Server 2003, you should be aware that IIS 6 will have to be reconfigured to run in IIS 5.0 Isolation Mode which is a major sacrifice in terms of performance, stability, and manageability.

While Apache Tomcat team seems to be satisfied with this workaround, I am not.  So I am holding off on moving to Windows Server 2003.  I suppose I can fix this problem myself, but knowing that this sort of short hacks can easily lead to a year long stream of bug reports, I won't.

If you really need to run Tomcat on Windows Server 2003 and IIS 6.0, here are some resources hosted by Adam Krouskop (HTTPS access only):

StAX Patent?

StAX (Streaming API for XML) was recently approved and implementations are starting to emerge from BEA, Oracle, and Sun, but I just noticed that a patent application has been filed by Chris Fry, an employee of BEA and the StAX spec lead at JCP (Java Community Process), on November 26 of last year.

Given that streaming XML parser implementations have been around way before that and well publicized, I am somewhat confused by this patent.  Can someone, preferably Chris, shed some light here?

Restricted Credit Cards

To stem mounting credit card debt and fraud problems in Korea, Korean credit card issuers like Kookmin are starting to experiment with restricting transactions by merchant type, time, and amount.  For example, a credit card that can't be used at bars from 8PM til 6AM could save Korean business men a lot of money.  Some day, credit card users will be able to not only program their credit cards like they would a VCR but also issue and manage their own cards.

XML Library Benchmark

If you are still not sure which XML parser to use, here is a nice benchmark result.  While benchmark results are not always trustworthy, these results matches my experiences with expat, libxml, and Xerces parsers.  The parser I recommend is libxml for providing excellent performance with reasonable footprint and resource consumption.  For XSLT, I recommend libxslt which provides much of the same for XSLT transformation.

Unfortunately, Berkeley DB XML uses Xerces which falls way behind libxml.  Also, I thought Berkeley DB XML stored XML in preparsed format, but the doc say XML is stored as in UTF-8.  It might be interesting to build a native XML database using libxml on top of SQLLite that stores canonicalized XML documents as well as binary versions of those documents…  If I had the time that is.

FYI, Expat is small and fast for simple tasks but offers only a fraction of libxml features and Expat third-party libraries I have looked at are no where near what libxml delivers.

Red Hat Drop

Red Hat is dropping support for non-Enterprise versions of its Linux distribution.  Drop date for Red Hat 7 and 8 is end of the year.  For Red Hat 9, which I am grumpily using, the date is end of April 2004.  So now I am running unsupported OS on my server.  I am half tempted to replace it with Windows 2003 Server at this point.  Last thing on my mind is upgrading to Red Hat Enterprise.