Sunday, January 25, 2009

Far far away by shady shores of Arabian Sea lies a reclusive industry called Bollywood. An industry that produces almost 1000 feature movies every year of which 95% go to trash. An industry that once provided a safe channel for under world mafia's to siphon off their black money. But its also an industry that produced some of the pearls of film industry, some we know about and most we don't. This Bollywood produced ever green singers like Kishore Kumar, Lata Mangeshkar, Md Rafi and Manna Dey who have sung some the most difficult songs in some of the most challenging Ragas. No, not much of Hollywood ever heard of them. A few names who once in a while popped up are the ones who were already in their late 30s or 40's. Aishwarya Rai, Om Puri and now Anil Kapoor have made some name but they are too old to carry on or be able to establish any platform for others to take advantage of. Anil Kapoor for example, this not so handsome actor has given some of the most bone chilling performances in Hindi Cinema but remained an unknown till Slumdog Millionaire gave him a role to appear. His performance in SDM is no means any extraordinaire but its about standing on a platform that everyone is looking at. And this platform is called Hollywood. That's why Dev Patel and Frieda Pinto are important. They have not only produced some good performances in an internationally known movie but their age is by their side. And they are known as Bollywood actors.

60 years ago when the world questioned the framework of India, when they talked about independence of princely states, when nations were created based on religious partitions and questioned the concept of one Bharath, India adopted a secular, democratic and republic constitution. A constitution that guaranteed equal rights to majority and minorities and to Men and Women. A constitution that gave freedom of religious practice, right to speak and right to vote and a constitution that abolished untouchability and titles. It reiterated that Bharath was always one nation be it south, north, east or west or composed of hundreds of quasi independent states. After 60 years we have to salute our visionary leaders that penned down one fact that its not the riches of a few, or one language or one religion and one culture but the real wealth of a nation is in the freedom of its people. The constitution of India was a slap on the face of those who talked about religious division and unilateralism, as Indians that we all should be proud of. A poem to salute the Indian constitution:

Monday, January 19, 2009

This is a question almost everyone is asking today and many believe it. MLK's dreams were already fulfilled when you had a company's CEO of an African American decent. His dreams were already fulfilled when you talked about your illness to an African American Doctor. His dreams were already fulfilled when you had a business owned by an African American running next to one owned by a White man. Obama's election as the Commander-in-Chief is just the pinnacle and possibly the fruit of his dream. MLK's work reflects one from a similar political and social legend - Dr. B.R Ambedkar of India. Ambedkar's work towards social justice revolutionized India's social equations forever. But India saw leaders from the community which Dr. Ambedkar fought for, becoming State Chief Ministers and even the President of India years ago. But has the struggle stopped? Is social justice achieved? Is the dream already fulfilled? No, Only its face has. The struggle is still on. Unfortunately In India today it has become a tool to play power games. It has become a number game to exploit the Democracy. So the dreams of social justice is not fulfilled when you end up with a President or a Prime Minister, it is fulfilled when he or she makes all and everyone feel equal and the same. The dream is fulfilled not when you have just a black President but when Whites, Asians, Indians and every American looks up to him as his or her own leader. His dream is fulfilled not if the color of the President runs the office but when the Content of his character runs the nation. Obama feels like a sweet breeze and not only Americans but the entire world looks up to him. He stands today on top of MLK's legacy. The legacy that talks not about the color of the skin but the strength of the character. America is proud to elect Obama as it's President now the onus wrests with him to keep all the residents of American nation proud and then only MLK's dream would be really fulfilled.

Sunday, January 18, 2009

In this series about building JMS on top of reliable and fast Oracle Coherence data grid, I added the functionality of a JMS Queue. Projects like ezMQ re-iterates a fact to perceive Coherence data grid as a high availability System of Record not mere a Cache Provider. The solution to build a JMS Queue is a little tricky compared to implementing a JMS Topic on top of Oracle Coherence. The reason is inherent behavior of Coherence to broadcast the cache events to all Map Listeners. The solution revolves around the following method:

The method collects all the registered Listeners on that Cache node, picks one from the list randomly and dispatches the Map Event to it. Second component is a Custom NamedCache that extends Coherence's WrapperNamedCache. The key method is it's addMapListener ().

And then at the end an EntryProcessor that makes sure even if Listeners are distributively registered one and only one of those Listeners receive the message. This is done by setting an event dispatch state that every thread checks against before dispatching the event. The class is pretty simple as well:

Friday, January 16, 2009

