The media has been quick to associate Qatar’s decision to withdraw its peacekeeping forces from the disputed Djibouti-Eritrea border with the Gulf crisis. This connection was most likely made because Qatar’s decision came only days after both Djibouti and Eritrea announced that they are siding with Saudi Arabia in the diplomatic rift and downgraded their diplomatic relations with Qatar.

The withdrawal of troops, if understood as a knee-jerk reaction, contrasts markedly with how Qatar has been operating since the start of the crisis. Qatar has not reciprocated the harsh, punitive moves of the United Arab Emirates and Saudi Arabia in a tit-for-tat spiral of vindictiveness. Nor has it reacted to countries which have reduced diplomatic relations, such as Jordan, by taking retaliatory measures against its thousands of nationals working in Qatar.

While Qatar Airways offices have been sealed off in Abu Dhabi and its senior staff harassed, no such measures have been taken by Doha. Furthermore, while food supplies through Saudi Arabia and the UAE were cut, Qatar continues to supply the latter with around 57 million cubic metres of gas daily. This shows that Qatar continues to play the long game by taking the moral high ground – a strategy that looks to have paid off given the number of international diplomatic capitals that have refused to cave into the intense lobbying of Saudi Arabia and the UAE to vilify Qatar.

READ MORE: Africa and the Gulf crisis: the peril of picking sides

Given what we know about how Qatar has operated during the crisis, the explanation that the troop withdrawal is purely a knee-jerk reaction to the downgrading of diplomatic ties does not add up. Doubtlessly, with downgraded relations, Qatar finds itself in a difficult position as a mediator and peacekeeper between the two nations. No mediator can operate effectively with reduced representation, both on a practical and reputational level. Nevertheless, it is unlikely that the decision has been made in a retaliatory manner. Rather, there are three less evident reasons for why the decision to withdraw has been on the cards for some time and why it is now impossible for anyone in Qatar to advocate for maintaining the peacekeeping force.

The potential fallout of the crisis could have ripple waves spiralling out of the border dispute to the much larger Eritrea-Ethiopia conflict and the rest of the Horn of Africa at a time when the sub-region is facing a massive humanitarian crisis.

First of all, a fundamental principle of conflict mediation is that any third party must maintain a credible threat to walk away if the conflicting parties are not committed to reaching a negotiated settlement. Qatari troops have, for the past seven years, been stationed in the dusty uninhabited border region between the two East African countries to monitor the implementation of the terms of a ceasefire agreement brokered by Qatar in June 2010.

Despite consistent attempts to turn the ceasefire into a peace agreement, little progress has been made. A minor breakthrough was achieved in March 2016 when, in a deal mediated by Qatar, Eritrea released four prisoners from Djibouti’s armed forces who were captured in June 2008 during border clashes. However, in the past year, the Eritrean negotiating team has disengaged from the mediation process despite the United Nations Security Council mandated-arms embargo on Eritrea being re-approved in November 2016, demanding that Eritrea release all missing prisoners and allow UN monitors to enter the country.

The two states, particularly Eritrea, have not heeded calls for border demarcation and have gone into denial by refusing to refer to the border conflict as a serious issue. The presence of the Qatari peacekeepers had allowed both parties to grow accustomed to the status quo of a mutually beneficial stalemate.

Second, Djibouti and Eritrea consistently engage in a geostrategic game of shifting alliances. When Qatar entered the fray, the Djibouti-Eritrea border dispute was a minor conflict with very few international actors showing an appetite for mediation. Since then Camp Lemonnier in Djibouti has expanded to become the largest US military base in the region, China has also entered Djibouti, while, in April 2015, Saudi Arabia and Eritrea signed a security cooperation agreement and the UAE is currently completing the construction of a military base north of the port city of Assab in Eritrea from where its armed forces have been operating in the military campaign in Yemen. This particular corner of the Horn of Africa is by now far too crowded for a small nation like Qatar to justify its military presence as a buffer.

READ MORE: Qatar-Gulf crisis: All the latest updates

Third, maintaining the 500-strong presence of Qatari troops in a remote area is a costly and largely thankless endeavour. While the withdrawal was doubtlessly hastened by the changes in diplomatic relations with Eritrea and Djibouti, this has more to do with the infiltration of the United Arab Emirates and Saudi Arabia into Eritrea. This military presence clearly renders Qatari troops stationed thousands of miles away in an isolated area a soft target for direct or indirect retaliation. Moreover, 500 troops represent a significant investment of military manpower for an armed forces of around 12,000 during the most urgent crisis the country has faced in its history.

With Eritrea moving its forces into the contested Dumeira Mountain and Dumeira Islands, the temperature of the conflict has been increased and the situation is now more explosive than ever before, for all actors involved. The rapid development of the situation demonstrates the important stabilising role that Qatar had played under the radar for many years.

Moreover, the potential fallout of the crisis could have ripple waves spiralling out of the border dispute to the much larger Eritrea-Ethiopia conflict and the rest of the Horn of Africa at a time when the sub-region is facing a massive humanitarian crisis. This should serve as a cautionary note for the potential of escalation in other places where Qatari assistance has been keeping the lid on conflict, in particular, the Gaza Strip, where as a result of the increased isolation of Qatar by its Gulf neighbours we may see the end of the single most important donor to the reconstruction of the besieged territory to date. This should focus the minds of world leaders on the need to resolve the Gulf crisis amicably as soon as possible.

Professor Sultan Barakat is the director of the Center for Conflict and Humanitarian Studies at the Doha Institute for Graduate Studies and professor in the Department of Politics at the University of York.

Dr Sansom Milton is a senior research fellow at the Center for Conflict and Humanitarian Studies at the Doha Institute for Graduate Studies.

The views expressed in this article are the author’s own and do not necessarily reflect Al Jazeera’s editorial policy.