Servitude is one part of God's plan for rehabilitating people who habitually make bad decisions and for training downtrodden, landless foreigners into self-supporting Israelites. Although God's Law allows a foreign slave and his children to be kept in perpetuity, a God-fearing master will turn his servant into a Hebrew who must then be released in the 7th year. Exodus 21:2

I served in the United States Air Force for 6 years and was released in the 7th per God's terms defined in Torah. Of course the Air Force probably hadn't considered that and I doubt they gave much thought about turning me into a good, Torah-observant Hebrew.