June 20, 2008

Boring work details

Just jotting down things to remember….

.Net 3.0 SP1(via Aaron Ruckman) is part of Vista SP1.

.Net 3.0 SP1 is also part of .NET 3.5 :)

.Net 3.0 SP1 is only valid for Windows XP, Win2k3 servers which have the .NET 3.0.

Only in .Net 3.5 compilers have changed(bloated). Java too is taking the cue and adding load of features in next version.(heck their train is moving faster in terms of obliteration - read the “Java SE 5.0 is in its Java Technology End of Life (EOL) transition period” .

.Net 3.0 was wcf/wpf/wf.

asp.net mvc etc is oob release for now

JayRock - Rocks

return Jayrock.Json.Conversion.JsonConvert.ExportToString(items);   // items is specialized collection of suggestions :)

The above line took care of my worries of returning a json string from httpHandler(ashx). I did not want to use the new WS-* (wcf) serializer good ness and muck around with configuration(morever suddenly in iis7 I was out of ideas on how to associate new .net 3.5 compiler - and worry creeped up on me about changing the runtime when it is not really required, i will mess with wcf and its webHttp/enablewebscript binding on another day). The whole declarative coding is pain for development unless it supports the evaluate (ala lisp/python/how much I need a “active command” window where I can try the code right in before including the configuration) right then and there. Too much of configuration blues with not enough help. Yeah powershell looks good but it is not yet a generic ide replacement.

June 18, 2008

Dish 3 (thanks to Sunanda ) Soya Nuggets recipe

I have started eating the soya nuggets after having aversion for them for decades. Sharing the recipe of my sister for these nuggets - verbatim

 

Soak soya nuggets and put it in warm/cold water  for 15 minutes or till the soya becomes a bit soft to take out water from them and also the size of the nuggets will increase(so put in a broad vessel).once soaked , continue the process of putting in fresh water and taking water out for 2-3 times, this avoids the smell which normally any soya food has.Then drain  the water out of  nuggets as way we do for dahi vada.

 

Cut  tomatoes, onions in small size.Keep aside black masala..

 

Then in a vessel put a oil, let it heat up.Put onions in the hot oil and then let it get brown color, put tomatoes in it and fry it til it gets soft.Put turmeric,hing powder,chilly powder in it.Put the drained soya nuggets in that.Mix it up in the pan. and then put the lid on pan for some time.after sometime , chk for soya nuggets if prepared,If soya not getting soft, put warm water.In the last put the black masala.

 

You can make this with black chana also.

 

If want a full non veg taste, prepare the wet and dry masala like we make for non veg and use it for phodni(seasoning)…

 

June 18, 2008

Skewed priorities - No deodorants 3 decades ago to 400 M Euros in Brazil

Brazillian poor rural folks have challenge of access to sustainable sanitation facility. But there’s an mnc(Unilever) which is selling them deodorant to overcome the smell of the bodies.

While reading one of the economist article - Feb 2nd 2008, I was appalled to it  and its implication of treating “people” as potential customers. Most probably they will lure the customer by raunchy/racy ads and making them feel bad about themselves. It was as bad as feeling when I returned home after getting the first job. My uncle who works at field asked me about my work. I was trying to explain the work - his suggestion was to do something about water shortage rather than just writing software for communication, storing financial data.  It was too late to change the career track by then :(.

Anyway coming back to the article - Company’s next big target are the asians - only 7 out of 100 of them use deodorants. That is alluring. Forget the fact that many of them have challenge getting water, sanitation, access to lower priced drugs. But heck - they need latest deodorant and shampoo to get the water and sanitation.

Challenge here is - what are the ethics and how far you will stretch them for blind benefit. There is nothing wrong in selling deodorants but don’t push them by hoodwinking folks at large. Certainly not to the person thinking about the next square meal or education for the kids. Are perfumes and deodorants so neccasary a priority? Don’t even get started on role of the MNC which push/sell the aereated drinks in arid regions.

If you get the time watch through www.thestoryofstuff.com



June 11, 2008

Dish 2(morally supported) - Pasta with chaat masala add on :)

Finally Jyoti gave in to my whims and made pasta with zing of chaat masala.  Chaat masala abhorred by many  has the habit making the blandest of the dishes into savoury items. The dish recipe was picked from  website. And the corruption of the dish was carried out with my full support and push(no nudge would have worked).

Now the dish came out at the very best with rightly cooked veggies (not too soft) and not too crunchy.

May 31, 2008

DI, IoC => windsor Wins

After a long time a chance came around to use Windsor in one of the projects. While refactoring the code I realized we had coupled few components way too tightly. Thus their upgrade, pluggability were getting hindered. At that time we had very less time and no luxury of evaluating the frameworks.  Now in some down time, I realized Windsor  is a perfect lazy programmer’s helper. Do minmum independent work in one class and keep the dependency in form of behavior (interfaces).  Keep the implementation of interface at a distance and use a framework to resolve the relationship.

No I am not using it becuase it makes the testing easy. I have the pluggability as main concern. Use of factory/service locator etc was not going to give this kind of ease.  One of the days when I have time, I will trim the code and dump it here for before and after image.

A day of work with windsor convinced me about its elegant design and use. It is pretty powerful in its services/Dependency Solver/Facilities and related extensibility model.

Related important documentation - configuration (.chm file is not so good for explaining the items), it gets complex at times if you have lot of items you want to decouple. It would be wiser to use include files or Boo-DSL-Binsor.  That is the only downside of the these frameworks (spring.Net) as they make debuggability - hard. One needs to look at 2 different places for the information. 

Tip - type is fully qualified type information. When directly using kernel you may not encounter any errors as was in my case but one would be insulted when using the configuration method. So always remember this when providing information, (same applies to service information)

<namespace.type>,<assembly>

Good tutorial - BitterCode.

Download location - Castle.  They also have the MonoRail which started the push for asp.net mvc framework in many ways.

Alternatives are ninject, spring.net, pico/nano. On java side the one which is more exciting is guice. The video of guice is little better intro compared to msdn articles. But don’t worry it is just factory pattern/strategey.

Common things

- injection of constructor, setter etc, interceptors (method )

- lifetime, security + AOP concerns

- use of config files(ninject has different attribute based approach) to provide default information to decouple.

Nothing new for folks who have seen the early remoting days and evolution of wcf in its container avatarand folks who use the terms like strategey/factory pattern. Just a big time saver. It should be used carefully depending on how much time you want other people to learn a framework vs your container approach.

I wished CLR team extended the Binderand friends in elegant way for general usage, Objectbuilder(/Unity) does not inspire confidence. 

Activator.Createinstance !

Anyway - another good thing for last 2 weeks was xunit. So xunit+waitn should cover most of the scenarios for us. Compared to nUnit/MBUnit - it was dead easy( I am hoping I am not betting on always in beta work though). Battle is still on between Moq and RhinoMocks. I am still refactoring like crazy to enable most of the essential control.  Waiting for spec# to have some official lifeline.

May 28, 2008

Dish one, Jhaalmuri

Tick 1 - Jhalmuri with kolkata spunkiness done !

I longed for the spicy, zany taste of Jhalmuri and almost got there this evening. The guidance came from Masalamagic. I did not use the potatoes because boiling them takes time :). For non Bengalis/Oriyans Jhalmuri is spicier version of Bhel with very apt use of mustard oil. It also lacks the tamarind/jaggery taste thus making it truly unique and addictive.  There are versions of it which use Haldiram mixture/peanuts , but the best taste is taking fresh ingredients and using home roasted peanuts.

