The Armed Forces of the Empire of Brazil were the overall unified military forces of the Empire of Brazil. The Brazilian military was first formed by Emperor Dom Pedro I to defend the new nation against the Portuguese in the Brazilian War of Independence. The Army and Armada (as the Navy was called) were commissioned in 1822 with the objective of defeating and expelling the Portuguese troops from Brazilian soil. From the time of its inception, the military played a decisive role in the history of the Empire of Brazil. A sense of national unity and identity was forged out of the victorious Paraguayan War. The Emperor was commander-in-chief of the military, with the Ministries of War and Navy as the main organs by which military policy was carried out. Organization The Brazilian Armed Forces were subordinated to the Emperor, its Commander-in-Chief. He was aided by the Ministers of War and Navy in regard to matters concerning the Army and the Armada, respectively. Traditionally, the Ministers of War and Navy were civilians but there were some exceptions. The model chosen was the British parliamentary or Anglo-American system, in which "the country's Armed Forces observed unrestricted obedience to the civilian government while maintaining distance from political decisions and decisions referring to borders' security". The military personnel was allowed to run and serve in political offices while staying on active duty. However, they did not represent the Army or the Armada but instead the population of the city or province where elected. Dom Pedro I chose nine military personnel as Senators and five (out of 14) to the State Council. During the Regency, two were chosen to the Senate and none to the State Council as there was no Council at the time. Dom Pedro II chose four military personnel to become Senators during the 1840s, two in the 1850s, and three until the end of his reign. He also chose seven military personnel to be State Counselors during the 1840s and 1850s and three after that. Recruitment The recruitment for the Armed forces of the Empire of Brazil, generally considered the imposition of a strong state on a recalcitrant society, was shaped by a complex network of patron-client relationships between the State, the members of the plantation class, and the free poor. These well-established (and in general legitime) relationships survived the challenges of recruitment in times of war and prevented reformers