Washington (CNN) President Donald Trump fired two key impeachment witnesses Friday, dismissing Lt. Col. Alexander Vindman , the top Ukraine expert at the National Security Council , and US Ambassador to the European Union Gordon Sondland.

An adviser to Trump said the firings of the major impeachment witnesses was meant to send a message that siding against the President will not be tolerated.

"Flushing out the pipes," the adviser told CNN. "It was necessary."

Vindman was pushed out of his role Friday months earlier than expected, according to a statement from his attorney. Vindman was not slated to leave until July, but had been telling colleagues in recent weeks he would likely leave soon.

Sondland said in a statement Friday that he is being recalled from his post.

"I was advised today that the President intends to recall me effective immediately as United States Ambassador to the European Union," Sondland said. "I am grateful to President Trump for having given me the opportunity to serve, to Secretary Pompeo for his consistent support, and to the exceptional and dedicated professionals at the U.S. Mission to the European Union. I am proud of our accomplishments. Our work here has been the highlight of my career."

The dismissals appear to be retribution for Vindman and Sondland's explosive testimonies to the House impeachment probe late last year, both of which were done under subpoena. The duo gave some of the most damning testimony to House impeachment investigators during last fall's public hearings and quickly became targets for Trump's supporters, both inside and outside of government. The firings come two days after the Senate voted to acquit Trump on two articles of impeachment in votes that were largely along party lines.

Trump had continued to fume privately about Vindman's testimony during the impeachment inquiry and foreshadowed his dismissal earlier Friday.

"Well, I'm not happy with him," Trump said. "You think I'm supposed to be happy with him? I'm not."

Sondland's ties to the White House and Trump had deteriorated since his testimony. A person familiar with the situation says Sondland's ties to the White House and Trump had frayed badly since he testified last year. He once had Trump effectively on speed-dial, or the presidential equivalent of it, but since his appearance he hasn't spoken with Trump. He was also pulled from overseeing the Ukraine portfolio, which wasn't directly related to his position as EU ambassador.

Vindman dismissed early

Vindman, a decorated veteran who was born in Ukraine, was escorted out of the White House by security and told his services were no longer needed, according to his lawyer, David Pressman.

Pressman said in a statement that it is clear he was fired for testifying in the impeachment probe.

"There is no question in the mind of any American why this man's job is over, why this country now has one less soldier serving it at the White House," Pressman said. "LTC Vindman was asked to leave for telling the truth. His honor, his commitment to right, frightened the powerful."

He added, "Truth is not partisan. If we allow truthful voices to be silenced, if we ignore their warnings, eventually there will be no one left to warn us."

His twin brother, Lt. Col. Yevgeny Vindman, a National Security Council attorney, was also fired, "suddenly and with no explanation, despite over two decades of loyal service to this country," Pressman said, and walked off the White House grounds alongside Alex Vindman.

Yevgeny Vindman had never testified or spoke publicly about the Ukraine saga. "He deeply regrets that he will not be able to continue his service at the White House," Pressman said in a statement.

Before the impeachment inquiry was launched, the Vindman brothers often arrived at work together.

National Security Council spokesman John Ullyot said: "We do not comment on personnel matters."

Vindman is expected to return to the Pentagon, though it's still unclear what his assignment will be until he's expected to attend war college this summer.

"We welcome back all of our service members, wherever they serve, to any assignment they are given," Defense Secretary Mark Esper had said Friday when asked about Vindman's expected ouster.

"We can confirm that both Lt. Cols. Vindman have been reassigned to the Department of the Army, out of respect for their privacy, we will not be providing any further information at this time," an Army spokesperson said.

The vice chairman of the Joint Chiefs of Staff, Gen. John Hyten, told CNN that "it will be up to the Army" to determine where Alex Vindman goes next. "But I'm sure there's still room for his talents in the United States Army, it's just not in the current job," he said.

While Vindman had only learned from news reports late Thursday night of the potential White House plan to fire him, he'd been steeling himself for this moment since he testified in Trump's impeachment hearing in November, according to a source familiar.

Of the friends and family reaching out in support of the Purple Heart recipient amid the subsequent attacks from Trump and his allies, some also warned of likely retribution.

One source who spoke with Vindman recently said the veteran originally hoped he could continue to be effective in his role at the National Security Council post-testimony, but was quickly marginalized when he returned to work.

