Time: Google’s chief looks ahead

Google’s chief – Eric Schmidt speaks about the silver bullet in business – partnerships. Eric is usually rather honest in his interviews which is what makes them so interesting to read.

The new technology thrust that is unravelling is in terms of video online, Search, Exchange, Edit, Annotate, Popularize, Promote name it there is a web 2.0 site out there that is doing it. Google themselves are partnering with MTV.

Google’s chief looks ahead.

From the Bigger Boat site,

Entertainment isn’t what it used to be. From big media company blockbusters to two minute videos created by individuals armed with an imagination and a camera, entertainment comes in many forms. Much of it now targets the individual instead of the masses. With so many services competing for our attention, we find ourselves asking, “Does it work on my iPod?, Is this the free version with ads?, Can I burn this to disc?” While the Internet gives us access to much of this content, there hasn’t been a simple way to find and filter it.

BiggerBoat gives people a better way to search and discover entertainment. From the top of the charts to the long-tail of consumer generated content, we’re developing a resource that gives consumers an accurate picture of what’s out there. We’re doing this by creating a single powerful Index of information coming from a variety of sources – the freely available Web; members-only services; and information that you just can’t get anywhere on the Internet, until now.

Uncertainty, complexity, and hard non-deterministic problems

I came across validation on the thought that people management is a hard problem.

From Bruce Eckel’s blog, “Deterministic Software Development“. Bruce talks about management thinking, about why Software development cannot be included in deterministic set of problems and finally about why the people factor in software development is key. He suggests that looking at it in a deterministic sense is a dead-end approach.

Related posts on my blog:Engineering Management” – Sukshma.

You might also be interested in “What is problem solving?” – Michael E. Martinez, on the application of heuristics, goal management, and learning to solve complex problems.

Web application testing tools

Automation of basic tasks is important – work smart and efficient. I am trying out Watir (pronounced water) for web application testing. Watir stands for "web application testing in Ruby". Watir was recommended to me by two other sr. technologists (thanks Anjali and Nikhil).

Why do I think it is the killerest? Watir is a test framework written in Ruby. The test scripts are also required to be written in Ruby. The idea is to instantiate an instance of Internet Explorer at the start of your script. The test script is given a handle to the browser. A programmer can then use the handle to script in input to the browser and validate and verify the output. Under the hood, this is accomplished by directly manipulating Internet Explorer using DOM. This is similar to how javascript manipulates the DOM through IE.

The advantages are many. I wrote my first (dead simple) script within 15 to 30 minutes. This way, I can also avoid any harness-specific issues. I also avoid the "recording" phase. My tests scripts are already parameterizable, since they are written in a programming language.

What does it lack? Anyone heard of firefox and linux? I cannot run Watir of a Linux/POSIX box as it stands today. I am already thinking of extending Ruby to provide handles for SOAP, LDAP and other application protocols. I am not sure how easy or hard that would be.

To what can I compare it? I tried to first pick up on Apache JMeter. I ran into two problems. Firstly, a lack of simplified documentation to get me started with writing a simple test script. Have a look at the first page of "Building a test plan" in the JMeter user manual. The second is subjective – I felt the interface to compose a test "story" (If I may call it that) was not intuitive. Nevertheless, people who do know JMeter will swear by it for automation of functional as well as performance testing.

My research is far from complete. Yet, I will bet my money on writing scripts in a language rather than through a point and click user interface. Power over usability. This also implies that I will have to first gain expertise in Ruby to get anywhere near exploiting Watir to the hilt. Later, I could try and peek into JMeter's internals to see if scripts can be written in the native language with little learning other than knowledge of Java.


Update: Also have a look at the Selenium IDE. Selenium is similar to Watir but automates the process of script creation through point and click. So the choice of power or usability is really up to you. An advantage is, Selenium will work on Linux/POSIX and Mac OSX. Selenium is built and supported by Thoughtworks.

All things distributed: Growing (up) is hard

Werner hints that Amazon guarantees performance and availability while scaling up to handle exponential growth in data-sets and user requests successfully. He also asserts that the techniques have remained a dark art.

I don't agree with the second part. There are many out there that beat the same problem (I had the good fortune of working with one such company). Those who have won have solved the problem by creating a solution that is tailored to their context in conjunction with well known techniques for scaling and redundancy. Everyone has to start someplace, I recommend – "Programming Pearls" by Jon Bentley.

"Growing up is hard" – Werner Vogels on All things distributed.

To those who still read this blog. I am growing (up) and this blog is beginning to suffer. I am working on fixing that problem (not the part where I am growing 😉 ). Until then, thanks for stopping by.

Fuzzy Programming

Original Article: "Coding Tool is a Text Adventure" – Wired Technology News, Mar 15th, 2006.

Software developers are going to get a kick out of this new virtual programming tool:

Now, thanks to a new software-collaboration tool, you and your intrepid party of fellow hackers can navigate your labyrinth of code and slay its dastardly bugs, all in a dungeonlike world similar to an old-school text adventure.

Called playsh, the new tool is a collaborative programming environment based on the multi-user domains, or MUDs, so popular online in the early 1990s.


NullPointerException thrown

Seriously considering enforcing every assertion of the form,

String objectA = objectB.getStringValue();

Rewrite as the following,

String objectA = objectB.getStringValue() != null : objectB.getStringValue() ? "";

Advantage, you won't encounter a NullPointerException.

Disadvantage, every object has to have a default, non-null state.

Anyhow, this is not a recommended practice. In many cases, all a programmer would be doing is replacing poor code which throws a NullPointerException with poor code that will try to work with bad data (and eventually choke with unclear symptoms).

A better rule of thumb might be, if your writing a producer, never return a null object, throw an exception instead as an expression of error. If the value is a null reflecting the storage (file/relational db or something else), then it cannot be helped.

If your writing a consumer, always check your arguments, log which ones are null and re-throw a runtime exception. Unfortunately, a runtime exception can throw things out of whack. Use it judicously. If a null object can exist (see the storage case above), you may have to work around it (by applying a default code path). Even if you were to assert that the consumers arguments cannot be null, a code review would catch it, since your assertions are now explicit.

To conclude, I recommend that a consumer must avoid re-throwing a runtime exception, check its arguments, and wherever possible, explore the option of providing a default code path when critical arguments to the consumer are null. For example, if a users language and country is null, select the system default locale.