Saturday, August 09, 2008

Thinking and Us.

These days I have been reading about Thinking. Well. fundamentally what it says is that the way we think or the size of our thinking makes a big difference in what we are or what we become in Life.

As I read about it I found many things to be true.

If our goals in Life are limited then our mind, body etc. will only generate enough energy to reach them. It will never try to go beyond it. It seems that there is no limit on human capacity. It is that how much we draw out of it which matters.

So, that's why it is necessary to think big and then let our unlimited potential fulfill our dreams.

Our thinking gets affected a lot by our environment, it seems. If from childhood we have been listening of defeats, disappointments and negativities then it is hard to develop a positive attitude towards Life. If we grow hearing that getting good food and money is the ultimate aim of Life then we find it difficult to think beyond them.

So, in order to be positive it is very necessary to be in good company. In our daily lives we meet all sort of people. Some are ever complaining, some are neutral and some are damn positive and wanna become something in Life. We all live in the same world, yet we have different attitudes. And ultimately it makes a big difference in the quality of our Lives.

If we look at it, Life is a ultimate gift. There is nothing to lose. We had nothing when we entered. So, there is only one outcome possible in every endeavour of Life and that is Win. Even if you are unable to achieve something you end up learning something. That's the beauty of Life.

Yet as we grow we develop more and more fears. We don't wanna take the next step just becoz we don't wanna lose what we already have. We are so attached to what we have now that we limit our scope. But that sucks. I believe at every stage of Life one should try and develop more independence. One should try and be more free, free in doing whatever he wants to. That's when you feel that you are growing, that you are living.

Really, if we are not facing failures that we are not taking enough chances.

But to come out of the cocoon of our daily lives takes some effort. It is not easy to come out of the comfort zone. But once we realize that there is nothing called comfort zone and there are limitless possibilities lying outside, we won't shy of taking a chance.

So, we need to expand our thinking. We need to remove the boundaries which we have put on ourselves. We need to think as big as possible and then proceed. Then only it will be possible to become what we deserve.

But the magic won't occur in a day. It will need effort. All the Best! :)

Happy Living. :)

Monday, June 23, 2008

Configuring Spring for your Web App

Configuring Spring is pretty easy.

Add a listener:-

<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>

The ContextLoaderListener implements ServletContextListener.

You can also configure the xml which Spring should read:-

<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>/WEB-INF/classes/context/applicationContext-*.xml</param-value>
<!--
The following param-value should be used instead if we ever want to search for context files anywhere in the classpath
<param-value>/WEB-INF/classes/context/applicationContext-*.xml,classpath*:applicationContext-*.xml</param-value>
-->
</context-param>

Hope it helps,
Thanks.

Configuring struts for your Web Application

Configuring struts in your web application is pretty simple. You have to add a filter in you web.xml file:-


<filter>
<filter-name>struts</filter-name>
<filter-class>
org.apache.struts2.dispatcher.FilterDispatcher
</filter-class>
</filter>



And then provide appropriate mapping, like:-



<filter-mapping>
<filter-name>struts</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>


So, now every url will be passed through the struts filter.

Hope you find it useful.
Thanks.

Strtus, Spring and Hibernate

Now-a-days web applications are heavily using Struts, Spring and Hibernate for developing web apps.

Struts provide a MVC-based Action Framework for developing Web Applications.

Spring provides dependency injection and thereby can be used for managing the beans in your application.

Hibernate provides a simple yet very effective ORM tool. It simplifies most of the database related stuff and the developer has to only bother about business logic.

Thanks.

Wednesday, October 11, 2006

Freaky Days Out - 2 !

Hi Guys,

I am back. I will continue with my freaky days.

So, after all music and masti we went ahead for dinner. Y suggested to have it at some 'Kaake ki Haandi' ( I am not sure wht's the exact name). With some suspicion we went ahead only to find a beautiful ambience welcoming us.

Though the place was small, the environment there was pretty good. The interior was "rural" in taste. So, the menu came and we started picking up the food. I wanted to experiment and do away with 'Paneer' as much as possible. Being in Noida, u will get so much of Panner that u will get scared of it. :~)

