Prolonged instability weakened the military. By the end of the nineteenth century, Haiti's military had become little more than an undisciplined, ill-fed, and poorly paid militia that shifted its allegiances as battles were won or lost and as new leaders came to power. Between 1806 and 1879, an estimated 69 revolts against existing governments took place; another 20 uprisings, or attempted insurrections, broke out between 1908 and 1915. At the beginning of the twentieth century, Haiti's political problems attracted increasing foreign involvement. France, Germany, and the United States were the major actors; the latter occupied the country in 1915. During the occupation, the United States made an unsuccessful attempt to modernize Haiti's armed forces.