Einstein once said the following on Mahatma Gandhi - "Mahatma Gandhi’s life achievement stands unique in political history. He has invented a completely new and humane means for the liberation war of an oppressed country, and practiced it with greatest energy and devotion. The moral influence he had on the consciously thinking human being of the entire civilized world will probably be much more lasting than it seems in our time with its overestimation of brutal violent forces....We may all be happy and grateful that destiny gifted us with such an enlightened contemporary, a role model for the generations to come". It seems today we are already forgetting him. Martin Luther King achieved an almost impossible dream following Gandhian Principles and so did Nelson Mandela. Faith in yourself is the first thing that Guns kill. As the world burns today, path that Gandhiji, MLK, Mandela and numerous other leaders who championed non-violent means are being burned as well. Let us remember this January two stalwarts of this era and hope we re-learn the ways they showed our generation and coming ones.

Monday, January 12, 2009

Bush says see India loves me. Yes Sir we do. If 10 terrorist hold the entire Mumbai and the nation hostage for three days and not even a single missile was fired to where they came from or invaded the country then Yes we wished if we had a President like you. Who doesn't love wars? We love retaliations. Why to sit on table to resolve issues and talk and arm twist politically and cut aids and put international pressure to choke hell of their breathing when we can just settle it on the ground with Guns and Missiles? Would we be the first to do so? Romans did it. Alexander did it all the time. Our history is full of it. Europe is built on top of wars. Did we forget our own history? Don't we know what works and what does not? If political drama would have worked why United Nations had sucked so much? World wars were fought and the major actors became super powers. War is good. It makes you a super power. At least it makes you feel like one. So what if you lose moral standings, you lose economy, you lose 401K but you should never lose the pride of showing your muscles. After all Men are meant to fight. Yes Sir we love you. Can we outsource our Presidency?

Saturday, January 10, 2009

Months ago I wrote a program to integrate Calendar with Twitter. This time I integrated Twitter with Coherence data grid. Programmatically this is no brainer - data are being put in a Coherence Cache and then there is a cache listener that publishes the data (message) to twitter. I am a big fan of Twitter. Simple interface, Revolutionary idea and an Awesome channel. So what I did is expanded my implementation of JMS Subscriber for Oracle Coherence and added an interface to tweet the JMS Message. Read more about ezMQ here.... Following is a sample code that is a subscriber of Coherence Topic and a Publisher to Twitter:

Friday, January 09, 2009

Hello Sir, I have been flying United for a number of years and chose this Airlines in hope of a good and on-time service. My friends call me crazy for the level of travel I have done and my body has adapted to it. My work typically requires me to take long flights and of course to places where time difference matters. It gets frustrating when the flights are delayed for hours as it not only disturbs my schedule but puts a lot of pressure on my body. I am not talking of delays due to weather or Air traffic control. Lately it has been happening due to technical failures of the aircraft. Take an example, reaching at 2AM and then sleeping at 4 does no good to me to be at work next morning at 9. Reaching home late spoils the entire next day too. I am no President of United States but my time is precious as well. Clients do not care if my flights were delayed and I hope you understand it. I do not want to leave the kind of work I am doing because United Airlines is adding more stress than I already get myself into. Remember, I have a choice too.

Wednesday, January 07, 2009

I have come across many applications that use JMS infrastructure to pass messages from one system to another. If you are already using Oracle Coherence or thinking of employing one then for many scenarios you do not need to have another messaging provider. ezMQ is an effort to provide a JMS implementation on top of Oracle Coherence. Do not confuse this project with Coherence's Incubator Messaging Pattern. The scope and target use cases are different even though it can be easily integrated. So if you are fed up with additional licenses for a JMS provider for straight forward usecases or looking to consolidate the infrastructure, the project ezMQ lets you keep your current application unchanged and gets it integrated with Coherence infrastructure by replacing and deploying just a few configuration files. The project is a stab to address this unique problem space and even though does not guarantee to work in all scenarios but the code is available for free download, make updates to and share it further. More details on ezMQ can be found at http://sites.google.com/site/miscellaneouscomponents/Home/ezmqIf you have an application similar to the following then you can use Oracle Coherence as the JMS provider by using ezMQ APIs. The only change set the jndi.properties or the Context.PROVIDER_URL.

This version of ezMQ is pretty basic and does not implement all the bells and whistles of other popular JMS providers but it works beautifully and provides a platform to expand. How is it implememted? There are two aspects of creating a JMS implementation: