I agree with you that its not right, but its what the law says is appropriate. Not me. There's nothing you, or me, or even the judge can do about that. I have my opinion on it which is similar to yours, but I understand how the justice system works enough to look at it through an objective lens and think that the sentence for the facts of the case is what it should have been from the legal perspective.
And you're mistaken if you think I'm ok with people being jailed for possession. Up-thread, I referenced that part of the reason marijuana is being decriminalized is for this exact reason. People shouldn't be charged for possession in many circumstances. Some of the people in jail right now for it are otherwise law-abiding citizens with no prior records that made mistakes, but they're currently serving time with no real need for rehabilitation, no danger to society, and instead are wasting tax payer dollars. The justice system isn't perfect, but all judges or anyone else can do is interpret the laws as written and execute their oaths and duties responsibly.