Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

Jordan executed two prisoners, including an Iraqi militant whom it had sought to trade with ISIS, on Wednesday morning to avenge the death of a Jordanian pilot who was purportedly shown being burned alive in an ISIS video, Jordanian state media and police sources said.

A police source told NBC News that the executions of Sajida al-Rishawi, an Iraqi woman whom ISIS had demanded be released, and Zyad al-Karbouli, an Iraqi Islamist who also had previously been sentenced to death, took place only a few hours after Jordanian King Abdullah met in Washington with President Barack Obama.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

Abdullah then immediately set flight back home, his government having promised swift revenge for the apparent death of Lt. Muath al-Kasasbeh.

A 22-minute video released Tuesday by the al-Furqan Media Foundation — one of the official media arms of ISIS — showed al-Kasasbeh with a black eye at a table and, later, standing in a cage as he is burned alive. He had been captured while on a bombing run over Syria in December when he was forced to eject.

Until the video's release, Jordan had been trying to negotiate a swap of al-Rishawi, who was jailed for an attempted suicide attack in Amman in 2005, for al-Kasasbeh.

Earlier Tuesday, Bernadette Meehan, a spokeswoman for the National Security Council, said Obama and the U.S. "stand in solidarity with the government of Jordan and the Jordanian people."

IN-DEPTH

NBC News' Moufaq Khatib contributed to this report.