Tuesday, January 31, 2012

My first Chrome extension

Here is my first chrome extension.. it show the first 20 pictures in Flickr photostream..

theskymind.crx

Open the link in Chrome to install the extension..

Monday, January 9, 2012

Thread Sleep in Java

There are quite a few articles online that deal with the sleep method in Threads. They deal with the granularity of the time that the thread is supposed to sleep i.e. with the lower limit of the sleep time. One such good post is this one:

http://www.javamex.com/tutorials/threads/sleep_issues.shtml

But I noticed that there weren't many places that talk about a possible upper limit on the sleep time (if there is one).  So I tried it on the following the operating systems:


Red Hat Enterprise Linux Server release 5.6 (Tikanga)

Microsoft Windows XP professional, Version 2002 service pack 3 using  
Eclipse Java EE IDE for Web Developers.Version: Helios Release,Build id: 20100617-1415


My code was pretty simple, I put a thread to sleep for 30 minutes and had a logging statement above and below the sleep statement. The thread recovered fine.

To conclude, I couldn't notice an upper limit on the sleep time.

Friday, January 6, 2012

SMTP vs IMAP vs POP3

Now I know the difference :)

Friday, December 9, 2011

Choice of Technology Stack

I was looking for the ideal stack and here is what I found online

Should you build the whole web solution with Java or should you implement real-time algorithms in Java and web site in Ruby or Python?


Actually this is a question about keeping your technology homogeneous or heterogeneous. Our quick suggestion is: the more homogeneous your technology stack is, the better. In the end it is easier and cheaper to maintain and develop.

Simple rule of thumb  is: the more your team is experienced with a particular technology, the better the chances that this technology is a good fit for your project. For example if you have a Java team with 3-5 years of experience, it will definitely develop more rapidly and efficiently than a team of junior Ruby engineers with 1-2 years of experience

Eclipse and the JDK

I thought I knew the basic relationship between the JDK, the JRE and the JVM. But then the Eclipse IDE raised a question in my mind. I want to know that if I have eclipse installed on my system, do I still need to install JDK separately to be able to compile my Java programs? Here is what I found online.

Eclipse doesn't come with a jdk but a compiler and runtime environment built in. Technically therefore you won't need to install one, though if you want to run or compile from outside the IDE (highly advisable) or want to test against the reference implementation (even better, the built-in compiler isn't 100% compatible) you should.

My new Ford Fusion and Microsoft Sync

I own a Ford Fusion hybrid which has the Microsoft Sync entertainment management system, with speech recognition. There are 20+ commands and learning them while driving can be quite a challenge. Here is what I have learned so far..




  1. There are 3 attached devices:
    1. Phone
    2. Bluetooth Audio (through the same phone in our case)
    3. USB link to Ipod
  2. Voice commands to these switch to these devices:
    1. PHONE
    2. BLUETOOTH AUDIO
    3. USB
    4. LINE IN or USER DEVICE is the super set for all 3.
  3. Simple Voice commands are
    1. PLAY
    2. PAUSE
    3. NEXT TRACK
    4. PREVIOUS TRACK
    5. SHUFFLE
    6. PLAY ALL: use when
                                                              i.      Player gets stuck in one song or set of songs.
                                                            ii.      While starting up and on PLAY says “current selection cannot be played”.
                                                          iii.      Sadly works only with USB link. ”PLAY ALL” Won’t with Bluetooth link.
    1. AUTOPLAY ON: Theoretically, should resume play from wherever the song stopped. If it doesn’t work, use PLAY ALL to start over
    2. USB if system went looking for another device i.e. Bluetooth
    3. Big round button on top right: PLAY/PAUSE, same as 3.a, 3.b
  1. Phone
    1. Answering a call – phone key on steering.
    2. .Rejecting or Disconnecting a call – hold phone key down.