Sunday, June 10, 2012

Ok..its been a while, spent diligently in technical retrospect and learning. The Oracle vs. Google debacle nearly shook the technological world at its foundations, since Oracle was trying to get the legal systems to say that APIs are copyrightable. Oracle nearly got away with it, and that would have been terrible for JAVA and all JAVA based platforms and companies who would suddenly owe their existence to Oracle, and would be forced to pay royalties to continue to live. Made me wonder..what else exists out there which lets us create cross platform systems that can run an enterprise? Researching this opened a whole new area that I had been oblivious to before...and that is what this post is about.
PHP and Perl are great languages that offer both server side and client side programming capabilities which are free from the tentacles of Oracle. I enjoyed learning these and dabbling with them. Reminded me of a cross between JAVA and old-school Visual Basic. I am quite convinced that all that once was considered best done in JAVA can now be done quite easily in these open source languages and platforms. I strongly recommend these. MySQL  and POSTGRESSQL are awesome alternatives to proprietary databases, which remain open source, though I remain wary of mySQL since its really owned by Oracle, where Mr. Larry Ellison feels that he can change the meaning of ‘open source’ to fill his coffers.
So, people, before Oracle gradually starts milking everyone for using ‘their’ supposedly open source JAVA, I strongly recommend moving slowly away to something that Oracle has not yet gobbled. It will help you survive longer..especially if you are a small scale developer or a startup.

A f(r)iend of mine..Ritu posed an interesting question.

“I am looking for some good resources for MVC patterns. The idea is to build a UI that sources data from the SOA infrastructure and be extended to be hosted on both desktop and mobile platforms.”

Now, considering the whole monologue about JAVA, before this, I realized that while JAVA offered plenty of MVC patterns, my technical conscience would not allow me to recommend a JAVA based solution.
While one can create their own pattern I would recommend using a pre-built framework. Such frameworks allow structure and standards to be enforced, which at an enterprise scale are much needed.
Here are a few examples of some good ones:
1. PHP: CodeIgniter. A good reference for MVC in PHP is this book.
2. Ruby, on Rails: This merits a little more discussion. What Ruby and Rails bring to the table is a very strict (and very different) templating language and framework for rapid MVC based web app development. The learning curve is much higher than PHP, but you save that time by getting basic apps up and running rapidly. Such templating mechanics represent that age old paradox. It was developed to create a fixed and well defined way of ‘doing things’ only in the Ruby way. Then a whole lot was done to give developers the ability to  do things differently or in a customized way. This tug of war leads to a bit of confusion, but in the end, the developers win...so it's a good thing.
Both these platforms and techniques, although very different, offer very good and solid MVC app foundations.
But wait..what about mobile?

Off late, I have become quite convinced that building native apps is really not the way to go, since the various App stores are very greedy. I really like the emerging trend where HTML5 mobile apps are becoming so popular (refer to Financial Times mobile app, which is a pure HTML5 app). My recommendation would be to create the MVC infrastructure, and create a lightweight rest web service with JSON to talk to a  mobile skin built with HTML5 and other resources like JQuery Mobile. If you want to really make native apps after you have built your HTML5 app, you can always use tools like Phonegap to create native apps.

The key is to remember to expose your model a.k.a. via a web service (lightweight and simple like REST with JSON is always preferable) so that the same model can be used in the same way with the same business logic by web, desktop and mobile apps. Resist the temptation to make your apps talk directly to your database/model.

Go open source as much as possible, otherwise get ready, it's only a matter of time for sharks bearing the Oracle copyright come to take a bite off you..

.. and so says I.

No comments:

Post a Comment