"Alex was a bit naïve about it at first -- because he believed that since he did what he thought was right, things would work out," a source close to him said. "But it eventually became clear that wasn't how things were going to go this time."

Vindman had told lawmakers during his November congressional testimony that he reported concerns about Trump's July 25 call with the leader of Ukraine to the top National Security Council lawyer within hours of the call, and that some of the changes he tried to make to the since-published transcript were left out, though he didn't say why.

Vindman -- who was awarded a Purple Heart for his service in Iraq after being wounded in an IED attack and still carries shrapnel from the attack in his body, according to a source close to him -- also told lawmakers how his family had fled to the US from the Soviet Union when he was a child.

"The privilege of serving my country is not only rooted in my military service, but also in my personal history. I sit here, as a lieutenant colonel in the United States Army, an immigrant," he said. "My family fled the Soviet Union when I was three-and-a-half years old. Upon arriving in New York City in 1979, my father worked multiple jobs to support us, all the while learning English at night. He stressed to us the importance of fully integrating into our adopted country."

Vindman served multiple overseas tours, including in South Korea and Germany in addition to his deployment to Iraq, according to his prepared remarks.

But now the intense and public backlash from the President and his supporters has put Vindman's future in the military in question.

"If Alex could stay in the Army forever he would. If he could go continue his career without [the impeachment testimony] following him around for the rest of his life, he would. But it's not clear he can," said a source familiar with the situation.

Sondland connected Trump to quid pro quo

Sondland's dismissal comes nearly three months after he connected Trump directly to the "quid pro quo" trading Ukrainian investigations into Trump's political opponents for official actions, including a White House meeting, during damning testimony before House impeachment investigators.

Sondland, a political appointee and hotel magnate with no background in government before joining the Trump administration, testified in November that he was working with Trump's attorney Rudy Giuliani on Ukraine matters at the "express direction of the President of the United States."

He also recounted several conversations between himself and Trump about Ukraine opening two investigations: one into Burisma, a company where former Vice President Joe Biden's son was on the board, and another into conspiracies about Ukrainian meddling in the 2016 US election.

"Everyone was in the loop. It was no secret. Everyone was informed via email on July 19, days before the presidential call," Sondland said.

While Sondland said Trump had never expressly told him that US military assistance was contingent on Ukraine announcing investigations into Burisma and the 2016 election, the ambassador said he was "under the impression that, absolutely, it was contingent."

Though the new comments corroborated testimony from other witnesses and contradicted Trump, who had said all along that there was no quid pro quo with Ukraine, he didn't go as far as some of the other witnesses in his statements.

Sondland said Trump withheld a White House invitation from the new Ukrainian President, Volodymyr Zelensky, until Zelensky announced the investigations. Other witnesses testified that US military assistance was also part of the quid pro quo, but Sondland said Trump never mentioned the foreign aid component.

Still, the testimony ruined Sondland's standing in Trump's orbit.

"Sondland was a dead man walking," a current US official told CNN. "We all knew it was coming and it was going to happen fast, it was just a question of when Trump was going to do it."

Even other US ambassadors who were appointed by Trump and had been close to Sondland tried to maintain an arms-length distance from him, knowing that Trump had turned on him, the official said.

A source close to Sondland told CNN "there's no other job for him" in the Trump administration. He had resisted resigning, a source familiar with the situation told CNN.

In Brussels, a diplomatic source told CNN that Sondland had seen his status diminished in the eyes of his diplomatic counterparts. They want to work with someone who has proximity to the President, and after Sondland testified, it was clear he didn't, the source said.

Sondland, who was confirmed to the ambassador role in June 2018, has been a player in Republican politics for a number of years but wasn't always a Trump supporter.

During the 2016 election, he donated to Jeb Bush's presidential campaign and to the former Florida governor's Super PAC, FEC filings show. After Trump locked up the nomination, Sondland, a frequent donor to the Republican National Committee, joined Trump and the RNC's joint finance operation, and eventually donated $1 million to Trump's inaugural committee through four limited liability companies, according to the Center for Responsive Politics.

Sondland was previously the founder and CEO of the Provenance Hotels chain, which boasts 19 hotels across the country.

This story has been updated with reaction and further details.