Pages

Google Chrome - A Quick Look

Installation
Downloads very fast. Installs very quickly. Very easy.

Browser Startup
Very quick indeed. 10 times faster than ffx I'd say. Really lightning fast. Lets wait for some more features to add to it, like plugins etc.

Page Loading
I don't think browser can do much if your internet connection is screwed up. I didn't find any noticeable difference in terms of loading a page. For real benchmarking, test highly AJAXified sites on chrome. According to developers, V8 and WebKit would make rich internet applications work faster on chrome.

UI
Truly Awesome. Almost no UI. All you see is your webpage. Full marks for UI engineering. All not-so-used buttons/controls (which clutter up other browser's UI space) are safely hidden.
Window's title-bar's space is utilized for displaying tab. Even the browser's name is not shown anywhere on the screen. Looks like not a single pixel is wasted.

Tabs
Extremely Flexible Tabs, Pull out of one window, Push it in other window.
Secure. If one tab crashes, whole browser wont go down. (ffx3 on vista has become real pain in this regards)

Shortcuts
common shortcuts keys should work like they work for ffx/IE.
CTRL+TAB, CTRL+SHIFT+TAB, F5, CTRL+N, CTRL+T etc.
(They SHOULD work, for ease of new users)

Address+Search Bar
Address bar can act as search bar as well. (hmm...)

Application Shortcuts
drag and drop web applications shortcuts on desktop (..not a great deal, at least i think so)

Well well well....you can read about more features (downloads, security, incognito window etc) on chrome's site. Why am I wasting my time!!

Conclusion
Truly a new generation browser. Its worth giving a try. Very light weight and fast. Smart, streamlined and intuitive UI. But in the browser market, it has a long way to go.

Google Chrome

There was a time when browser used to be a separate application that was not a standard part of Operating System. People had options. Then came a big giant, and things would never be the same. Air would never be clean again. A cold war was set off. Do I need to tell more?

Internet Explorer, the blue E, had become synonymous to internet the same way Windows became synonymous to computer. [I have deliberately used internet in place of browser and computer in place of OS, so please, no hullabaloo regarding the same ;) ] . The little blue E was made an inseparable part of ubiquitous Windows. Though there was an Antitrust suit blah blah.. (which I don't want to discuss here).. it hardly made any difference.

Time kept passing by. The big M had now become a symbol of tyranny. The little E kept reigning the browsersphere. Given the backing of the big M, nobody could move E from its throne.

Meanwhile there was born a little g (then little), who had all good intents of organizing information. Little g would not intrude into business of others. It would just innovate (or take over small fishes in the pond).

At around same time a little m was born. By 2004 little m devised its flagship product named ffx (firefox, if you don't know). It was open source browser, all set to set all the records straight with M for whatever it had done to the poor chap NN (Netscape Navigator). And by far, it is climbing the ladder of success, successfully.

During all this, little g's growth had been exponential. Its journey from little g to bold face, font size 64, underlined, hyperlinked G was record breaking, jaws dropping.

G liked the good deeds of m. Shook hands. Together they looked like becoming a synomym of web 2.0. Glory of browser was coming back. People started realizing that Internet cannot only be explored by IE (and also computer cannot only be operated through a small service Window). G was ruling the web.

G should be having data of users like no other on the planet. G's offerings were increasing day-by day. G Offered win-win situation for businesses and end users by its Advertising services. G took control of everything, from search to email, blog to documents, code to health, finance to patents (and the endless list goes on). But somewhere in the back of its mind, G realized that all services it provides are still accessed through a medium (browser) on which it has little control.

Bang!!!! G lunched its own browser named chrome. They are giving good reasons as well. (Psst psst... has it got anything to with impending release of IE8)

As of now (2-Sep-2008), it (like all other Google products) is under Google's cool, all-new, exclusive forever-beta tag. Do they also think putting beta is trendy? because gmail, after 4 years, still has beta.

Anyways, I've always liked almost everything Google has offered. And am going to try this out as well and very soon gonna update you about it.

PS: Don't be deceived by the cynical language of this blog. I am a Google fan. I have respect to MS as well. They have done a lot good to the computing world. Please don't always disparage MS. It should really hurt the good folks working there.

PPS: Throughout this blog I have not mentioned the super brand with little i (and their broswer Safari). And also the browser with big O (Opera). This does not mean their contribution is insignificant. They were not here just because they would add a very little to the discussion. Now I have mentioned them, I feel better. Feel much safer from those iFanatics.

PPPS: You can find more on browser comparison (and almost anything that you can think of) on wikipedia

Delete data from tables

Ever needed to clear all the data from your database (usually while in development)?
You can use this script to clean the tables. It will work for oracle only, AFAIK.

-- script to clean the tables (ie the deleting the data only)
DECLARE
cursor c1 is select distinct table_name from user_tab_columns;

BEGIN
for v1 in c1 loop
dbms_output.put_line('cleaning '|| v1.table_name ||'...');
execute immediate 'Delete from '|| v1.table_name ||'';
dbms_output.put_line('done');
end loop;
dbms_output.put_line('completed');
END;

Disclaimer: I hold no responsibility for the havoc this script may create on your database ;) never use it on production databases.

Presentation on Log4j

I had presented this some time back at my workplace. May be you'll find it useful.

Log4j Logging Mechanism
View SlideShare presentation or Upload your own. (tags: log4jjava)

Interesting Identifiers in Java

Ever seen a declaration like

_ _ = new _();

or call to a method like

System.out.println(_._());


Try this example, you'll see, these are valid java statements.
read on..


package test.identifiers;

/**
* example that shows various legal identifiers
*
* @author Kunal
*
*/
public class LegalIdentifiers {

int $1 = 1; // valid
long _6 = 6L; // valid
char t = '\t'; // of course valid, did u have any doubt ;)

class t{
}
t $; // now here t is type & $ is object of type t

class _{
int _ = 0;
int _(){ // method with name of constructor
return _;
}
}
_ _ = new _(); // _ is an object of type _ (underscore)

void display(){
System.out.println(_._()); // interesting, isn't it?
}
// this is not a fill-in-the-blanks question
// it actually compiles and runs :)

// this means
String String = "String"; // is valid
// yes it is !!!
// so you can have variable name same as class name

public static void main(String[] args) {
(new LegalIdentifiers()).display();
}
}

Felt like writing just Anything

Once again i am feeling like writing. The same old story about not knowing what to write. There are things in life that make you feel good or bad. Almost everything you feel about something/someone can be boiled down to these two adjectives. Still we have coined thousands, if may be not a million, of adjectives to define every feeling defined in the world. Yet at times we run out of words to express ourselves. Language is the medium of communication, a medium to convey your thoughts to the other person (in fact to computers as well, now a days). It is a way of communication. It is One of the ways. This gives way to a thought that there are of course other ways as well. A hug of a friend is just irreplaceable with thousands of words. Sometimes a slap gives a better message to a kid than hundreds of warnings. You cant shy in words better than your eyes. Beauties can be defined in words but can never confined to words. All this is just a random musing over the very thought of writing something. I felt like writing something. I did it. I cant bound experiences in word but at least they give me power to share something about it. Without them (words), I could not have slapped this keyboard or stored my tears on the hard-drive. I think this is all for now :)

