Hmmm, this is a pretty interesting and difficult issue. I don't have very well-developed views on this, but neither of these choices - retributive or rehabilitative - seems overwhelmingly desirable to me from a purely abstract, philosophical perspective. I tend to view a restitutive/restorative system of criminal justice as at least prima facie more desirable than the pure forms of either of the alternatives. I think, and I hope other people think similarly, that the primary focus of criminal justice should be directed towards the victims of crime, and I don't think what we currently have really lives up to that ideal. Thus, I think the focus of criminal justice ought to be restitution. I don't see how a purely retributive system of criminal justice would even be close to ideally just. What exactly do the victims of crime get out of this system other than whatever small amount pleasure they might get from seeing a criminal thrown in jail for some amount of time? It does not even come close to restoring the victim to his or her status quo ante condition.
A restitutive view at least addresses that issue even if there are some fundamental difficulties for the view, not to mention the difficulty of what is supposed to count as restitution in the case of murder. And anyway, it looks as though we could, at least prima facie kill two birds with one stone under such a system if we could calculate what would count as appropriate restitution for various cases in such a way that the expected chance of being caught for a crime plus the expected cost conditional upon being caught at the very least nullifies the expected chance of getting away with it plus the expect payoff.
As far as the comparative desirability of imprisonment versus rehabilitation in "consequentialistic" terms goes, I don't have much to say other than that I suspect that the perception that this is a genuine dichotomy is due to lack of imagination.
edit: I should also add that I have some sympathy for Dakryn's view, although I find his seemingly gung-ho attitude towards the death penalty somewhat worrying. He's right, however, that the prison system in this country is a huge drain on resources. Much of the growth in the prison population in this country can be attributed to drug-related convictions. Stop the drug war and get rid of these puritanical drug laws and you kill two birds with one stone.