During its peak, the Ottoman Empire threatened to conquer the Austrian capital of Vienna twice: in 1529 and 1683. After the second Ottoman defeat at Vienna and the end of the Great Turkish War in 1699, however, the Habsburgs gained the upper hand, and captured Hungary and Croatia from the Ottomans. After these gains, Austria was no longer able to advance into the Balkans, because of the rival influence of Russia, in a stalemate and dispute known as the Eastern Question. While Ottoman control in the Balkans declined, the Austrians were not able to annex any new territory until Bosnia in 1908, and even that caused a diplomatic crisis (the Bosnian crisis). In the interim, Russia had helped several nationalities in the Balkans to rebel against the Ottomans and create separate nation-states in the Balkans. After the culmination of all the changes from the Greek War of Independence (1821–1829) to the Balkan Wars (1912–1913) the Austrian and Ottoman empires no longer bordered each other. This allowed both to join the Central Powers as allies during the First World War. The defeat of the Central Powers led to the overthrow of both monarchies.