Only tip - Add the finely cucumber only at the time of serving.  I was not sure of the coconut getting added to it but in hindsight it should be good idea.

Notice how muri is same as churmure in marathi, mur mure in Hindi?

May 23, 2008

Is it my life?

The idea of control of time and way of death has baffelled many over long time. Well meaning governments have made sucide/euthanasia a crime. Death is made morbid and unfashionable in the ad-pushed-get-quick-riches-cure world as many other old fashioned things. But when I am old and crippled with disabilities not allowing me to talk/respond, why continue with artificial means of “keeping the body alive”?  who makes that decision?

Mr. Russelll makes  poignant point   about his life.  Just as life is welcomed, death should be too.

May 9, 2008

Kolhapuri misal at Prarthana

“कोल्हापुरी मिसळ - Misal” was introduced to me near kolhapur Bus stand as dish which sort of represents Kolhapur. In those days I was not amicable to other fav of Kolhapur - tambda/pandhra rassa.  I enjoyed misal back again from Kedarling(Jotiba).

Over years across Pune/Mumbai I have tried to find the right Misal taste, Prarthana is the closest to the ideal. Contrary to expectations, it is not hot(chilly) but is made of generous helping of usal(sprouted beans), kat, farsan, kanda, kothimbir, lal tavang.  Hotstove has a great recipe.

