The end of imperial rule in 1917 meant the loss of some territory following the treaty of Brest-Litovsk, but much of it was quickly reconquered by the Soviet Union later on, including events such as the partition of Poland and reconquest of the Baltic states in the late 1930s and ‘40s. Soviet influence reached its peak after WWII in the Cold War era, during which the Soviet Union occupied virtually all of Eastern Europe in a military alliance known as the Warsaw Pact, with the Soviet Army playing a key role.