Spießrutenlaufen was used by the military and was a severe, often fatal punishment. It was certainly not a great educational tool.
With my University diploma I've also got a rank of Lieutenant-reserve of РВСН (https://en.wikipedia.org/wiki/Strategic_Missile_Forces) so the procedure is metaphorically close :D