In Pune side, they also add pohe, some people have added potato chips/churmure etc. Anyway talking about this presentation from prarthana in Kolhapur. It comes with two while slices fresh of white bread(nope no options of brown bread) . A pot of kat(sort of sambhar) and misal. It has the addition of nicely cut onions, kothimbir etc and lemon. The dish costs only 18 odd rs and leaves you with lingering taste.

May 9, 2008

Language, culture, Religion

Control of the language also is tied to the religion in many ways and thus one see the pointless fights in India where religion is nearly the same but the culture, language traditions are very different across the region. It is offcourse sad to see the movies released with little or no regard for the languages and using the lowest common denominator and most of the time making fun of local tradtions. How many time one sees the use of proper Hindi (forget sanskrit) by comedian(again mostly having no regards for the local language) for creating laugh viz vs use of urdu for songs or even other stuff (becuase screenplays were written by non hindi/local language folks). It is simply made unfashionable and laughable (compare this to the spelling bee contest or use of proper language in other parts of the world). Me Fanatical - no no yet - just annoyed - see even now I have apologetic tone. why that need should be? )

Have time ?

Read a great piece of writing by Arun Shourie. The attempts of missionaries to dump everybody else as animalistic and need to be “saved”. If the paths are different - let them be. But don’t come in to “tout” the horn and save others. They will be saved, who are you to save anyone?

Mosques of India (Hindustan ki masjiden) (via Maulana Hakim Sayed Abdul Hai ’s translation) , guess what were they built on or using what materials were they built? Yeah apologist secularists of the infamous kind will come around to talk about fratericide and duels between Chalukyas and others or native rulers. Point is most of them rebuilt grander temples but not replaced it with another foreign religion icon. Puhlease leave to your favourite middle east destination or the evangelical land now to get salvation or freedom you crave for. Sad thing to see was that this was all known and documented but susbstituted in English edition of the book.

For all the apologetic secularists and hideous communists this comment from AS should suffice

“Or M.F. Husain. He is a kindly man, and a prodigiously productive artist. There is no warrant at all for disrupting all his exhibitions. I am on the point of sensibilities. His depictions of Hindu goddesses have been in the news: he has painted them in less than skimpy attire. I particularly remember one in which Sita is riding Hanuman’s stiffened tail — of course, she is scarcely clad, but that is the least of it: you need no imagination at all to see what she is rubbing up against that stiffened tail. Well, in the case of an artist, that is just inspiration, say the secularists. OK. The question that arises then is: How come in the seventy-five years Husain has been painting, he has not once felt inspired, not once, to paint the face of the Prophet? It doesn’t have to be in the style in which he has painted the Hindu goddesses. Why not the most beautiful, the most radiant and luminous face that he can imagine? How come he has never felt inspired to paint women revered in Islam, or in his own family, in the same style as the one that propelled his inspiration in regard to Hindu goddesses?”

Offcourse the few european  countries allow the expression of freedom where Gods(of either kind) were painted on the undergarments or burnt or dealt in any other way so as to destabilize, shock the majority of believers. Rememeber the head gear controversy, use of madonna, Ganesha or other gods on undergarments/toilet seats etc.  The challenge is in the world where the faith is part of everything in place like India. Europe still does not like “its” religious icons destabilized or the latest controversy about the dutch film on Islam. But this will continue…

January 21, 2008

Break

via kaavyalaya

झाड ऊँचे और नीचे,
चुप खड़े हैं आँख मीचे,
घास चुप है, कास चुप है
मूक शाल, पलाश चुप है।
बन सके तो धँसो इनमें,
धँस न पाती हवा जिनमें,
सतपुड़ा के घने जंगल
ऊँघते अनमने जंगल।

 woodway homestay

In the recent break at Woodway homestay the coffee estate of the wonderful hosts (sushmita & shreedev) felt the same.  The drive to the place is hassle free except stretches of city travel of Hassan.  Easier way would be to take the bypass. Sushmita is detail oriented and takes the food preference, finds out about the age groups of people, dumps the detailed driving directions. Once you are cosy in the homestay - you get santosh’s good food and Sreedev’s humility and generous knowledge about the area, cultivation of coffee.  The stay is clean, simple and can accomodate multiple groups and has activities for the people who want it. Only kids can be bored if there are no other kids around to play with.  Cost can seem little higher but then you need the break. I hope once things settle down she can offer packages for longer stay.