There is little doubt Aberdeen fisherman and factory worker CJB could have been jailed for the abuse he inflicted on his wife and daughters.

The man, who has not been named, to protect his children, ran his family through a combination of sustained violence and fear and the charges he faced at Aberdeen Sheriff Court in February covered numerous assaults across 17 years. For his daughters the abuse began when each was about seven and continued into their teenage years.

He pled guilty to charges which the advocate depute described having left a "trail of human misery". He assaulted his wife with fists and feet, struck her head against the floor, pinned her against the wall and grabbed her by the neck. On 'various occasions' he dragged his daughter by the hair, kicked her, struck her head against a fireplace, pinned her against the wall and grabbed her neck. His younger daughter was punched and held by the throat, and had her head struck against the ground. The wife and younger daughter were both threatened with a knife.

There were elements of what is now acknowledged in law as 'coercive control'. He accused his wife of inventing the fibromyalgia she suffered from. In the incident with the knife, he gave it to one of his daughters and told her to stab him.

His offences were often aggravated by alcohol but his daughters testified that he was angry and abusive whether drunk or sober.

So on the face of it you can see why some found the sentence imposed - a restriction of liberty order and a probation order - an example of 'soft touch' justice.

In respect of his conviction on three accumulated charges, in relation to each of the three victims, CJB was sentenced to two years supervision and 220 hours of unpaid work in the community. He was given a curfew banning him from leaving his house from 8pm to 8am every day for 11 months.

This week an appeal ruling was published rejecting an appeal against the leniency of the sentence.

Three judges, led by Lord Justice General Lord Carloway refused the appeal on the basis that the original Sheriff's reasoning was sound.

While the advocate depute advanced 10 similar cases in which abusive men had been sent to prison, the judges felt all had other aggravating factors or different circumstances.

CJB's marriage ended in 2015. He has not offended further and is in a stable long-term relationship with a "pro-social" partner (it is not clear from the ruling exactly what that means)) and has taken steps to address his drinking. He has been attending counselling to address his own mental health issues which include attempted suicide.

So did the sheriff's sentence meet sentencing guidelines? The judges believed it did. The curfew meant CJB could not work offshore and lost out on work, and community work was a punishment. The public will be protected, because the court heard CJB does not pose a continuing risk. Rehabilitative work can take pace in the course of his community work. And the sentence meets the need for expressing 'public disapproval'.

Yet still it seems unsatisfactory and many will sympathise with the advocate depute's argument that The sentence failed to satisfy the need for "retribution and deterrence".

But I don't think we should let a desire for "retribution" cloud our sense of what is in the public interest. The justice system's view is that prison should be the sentence of last resort, and that has translated into a public view that it is the harshest or toughest or best outcome for victims.

Is it, though? What chance would there be of CJB or others like him being rehabilitated in jail? Or are they more likely to emerge a greater risk?

A report this week on HMP Grampian, where he would likely have been sent, warned staffing problems are so severe that the prison struggles to address violent behaviour within the jail, let alone when inmates return to the community. "In reality, almost all areas of the prison were negatively impacted by staffing shortages" Her Majesty's Chief Inspector of Prisons for Scotland, Wendy Sinclair-Gieben said.

Similar issues are seen across the prison estate - regardless of the best intentions of many of the governors and prison officers working within them.