complicating things to get rid of complications

This blog is dedicated to me ;)

Well, as the title says, I really keep on complicating things just in search of some perfect solution that will take all the complications out of the thing/task at my hand. I think I will blog, I have had drafted many small articles which are still not complete. Always procrastinating things in hope of that golden day when every word written by me would seem perfect to me & finally I'll be able to post it.

I do code to earn my bread & butter. I have observed that I keep on refining/refactoring the code until everything becomes so customizable that it gets too complicated to understand at first sight. I have seen people who just do the work. They do great. They almost never drive themselves crazy for just a freaking line of code which doesn't seem right to them.

The point is to understand the 80-20 principle (Pereto's principle). 80% of work is done in 20% of time but the rest 20% takes the 80% of time to complete. This principle is amazingly true. Notice the time spent on each activity, even the trivial ones. We tend to spend a lot of time on the 'finishing touch'. And if you are not doing so then you are already on your way of learning the art of time management. The art is to cut the rest 20% of work at the point where you can just say you have completed your task. (Say at 90%... you saved 40% of total time just at cost of 10% of work.)... Well it’s easier said than done... :)

In fact, I fall in the category of those pigheaded perfectionists who consume whole 80% of time, still reach to 95% then again waste 20-25% of time & even after that believe there is something left to be done. And this last portion of work which I do really looks like a Monalisa hung on bathroom’s wall. It was really not needed. It doesn’t actually blend with the quality of rest of the things in place.

I do really waste a lot of time. I just can’t understand that why I complicate things so much. How do I convince myself that 90% is enough and is more than what is usually expected or done? Will write something more on the same topic, some other perfect day.