Thoughts about technology, business and all that's life.

This blog has moved to http://shal.in.

Saturday, August 26, 2006

Arxiv, Perelman, Poincaré and Mathematics

I read an article posted on New York Times about the Perelman and Poincaré Controversy. It's long but interesting. Through the article I got to know about http://www.arxiv.org/ This website has unpublished (or waiting to be published) articles related to Physics, Mathematics and even Computer Science. Ever since my ACM student subscription has expired, I haven't been reading any new papers. This site will certainly help.

technorati tags:, , ,

Blogged with Flock


Friday, August 25, 2006

OnYoMo featured in BusinessWorld

Check out this week's BusinessWorld Issue (dated 4th September, 2006) and find about the company that I am working at: www.onyomo.com

technorati tags:,

Blogged with Flock


Wednesday, August 23, 2006

Javascript on the server

I came across a project on SourceForge.net called jsext. These people are trying to build a pure javascript based server side libraries for common tasks such as connecting to databases and other stuff. These libraries will be able to execute as native server side modules for SpiderMonkey, the Mozilla Javascript interpreter.


The idea behind it is that in most web development projects, javascript is often an integral part on the client end especially these days when Ajax has become quite popular. By making javascript as an option on the server side as well, multiple language development can be cut down and hence maintainability of the software can be increased. Cool!

technorati tags:, , , ,

Blogged with Flock


Sunday, August 20, 2006

Writely is right again

Writely is out of it's self imposed hibernation now. For those of you who haven't heard about it, Writely.com is a web based document editor which was acquired by Google some months ago. Since that time, it has been not been accepting new users. Now the wait is over.

I first heard about Writely while browsing through the TopCoder forums. Snewman (one of the TopCoder's TopCoder) was the guy working with (owner of?) this company and he was discussing performance optimization problems related to the website. The site has some cool collaboration features such as shared document editing, ability to export as an RSS feed, publishing it to the public or a blog. You can also export the document as a PDF and HTML. Also you can view the revision history of a document and compare between two revisions.

Last night the SRM 316 was my comeback to TopCoder competitions after a long time. I solved the 250 but saw it going down to a challenge as I failed to handle a corner case (once again). Better luck next time.

The article was written in Writely itself. Keep checking :)

Friday, August 18, 2006

Some Google related tidbits

A new version of Google Talk has just been released. It supports Photo & File Sharing, Voicemail and Music status sharing features. Cool isn't it?

Find more information here at the official Google blog and the official google talk blog.

Meanwhile TopCoder has a lot of components related to XMPP posted these days. XMPP stands for eXtensible Messaging and Prescence Protocol. It was developed by the Jabber open source chat server/client and is now used by Google Talk as well as many other IM clients.

The international coding competition Google Code Jam has been announced and registrations have started. Google has been investing a lot of money in these coding competitions. Recently we saw a Google Code Jam for India, China and Europe. TopCoder organizes these competitions on behalf of Google. It's said that the top contestants usually recieve an open offer to join Google's engineering team. All the best to those who are participating. I think I'll be one of them :)

technorati tags:, , , , , ,

Blogged with Flock


Thursday, August 17, 2006

Open source java?

After a lot of promises it looks like Sun is finally going to open source their Java virtual machine. It plans to release the javac and the hotspot client VM as open source software in October.

So how does an open source java help? Frankly, I've no idea.  "Don't fix it if it ain't broke" is a popular quote. The present status of Java goes well with me. Things are straightforward, there's an implicit standard and besides, Sun has been handling Java development quite well. Multiple forks of the JDK may break compatibility and that's one of the major reasons Sun has been refusing to open source java untill now. And this lack of an open source license for Java is the reason that Sun JDK does not ship with any of the major Linux distributions.

Although some people have had some frustations with their promises. For example, there's no library support for knowing the free disk space on a disk partition in Java. I'd think that's an important thing. Surprisingly this has been a  feature request since 9th June, 1997 and after repeated (unfulfilled) promises, it's going to be implemented in the upcoming mustang release of JDK (version 6.0). It shows as fixed in mustang release in the bug logs of Sun.

technorati tags:, ,

Blogged with Flock


Wednesday, August 09, 2006

Object oriented event handling in Javascript

I've been playing a lot lately with XMLHttpRequest. As a part of one of my tasks, I set out to build an object oriented javascript component which provided a plug in functionality for a HTML element. Specifically I set out to build a decorator (in design pattern parlance).

I ran into a problem which foxed me for some time until I dig up some old posts in the comp.lang.javascript google group. The problem was something like this:

Suppose you create a javascript custom class which takes a UI element and attaches some event handler to it. That event handler is one of the methods of our class. Now the problem was that I was unable to access any of my class's attributes from that event handler function. Every time I tried using the this object to access a attribute, I was getting an undefined value. After some experimentation I found out that within the event handler function this refers to the UI element on which the event was attached. So inside that event handler, we don't have a handle to the current object of the class.

function MyDecorator(sourceElement) {
this.sourceElement = sourceElement;
this.someOtherAttribute = 192123123;

this.sourceElement.onmouseover = function() {
//do Something with the class's someOtherAttribute.
alert(this.someOtherAttribute); //This does not work
}
}

One way out of this problem was a dirty hack. Maintain a global variable to hold the current object. But that can only work when there's only instance of the decorator in the page. The second way was to let the javascript in the page handle the event and pass it on the appropriate decorator object.

But in both of the cases the self-contained nature (or encapsulation) of the object-oriented approach is destroyed. This problem surfaced again when I was writing a javascript class to fetch some data from XMLHttpRequest and process it's response inside the class. In this case you can't implement the second approach outlined above and keeping a global reference to the current object seems the only way to go about it. Or else I can keep aside the object oriented stuff and go about it in a function based approach.

technorati tags:, ,

Blogged with Flock



About Me

My photo
Committer on Apache Solr. Principal Software Engineer at AOL.

Twitter Updates

    follow me on Twitter

    Recently shared stories

    Recent questions on Apache Solr

    Recent development in Apache Solr