Well, meanwile I asked the waiters there to change the song being played. Saala apun log masti ke mud mein tha aur unhone sad song laga dala tha. They were generous enough and changed the song immediately to some Shahid Kapoor no. And yeah X got her eyes fixed upon 'Hyderabadi Moti' on the Menu and we ordered it.

Despite of my great efforts I couldn't avoid Paneer out of the food and we ended up eating Paneer Khurchan. But 'Hyderabadi Moti' rocked. It was so damn tasty.

With nice food in stomach and cool breeze flowing we three headed back to our homes in the 'luxury sawari' of Noida i.e. Rickshaw. Noida is endowned with many of them.

And alas the day was approaching its end. X and Y got very excited and were doing all sorts of things in rickshaw which included shooting a car with imaginary stan-guns. :~) I was lost smwhr, whr I don't knw, but smwhr and went to a low. ( I wish if Y were a bit less fat so that he could fit in at the back of rickshaw )

But we all knew we had a great day. X had to get down first and then me and Y headed back to Home. I was so tired by then and was thinking that the day almost ended , but only to see that there is one more twist to this exciting and enthralling day remaining ... ( Will be continued )

Tuesday, October 10, 2006

Freaky Days Out - 1 !

Hi World,

This is Rahul calling. Unlike my previous posts there won't be any discussions this time.

So, I am gonna tlk about some of the wonderful days I had in Noida, where I am currently working.

Life has taken many turns for me and it has been very interesting and fascinating to go from Pilani to Bangalore to Noida. Every where I am going I am encountering a new environment, new people and a different Me.

So, it has been a kind of evolving process for me. And I am so happy to discover various shades of my personality. And in Noida, it is the fun factor which is ruling till date.

Ofcourse I gotta give credit to the able company of my friends.

Ok, enough of bak-bak, let's come to the point . So, I was talking about fun. So, I am gonna talk about one of the most freaky days of my life .

It was a normal day, as usual people working on their systems, wondering what actually they are doing, life carrying on, when suddenly my crazy buddy X suggested to freak out. Well, what an offer ! I grabbed it with my both hands. So, we three , me , X and our very close friend Y went and blessed a Barista near-by.

Before going we decided to sing some of our fav. songs and then compose some on our own. So, we took print-outs and with all the ammunition ready attacked Barista. Now there resided a cool guitar and I don't know in what frame of mind I picked it up and started singing English no's. I am sure it was at least funny. So we sang, Linkin Park, "I am not a perfect person", "I want to break free" etc. and etc. Meanwhile, we composed a fundu song, which sounded like ->
"Tauba hamare yeh gaane, karte hain dekho hungame, gaane jo yeh hum gaane lagen hain, log Barista se jane lagen hain" . :~)

Believe me guys that was heights of creativity. And then the inevitable happened. We ordered. I asked for a Cappuchino as always, and X and Y ordered some weird Sandwich and God knows what.

With the bitter and strong Cappuchino on my tongue and tasty sandwiches with my frns, the spirits went higher. Y started dancing on "Woh Lamhe" and we joined. Meanwhile X was enjoying watching me and Y going Mad. Believe me, I just completely lost sense of people around me and with no regrets I was playing all weird and crazy tunes on the Guitar [ I pity it :( ] and adding to it my self composed songs . Y had his own set of songs and dances. And X was lost somewhere.

But guys, I did compose a beautiful song out there which was like -> "Oh Life ! I want to meet you ..." . I wish if I had recorded it.

Wht else, so we shared jokes, sung, danced and laughed like crazy people for around 1 and 1/2 hours. But the day didn't end here ... there was a lot to come . Wait for the post to be continued ... cya.

Tuesday, July 18, 2006

Krrish vs Superman - 2 !!

Hi Guys,

Thanks for your interest in the first episode of this series. :~)

So, lets continue the war. ;~)

One of the most common arguments we hear from junta is that the Indian Hero dances and sings which is very unrealistic. Now I got a different view on it. I guess this is where our strength lies. I ask why shouldn't we put songs and why shouldn't our hero dance ??

