re: CFMX Java-jock jihad

Geoff makes a couple blanket statements in his post about how the Java world doesn’t understand CFMX. I don’t agree with a couple of them:

· ColdFusion remains the only answer to making Java accessible to a mass of non comp-sci web developers — I don’t have a computer science degree, neither do 3 of the other 4 developers at Mindseye (all of whom have written Java applications and all of who have spoken at DevCon) and I’ve created a couple sites using Java & JSP technology so to say that non comp-sci web developers can’t understand Java is patently incorrect. I think it also bears mentioning that Java is considered by some to be a language for the masses:

The advantages of Java is that it easily serves as a lingua franca – everyone can read a Java program and understand what is going on…“,

· …most Java developers fail to see where CFMX fits into their world of programming… — Why should they care? There are a number of other scripting languages that work with Java, PHP being one of them. Java developers have enough to worry about… they’re too busy choosing between web frameworks (struts, tapestry, webwork2), persistence models (obj, castor, jdo..) and templating mechanisms (velocity, cocoon..). It’s commonly mentioned/demonstrated that ColdFusion is easy by showing how few lines it takes to query a database, but has anyone ever asked an enterprise Java developer how many queries they put into a JSP? .

With that said, I think that Geoff has the right attitude, starting a “.. post-positive campaign highlighting CFMX/Java symbiosis” is a great starting point. Go one step further though. Build a J2EE application, learn Struts, use OJB. Geoff claims that J2EE people don’t understand CFMX. How well do CFMX people understand J2EE?

Busy week…

Last weekend my wife and I drove down to Staten Island to help my parents move my grandparents stuff [pictures] into a truck that my parents then drove across the country to Seattle. Monday night I flew to Park City, Utah for a sales presentation, got in at 3am on Tuesday, did the presentation, flew home Tuesday night, got in Wednesday night at 12:30am. After that it was slower.. this weekend I dragged my wife to see the Blue Angels perform at the 2003 Westfield Airshow, which I just posted pictures of, along with 2 (admittedly) low quality videos [1], [2].

Instant logging: Harness the power of log4j with Jabber

IBM developerWorks has a great article that talks about extending log4J to with Jabber. log4J comes with appenders for Sockets, JMS, SMTP, Telnet and so on… This article discusses extending the AppenderSkeleton class to provide logging to a Jabber server, which initially sounded crazy (why would you want to get IM’ed every time a log() message is fired in your application?), but makes great sense now that I think about it. You can log to a group chat room (multiple people can be viewing the logs in real-time), Jabber clients are ubiquitious across operating system and device type, and Jabber provides resource awareness, which means that the logging messages will be routed to the best resource available.

The authors use Smack by Jive Software for connectivity through Java.

HttpHandlers, HttpModules, Servlets & Filters

I’m in project limbo today, coming off a large ecommerce initiative for FootJoy that uses ASP, C#, Flash and Flash Remoting and moving onto another ecommerce site, this one completely C#.

I’m slowly grokking the .NET packages, I trying to understand the low-level System.Web classes today. I was interested to read about the IHttpHandler interface, which you use to create services that are similar in nature to the Java Servlet interface. Similarities I can see/find:

  • JSP’s are compiled down to servlets at runtime, .NET uses the System.Web.UI.PageHandlerFactory class when handling requests for .aspx files. Don’t believe me? Check the <httpHandlers> element of your machine.config file.
  • Servlets can be configured to respond to a variety endpoints through the <servlet-mapping> element of web.xml, HttpHandlers are added to web.config like this:

    <httpHandlers>
       <add verb=”*” path=”/mypath/somepage.aspx” type=”com.mindseye.handlers.TestHandler, TestHandler” />
    </httpHandlers>

  • Both servlets and httphandlers give you a means of interacting with the low-level request and response services of the web server

In much the same way, HttpModules and the javax.servlet.Filter class perform similar functions. An HttpModule class registers itself to listen for events that are fired in your HttpApplication (for instance the ‘BeginRequest’ event) and then can perform actions based on the occurrence of those events. A Filter is a bit different in that it is mapped to the a specific url pattern in web.xml and is then called when a request is made that matches that pattern. Just like the HttpModule class, it too can then modify the request coming in or the response going back out.

In general, I’m very impressed by ASP.NET (and thus the .NET framework).

VS Httpd

VS Httpd is a small HTTP server for the Symbian Series 60 phones whose main purpose is to provide web access to images stored on the phone. You can download it here.

I installed with no problems but couldn’t view any documents on the phone, the phone was picking up a 10.x.x.x ip address, which I believe is a private IP behind the AT&T wireless proxy. Not sure if I’ll be able to make any use of this. Anyone else able to get it working?

[update: I found the readme.txt file on the system using fexplorer, according to it neither T-Mobile or AT&T give you publicly addressable ip addresses. Bummer.]