At least some of the issues in our justice system stem from not having the resources to handle every case fairly. Every criminal case should be fully investigated and tried in court, but the system would break under these conditions.
So you end up with a highly perverse system based on extortion, and heavily biased depending on socioeconomic status. Sometimes it works "too well", other times it doesn't work at all.