More interestingly, Erdogan ​declared the Astana process “ moribund " and leveled a rare rebuke against Russia, accusing it of violating its commitments under the 2018 Sochi deal.

Erdogan said that Turkey would be unable to deal with a new influx of Syrian refugees. “We will not shy away from doing whatever it takes to prevent this, including using military force,” he said.

The offensive of the Russian-backed Syrian regime forces against Idlib , where eight Turks were killed by shelling, has cracked Turkey and Russia's partnership, which had looked solid since 2016.

Ongoing escalation in Syria will undoubtedly influence the situation in Libya, as Erdogan’s policies have linked the two matters. Besides, the course of the events in Libya will influence the balance of power in the eastern Mediterranean.

Turkey’s President Recep Tayyip Erdogan is following an assertive and aggressive foreign policy, from northern Syria to the eastern Mediterranean. His policy of brinkmanship contains the dangers of a military confrontation with too many players, although such a possibility means a lose-lose scenario for all players involved.

The timing of the apparent rift between Turkey and Russia regarding the military situation in Idlib has also blown up the expectations on the ultimate amelioration of relations between Ankara and Damascus, which comes in the wake of the Russian-brokered meeting between Turkish and Syrian spymasters in Moscow Jan. 13.

Erdogan’s disgruntlement with Russia coincided with French President Emmanuel Macron’s unusually straightforward rebuke of Erdogan. “I want to express my concerns with regard to the behavior of Turkey at the moment," he said. "We have seen during these last days​ Turkish warships accompanied by Syrian mercenaries arrive on Libyan soil. This is an explicit and serious infringement of what was agreed in Berlin. It’s a broken promise.”

Macron's remarks indicate that Turkey has not abided by the agreement made at the Berlin conference on Libya Jan. 19. Yet Turkey denies it has deployed Syrian fighters to Libya. To add insult to injury, Macron made these statements during a press conference with the prime minister of Greece. He also announced that France would send its warships to the eastern Mediterranean to support Greece.

Prime Minister Kyriakos Mitsotakis hailed the French decision, describing the warships as “guarantors of peace.”

While French warships sail the eastern Mediterranean and Macron supports Khalifa Hifter's Libyan National Army on the battlefield, two Turkish frigates and a flotilla of warships have been spotted off the coast of Tripoli. Turkey’s commitment to Libya’s Tripoli-based government, the Government of National Accord, (GNA), even includes the provision of sophisticated air defense systems.

During his recent tour of Africa, Erdogan described Hifter as a "putschist" and a “traitor" to late Libyan leader Moammar Gadhafi. He also criticized the Wagner Group, a private Russian military company, for increasing Hifter’s chances at ousting the GNA.

As with Idlib, Libya constitutes another crack in Turkey’s partnership with Russia, and mirrors the downside of prioritizing personal relations in foreign policy. It's no secret that Vladimir Putin courted Erdogan for years to woo Turkey away from NATO and to create fissures in the trans-Atlantic alliance.

Erdogan responded positively to Putin, to the extent that he is now seen as Putin's Trojan horse in NATO. However, it is now apparent that the Russian military has persisted in its support of the Syrian regime and Hifter in Libya.

Syria and Libya also reveal the limits of Putin. For example, Putin could not secure Hifter’s consent to sign the cease-fire document during talks in Moscow — a loss of prestige for Russian diplomacy. Putin also could not curb the Syrian regime’s ambitions in Idlib, as he had done previously. It is also unclear whether Putin could force Bashar al-Assad in Syria and Hifter in Libya to back down to have Erdogan on board.

There are also allegations that many within the Russian military and diplomatic community are dissuading Putin from adopting positions that would satisfy Erdogan, who has conflicting interests with Russia in Syria and Libya.

The situations in Syria and Libya could end the Turkey-Russia partnership that has emerged over the last four years, and the Russian policy of turning Turkey away from NATO and the West may go up in smoke.

Yet a rift with Russia would not be a relief to Erdogan, given his increasingly problematic relationship with the West. His seemingly revived fraternity with Germany’s Angela Merkel may not compensate for his falling out with Macron and the majority of the European Union, despite his fear-mongering tactic of threatening to flood Europe with Syrian refugees.

Marc Pierini, the former EU ambassador to Ankara, wrote in an analysis for Carnegie Europe: “Although British, French, and German leaders may express their views in different styles, the EU’s political mood has become increasingly critical of Turkey and especially of its president. The substantive reason is the perception that Turkey is pivoting away from the values it once said it was sharing with the European Union and the [trans-Atlantic] alliance.”

Erdogan’s policies are now between the Russian hammer in Syria and the French anvil in Libya and the eastern Mediterranean. Erdogan's political survival could hinge on the debacles and blunders of these two interlinked fronts. Nonetheless, it's too early and imprudent to write off his chances of success, too.

Erdogan is risking possible military confrontations with too many players due to his aggressive foreign policies in Syria and the eastern Mediterranean. For now, this scenario is widely seen as a lose-lose situation for everybody involved. Yet there is now doubt that ongoing developments in Syria will influence the situation in Libya.

The disunity, in terms of political choices, between Europe and Russia will play into Erdogan's hands. As long as real options to deter Turkey’s unilateralism and aggressive foreign policy are produced, Erdogan may get over his problems with a face-saving deal.

Erdogan’s gunboat diplomacy in Libya and the eastern Mediterranean, and European fears of Syrian refugees, might still pay dividends.