Archive for the 'Tech' Category
“India is facing a serious talent crunch”

Dear Reader,

Well well… just been watching a program on BBC World. Appartenly the second fast growing economy, that is India, after China of course, is running into a shortage of IT professionals. They will face a shortage of IT-savy people in the next few years, they say… well that is if the expected growth rate is to be as predicted. And only then. On the other hand it means, India is still producing too cheap. The bubble is still expanding. There will come a time, when indias price level will be high enough, so that it will come apparent, that masses alone cannot do the job alone. In high price/labour level countries, creativity is what you get paid for in the IT sector, not slogging.

talent5.jpg talent4.pngtalent7.jpg

When the internet bubble bursted, invenstment went down on IT. Leaving a whole lot of people unemployed who got used to big salaries in the boom but who actually had too little eduction in computer science, or none at all, in order to survive the transition to reduced demand and hence to better educated employees.

In 2000, lots of people used to be professionals in something far form IT, like gardening. But at the time, when the CEO entered the conference room, overlooking the garden in front of the lobby, he used to go: “Who the hell, employed the gardener! We have IT workplaces unused! If the guy can cut a tree, he must also be able to use a mouse! I want to see THAT guy out at the customers site by next week! AT THE LATEST!”

The downside to this story is that, at least here in Switzerland, quit often some ex-IT people who happend to realise that they couldn’t keep up with their new standard of living, go totally crazy and started killing their families and so on. It happend often here after the bubble crush… (There were lots of discussions on this in the national newspapers with topics like this: “how dangerous are IT guys?” However, they didn’t see the connection to the Internet bubble crush. They thought the IT employee is a potential killer by nature. Oh well…)

talent10.jpg talent6.jpg talent9.jpg

So my Indian fellows, I have seen a lot of eagerness in learning lots of stuff, “EVERYTHING” if possible, amongst you fellows, when I visited Bangalore in late 2005. However, those of you who want to make it into the next round, those of you who want to survive the thinning out will have to take the next step. And this will happen due to increased standards of living in India (The IT centers Bangalore, Chennai, …) in the long run and may even sooner happen due to the Chinese economy that is catching up (and that is still not running short on IT staff - yet - as YOU are…)

Learning books by heart will not help you then. There has to be genuine creativity. Unfortunatly one cannot learn that. And the harder one tries to pretend it, the worse it gets to have to witness it.

Here my advice on behalf of creativiy is: less is more.

P.S.: But that just holds true for India and China. In the relaxed world, the part with the lazy teenagers, the U.S. and Europe, for them my advice is: more is more and even more is better but probably still not enough in the long run - You savy Indian guys who read the text books on macroeconomics and social sciences (and the purely creative minds) got the clue, right?

Thank you.

Spring Webflow on top of Spring MVC

Dear Reader,

I am currently trying to integrate Spring Webflow on top of an application that has been written using Spring MVC approaches. That is especially this kind of controller methodology (from the Spring MVC part):


public ModelAndView showListOfferPage(HttpServletRequest request, HttpServletResponse response) throws Exception {
//...
return new ModelAndView("path/tomy/viewJspFile", "dataKey", dataValue);
}

However, from what I’ve learned so far on Spring Webflow, all the View navigation decision is done in the Flow definition. This raises the question, how to intermix the different approaches. What confuses me is that in none of the examples seems to be any “context (request) aware” Class…

In every case, the controller layer needs the request object to extract data from it… So I would expect something like this:

public void showListOfferpage(HttpServletRequest request, HttpServletResponse response) throws Exception {
//... do stuff
// return nothing, as this is handled by the flow
}

I started a Thread on this topic on the Spring Framework Support Forums. So far it looks as if I had to answer this myself.

Let’s have a look into chapter 11 and 12 of the book “Expert Spring MVC and Web Flow” by Seth Ladd et al. This is an excellent book on the topic and very clearly written. The Webflow API from the book is a bit outdated. There have been some renamings, but with a look at the API of the latest release in combination with a bit of surfing the Spring Framework Support Forums, this should not be a problem.

Page 312:

Impletation Agnostic - Secondly, Spring Web Flow is deliberately abstracted away from the Servlet specification. […] there is nothing web-specific about a flow definition […] At now point within Spring Web Flow are you presented with an HttpServletRequest or an HttpServletResponse.”

Well, that’s great but I need some way to plug the stuff together… I’ll find out… You will find an answer right here really soon.

Ok. Looks as if I missunderstood the “plug and play” property of Webflow…

Yes it is agnostic of the MVC framework it works with. Its tied to that using FlowController, ExternalContext and ViewResolver. But No, it doesn’t let you plug it on top of your already coded Spring MVC Controllers, like SimpleFormController or MultiActionController. The controller part is defined completely in the webflow definition. The MVC controllers are replaced with Spring Webflows Action’s.

This I conclude from a bit of reading in the previously mentioned book and on these two discussion threads:

1) from The Server Side

2) from the Spring Webflow Support Forum

Erwin Vervaet says in [2]: “So a typical application will mix both Spring MVC and SWF. Use simple controllers like SimpleFormController when that is all you need. When you have more complex flow requirements, use SWF.”

and Keith Donald in [1]: “On the other hand, if you already have a lot of flow type stuff implemented in Spring MVC, perhaps using the AbstractWizardController, well, yea, you have a conversion effort there if you want to web flow that existing code. But I think you should think carefully if that is worth doing: if what you have already built works, why change it? AWC works and will continue to; web flow will provide more power/flexibility where it is demanded.”

So I changed the bits and pieces I want to have as part of the Webflow framework like this:

from Spring MVC, using org.springframework.web.servlet.mvc.multiaction.MultiActionController

public class MyAction extends MultiActionController {
public ModelAndView getOffers(final HttpServletRequest request, final HttpServletResponse response) throws Exception {
List offers = offerService.find(IOffer.class);
return new ModelAndView("pro/secured/offer/offerList", "offers", offers);
}
}

to Spring Webflow, using org.springframework.webflow.action.MultiAction

public class MyAction extends MultiAction {
public Event getOffers(final RequestContext context) throws Exception {
List offers = offerService.find(IOffer.class);
context.getFlowScope().put("offers", offers);
return success();
}
}

Thank you.