Generally, however funny or bad this sounds, justice isn't the only objective of a justice system - various kinds of impact on behavior are other reasonable goals (you might believe three strike laws to be just but oppose them because it incentivizes to murder witnesses), as is lowering the cost of the justice system itself (a treatment of every case that is just in isolation might not be a good or even a just deal for society if it costs taxpayers $100M to process each case, even if it's relatively trivial.) (I'm not saying that any specific justice system is good or bad, just that justice shouldn't be its only goal, which I think is an intuitively obvious point for most but a very contentious point for some.)