Nadezhda Savchenko gestures from inside a glass-walled cage during a hearing at a court in the southern border town of Donetsk in the Rostov region of Russia, March 21, 2016. Reuters

MOSCOW — Ukrainian pilot Nadezhda Savchenko was found guilty of murder by a Russian court Tuesday and sentenced to 22 years in prison. Her six-month trial has generated harsh international criticism of Moscow and made Savchenko a symbol of resistance against Russia and a hero for many Ukrainians.

Savchenko, who denies all the charges, interrupted the marathon legal proceedings several times by loudly singing a Ukrainian song, and her supporters gave a rendition of the Ukrainian national anthem as the judge finished speaking.

A spokesman for Ukrainian President Petro Poroshenko who attended the sentencing in Russia was forcibly removed from the court after attempting to unfurl a Ukrainian flag.

The case has generated outrage in Ukraine and further strained relations between Kiev and Moscow, which hit rock bottom in 2014 as Russia annexed the Black Sea region of Crimea and backed a separatist rebellion in the east of the country.

U.S. officials have warned that the treatment of Savchenko, 34, could endanger a 2015 ceasefire in eastern Ukraine that has brought an uneasy peace to the region, and President Barack Obama raised the trial in a telephone conversation with Russian President Vladimir Putin last week.

The sentence was not a surprise because of the case’s political nature, according to Savchenko’s lawyer Mark Feygin, who called on Savchenko’s supporters across the world to take to the streets Tuesday to protest the decision.

Savchenko’s legal team has said repeatedly her only chance of early release is to be included in a prisoner exchange for two Russian intelligence officers, currently held in Ukraine, that Kiev said were captured in its territory last year.

“An exchange for Russian soldiers would be logical,” Feygin told reporters on the steps of the court building in the southern Rostov region.

Ukrainian President Petro Poroshenko speaks after a meeting of the EU Council in Brussels, March 17, 2016. Reuters

Poroshenko said Tuesday that Ukraine would never recognize the decision of the Russian court and reiterated he was prepared to return Savchenko to Ukraine through a prisoner exchange. Russian officials have repeatedly denied any negotiations are underway to free Savchenko but have said a swap would be theoretically possible after a verdict.

A long sentence for Savchenko was widely expected, but proceedings were given an extra touch of farce Monday morning when Russia’s leading news agencies prematurely reported a guilty verdict. In the end, it took the judge almost 15 hours across two days to read out his judgment.

Savchenko was convicted of working as a spotter for an artillery team that allegedly targeted and killed Russian state television journalists Anton Voloshin and Igor Kornelyuk in a June 2014 strike in eastern Ukraine. The judge also said Savchenko illegally crossed the border into Russia posing as a refugee.

“Her reform is not possible without isolation from society,” the judge said during the sentencing, according to the Radio Liberty news service.

A Russian police vehicle believed to be ferrying former Ukrainian army pilot Nadezhda Savchenko arrives for a verdict hearing at a court in the southern border town of Donetsk in Rostov region, Russia, March 22, 2016. Reuters

Throughout the trial, Savchenko denied any involvement in the killing of Voloshin and Kornelyuk. She said she was taken prisoner by Russian-backed separatists when trying to help wounded comrades and maintained she was illegally transferred to Russia. Her legal team argued during the trial that phone records proved she was already a prisoner when Voloshin and Kornelyuk died.

Prosecutors originally requested a 23-year prison term for Savchenko. A spokesman for Russia’s Investigative Committee said Tuesday that he was satisfied with the 22-year sentence, the Russian Interfax news agency reported.

Savchenko’s defiance during her detention in Russia has helped to fuel even more public condemnation of her case.

Another of Savchenko’s lawyers, Nikolai Polozov, told reporters Tuesday that Savchenko plans to begin a full hunger strike 10 days after her sentence comes into force. “Nadezhda thinks that [a hunger strike] is the only way she can influence the Russian authorities ... she is prepared to return to Ukraine either dead or alive,” Polozov said.

Mark Feygin (left), lawyer of former Ukrainian army pilot Nadezhda Savchenko, speaks to the media, with lawyers Oleksandr Plakhotniuk (center) and Nikolai Polozov seen next to him, outside a court in the southern border town of Donetsk in Rostov region, Russia, March 22, 2016. Reuters

The military pilot visibly shed weight after she refused food for more than 80 days last year. During the trial she repeatedly rejected the authority of the court — even flashing her middle finger at the judge during a hearing earlier this month.

“I don’t admit my guilt or recognize the sentence or the Russian court ... I want the whole democratic, civilized world to understand that Russia is a third world country with a totalitarian regime and a dictator-tyrant who spits on human rights,” Savchenko told the court during her final statement.

Savchenko was elected as a member of the Ukrainian Parliament in November 2014 while already in Russian captivity; a picture of her face now adorns the rostrum in the Parliament. She regularly wore a traditional Ukrainian embroidered vyshyvanka shirt during her court appearances.

Before she was detained, Savchenko was fighting separatist rebels in eastern Ukraine with the extreme nationalist Ukrainian Aidar militia. She said joined the group while on a holiday from her Ukrainian military unit, where she served as a trained helicopter and jet pilot. A pinup for the post-Soviet Ukrainian armed forces, Savchenko served in a Ukrainian contingent deployed to Iraq after the 2003 U.S. invasion and was even featured in a 2011 propaganda film made by the Ukrainian military.

A woman takes part in a protest in front of the Russian Embassy in Kiev, Ukraine, demanding the liberation of Ukrainian army pilot Nadezhda Savchenko by Russia, March 22, 2016. Signs read (left to right): “Freedom for Nadezhda Savchenko” and “Nadezhda will not be broken.” Reuters

The trial of Savchenko has provoked intense international condemnation, particularly from the U.S. and the European Union. U.S. Secretary of State John Kerry, who has spoken out in support of Savchenko, is currently in Moscow on his second visit to Russia since the start of the Ukraine crisis and was expected to meet with Putin.

Russia has rejected calls to free Savchenko, accusing Western officials of attempting to influence a court decision. Putin’s spokesman, Dmitry Peskov, said the Russian leader rebuffed a request from Obama to release Savchenko during a telephone call last week.

Savchenko is one of more than 10 Ukrainians currently in Russian jails whom Kiev deems political prisoners. Several trials are still ongoing, and many of the defendants have alleged they were tortured in Russian custody. Some of the most prominent prisoners on the list are Ukrainian film director Oleg Sentsov, 39, who was sentenced to 20 years in prison in August on terrorism charges, and Yuri Soloshenko, a 73-year-old Ukrainian reportedly suffering from cancer who was sentenced to six years in prison in October on spying charges.