We shouldn't forget that Movies are just a medium of expression. And just like any art the artist is free to use any tools he deems suitable to convey the meaning. So, if the hero wanna express his love for his dearest, why shouldn't he sing !!

And I gotta say Bollywood music is one of the most beautiful, pleasant and sweet treasures we have. The quality of music and lyrics is uncomparable. Now I don't wanna generalize it to every crap director in Bollywood ( say David Dhawan ) but nevertheless one would agree that songs in 'Rang De Bansanti' ( by Rakesh Mehra ) were beautifully executed and never hampered the story.

As far as dance is concerned I am proud of Bollywood brand of 'dance' . Why?? , u might ask. Becoz it is not just dependent on physical movements. I have seen many English videos and I have to say that their dance just don't touches the soul, it is very much restricted to body movements ( Again, not applicable to each and everyone ). To better understand what I am trying to say just see the range of steps in an average Bollywood song. For e.g. take 'Des Rangila' from Fanna, the use of hands/legs movements, facial expressions is so beautiful, and take 'Main Aisa kyon hoon' from Lakshaya, wow! Every movement was in tandem with the theme of the song.

So, if Krrish sings and dances, it adds to his strenght. And I gotta say Hrithik is just amazing. Great movements and the whole dance sequence appears natural. See 'San-na-na, Aaj Pawan Bhi' for e.g.

So guys, just savour our own brand of SuperHero rather than uselessly comparing it to others.

Might be continued ... :~)

Saturday, July 15, 2006

Krrish vs Superman - 1 !!

Welcome to the war of the month. :) With news channels sucking all they can from Krrish vs Superman, the 'aam aadmi' wonders what the hell is going on.

Because many of them even don't know Superman. It is kind of roti vs Pizza. Now how many Indians know or have tasted Pizza ?? ( Plz remember there is a lot of India other than Bangalore or Delhi :P )

Nevertheless this makes an interesting discussion and I was really entertained by a fight between 2 ladies on a news channel, with one hailing Krrish and the other defending Superman, though I am sure that none of them really gives a damn about either. :D

But whomever you prefer, one thing is clear, Indians have declared Krrish as the winner. And this movie is creating record box-office history. So, as far as money-makers are concerned Krrish is the king now.

But lets move to a logical comparison between them. First both are different. Lets not forget that one is an Indian and the other, an American Superhero. Their cultural heritage and environment is different. Their powers are different. Their styles are different. So, as such the comparison might be futile.

But ofcourse Superman is technically better. Little doubt about that. But then I gotta say that the stunts in Krrish are great enough to excite the audience and even make them jump. I myself have witnessed people getting really excited (especially children) while watching Krrish taking those long strides. More importantly, Hrithik Roshan makes Krrish appear very real when compared to Brandon Routh performing Superman.

And I gotta say Superman costume is at most funny. I mean, u got a gown hanging from your neck, S printed on your chest and a red underwear over your pant !! Seems Superman, has dressed up in hurry. ;-P

And lets not forget that Krrish is an Indian movie with Indian budget, so its gotta be technically lagging.

Well, there are so many other things to be discussed. Lets see guys what you have to say,

To be continued ...

Wednesday, July 12, 2006

Machine Learning Continued! - 2

Hey Guys,

I am back. Well, its after a long gap. But I hope now I am more consistent.

Thanks to Mohit for his insightful comment. He mentioned some very cool points ->
  • We choose to learn or not from experience.
  • We learn from our and others' mistakes.
I believe a more intelligent human being will choose to learn from experience. Though I don't have a formal proof. So, taking this assumption, lets go ahead with building a machine which learns from experience. In absence of this way of learning, I don't know how can a machine become intelligent. Thoughts are invited in this line of thinking.

The second point is pretty cool. But I guess this also comes under experience only. This is more of a reward/punishment procedure. So, father says to the child -> if you sit quietly I give you a chocolate.

If chocolate is defined as a reward, then sitting quietly might be a fruitful activity in the future, in case the machine is looking for a reward. Keeping in mind that there might be situations in which we are looking for punishment. :~)

So, guys I think we can march ahead with this exiciting discussion.

Please pour down your ideas.

Have a great time...