USM – Universal Subscription Mechanism

Stumbled upon the RSS on Microsoft Watch, which included instructions for using USM with RSS. USM allows you to automatically subscribe to the RSS simply by clicking on the RSS link.

Previously, the RSS links to the XML file when you click on it. It is required to copy the link and register it with your favourite RSS reader. With this mechanism, the instruction to register the RSS is embedded within the click using a specific MIME-type, which can be handled by a USM application. The application would interpret the RSS URL and register the feed with your favourite RSS reader that the USM application supports.

The protocol is fully specified at this location:


I was told by one of our users today, “This feature is very straightforward, very logical and intuitive one…”.

What I felt he meant was a nicer way of saying: “Use common sense and you’ll know la…”. Yet we know we don’t understand enough about that feature.

In reality, common sense isn’t so common after all. I mean, what I think is common sense, is based on my experience and what I think everyone should know. However, that is so not true. It is related to one’s experience and culture, and how he/she see things.

This common sense problem becomes more problematic when dealing with user requirements. The user feels that the requirements are complete, because the omitted details are so logical, sensible, and can be automatically and “inituitively” interpreted by anyone. And so he may choose not to go into the level of detail necessary to save time and saliva. That assumption may lead to incorrect implementation, due to domain ignorance of the developers, especially if they don’t make an effort to clarify the requirements.

Of course it’s unlikely you’ll get totally complete and totally unambiguous requirements, but you should try to understand as much as possible. On one extreme is believing there’s such thing as a “complete requirements”, and the other end is believing there’s no such thing so we can ignore requirements gathering.

Better be shot during requirements stage than to be strangled after development when the product don’t meet user expectations. The cost of change would be too high then.

Stunned by DownloadThemAll

Another nifty Firefox plugin. Considered a download manager, allows you to download stuff. Stunned me the first time with an amazing mp3 download speed of 177 KB/s…

At first I was looking for something that can do pauses and resumes – unlike Firefox’s built-in download manager. Kinda sucks anyway. Known as DTA, it is supposed to do some other stuff like grab more than links. Will try it over time.

Password Hasher

The Password Hasher is a Firefox extension that lets you create and remember complicated passwords easily.

The motivation comes from combining the need for strong passwords and the preference for easy-to-remember passwords. By hashing your simple password into a complicated one, you are able to secure your password since it’s difficult for hackers to guess. Yet you can use it with ease since you’re “generating” the actual password based on a simple keyphrase that you know.

I’ve not tried it myself so I do not know the actual benefits or quirks, but the idea is great. One of the first negative thoughts I have was is the hash based on a key? What if you lose the key, such as during a PC crash/reformat? You lose ALL your passwords?!

Useless Fact

On your Screen Saver dialog, there’s a check option beside the number of minutes to wait before activating your screen saver. Sometimes its “On resume, password-protect”. Sometimes its “On Resume, show welcome screen”.

The difference is when the “Fast User Switching” service is enabled. When enabled, the welcome option will be shown, otherwise password-protect will be shown.

Slow Explorer

If you’re browsing in Windows Explorer and particular folders load just so much slower than the others, check if those folder contains zip files.

This is because Windows Explorer takes effort to “help” read those zip files so that you can access them as if they’re another sub-folder. If you’re accessing that folder often, you might want to shift those zips somewhere else to prevent Windows from trying to read them.

For those keen on removing this “feature” permanantly, run:

regsvr32 /u %systemroot%\system32\zipfldr.dll


I’ve been avoiding ANT for many many years now… probably because I’ve not got into any serious deployment, or something which simple compilation cannot do. However, I finally took my step in (JUST to try it), and it wasn’t so bad after all.

Essentially, the Ant tool is a cross-platform build script (windows batch file or unix make) that can run commands in batches. Core commands (“built-in”) include copy, delete, javac, java, jar, etc. You can group these commands in ‘tasks’ in a ‘project’ to be executed separately or you can create dependant tasks that executes one after another.

Common tasks include init (which setup variable for use in the tasks, usually a dependancy for all other tasks), build/compile (main javac code to javac and move them to appropriate dir), deploy (copy ready jar/war and files to deployment locations) and clean (delete everything).

I’ve used the core copy and jar commands to build Wildfire plugins that are deployed directly, eliminating the need to manually move class files, jar and copy to deploy folder. Compilation was automatically done with Eclipse, and the Ant task was run directly in Eclipse too.

For more complicated projects Ant also support defining your own Ant tasks, though I’ve yet to need such services. However being so extensible you can say it can do anything that you can code.

System Variables: PATH vs CLASSPATH

Still a lot of people don’t understand the purpose of these system variables. They don’t know when to set it, what it really does and therefore cannot determine that this IS or IS NOT a path or classpath problem.

The PATH variable is a Windows system variable that Windows uses to find executable files. When you type a command in the cmd window, e.g. “javac”, Windows will search in your PATH to find the program to execute. The search sequence is as follows:

Current Dir > PATH Variable > Command Interpreter

In the example, the interpreter will first look in the Current Dir for a, javac.exe or javac.bat respectively. If found, it will be executed. If not it continues its search through the PATH variable in definition sequence and extension sequence. This means for PATH=C:\Temp;C:\Windows, C:\Temp\ will be searched 1st, followed by C:\Temp\javac.exe, C:\Temp\javac.bat, C:\Windows\, and so on.

Once the PATH is exhausted, the interpreter will be checked if it is a interpreter command (such as “copy”). If so it will be invoked. Finally the interpreter will return a “Bad command or file name” if the command is not found.

All these means that if you’re getting a “Bad command or file name”, it is likely a PATH problem. It also means if you’re somehow running the wrong program, it may be a program of the same name in a path earlier than yours (useful for java version conflicts).

The CLASSPATH variable is a Java runtime system variable that Java uses to find class files. When Java tries to load a class, it will lookup its ClassLoader. If the class is not yet loaded, Java tries to find the class in the CLASSPATH variable. Sometimes the CLASSPATH may be appended from the runtime command line directly.

This means that if you’re getting a ClassNotFoundException during runtime, or “Unable to resolve symbol” during compile, you may have a CLASSPATH problem. (NOTE: Typos and other errors may also raise same compile error). If the classes are in the current directory and still cannot be found try adding “.” (current dir) to the classpath or check if the sources are in java packages.

To check the current PATH on cmd, type “PATH” or “set PATH”. To check the CLASSPATH, type “set CLASSPATH”.

To fix the PATH or CLASSPATH, you can either set it on the command line directly or set it through System Environment Variables. To set it from cmd, type “set CLASSPATH=someClassPath”. To append to the existing PATH or CLASSPATH, use %xxx%. E.g. “set CLASSPATH=%CLASSPATH%;.” to append the current directory into the classpath without affecting the existing classpath. Setting the variables on cmd only persists for that session. If you start another cmd or close this cmd the variables will be reset.

To persist the variables permanantly, you can set it through System Environment Variables. For XP Pro, go to the “System Properties” first. You can get there by

  1. Start > Control Panel > System
  2. Start, right-click “My Computer”, select “Properties”
  3. Press [WindowsKey]+[Break] simultaneously

with option 3 being the fastest. From there, click the “Advanced” tab and click “Environment Variables” at the bottom. Set either the User variables or System variables. The User variables only affect your Windows Login, and System variables will affect everyone. User variables will overwrite any System variable settings.