Yes, prison terms would keep future bureaucrats from attempting similar actions.
Sadly, I think not. Not unless this is punished on a regular basis.
There are too many petty bureaucrats everywhere who use their power to harass others and make themselves feel important and powerful. It’s not just for political reasons, either. Sometimes it’s for bribe money. Sometimes it’s a favor to friends. Sometimes it’s just because they get off on hurting others or jerking them around.
Ever try to get a building permit in most places? If you’re not part of the “in crowd” - professionals and contractors known to the bureaucrats - they make the process very painful and nearly impossible.
Still, I’d like to see plenty of jail time for everyone connected with this. It would be a good start.