Listing files in a servlet directory with JSP

Posted & filed under howTo.

One of those tedious things I had to do recently, so I thought I’d publish as a gist here.

Language shifting in TIOBE

Posted & filed under Software Engineering.

Having a quick look at the June 2010 TIOBE index, it’s good to see the languages I use are top of the bunch, Java, C, C++ and PHP, with the fairly new addition to my portfolio, C#, moving up the list into sixth place, just below VisualBasic. The even newer addition to my portfolio, Objective-C,  has jumped up to number 9, from 45 last year. So it’s nice to see my portfolio of languages are all in the top ten. (more…)

Solving COM threading issues in a .NET durable topic subscriber

Posted & filed under c#, GADfly.

I’ve recently been adding Groupwise functionality to GADfly which means using COM as that’s the only way to access the Groupwise Admin API, via the Groupwise client. I’ll go over how to do that in a later post but once I’d plumbed the COM functionality into GADfly via my MatrixClient for C#, I started to get a weird error. The basic setup is I register a message handler to deal with GW messages with MatrixClient and when a message arrives on a JMS topic, my durable subscriber gets the message, parses out the info and create a Groupwise account from it. However, the event handler was causing the GW class to barf in a big way:

Unable to cast COM object of type 'AdminTypeLibrary.SystemClass' to interface type 'AdminTypeLibrary.DIADSystem'.
This operation failed because the QueryInterface call on the COM component for the interface with
IID '{35FC2357-811A-11D0-8A96-00805FC16077}' failed due to the following error:
No such interface supported (Exception from HRESULT: 0x80004002 (E_NOINTERFACE)) (more...)