WASHINGTON (Reuters) - President Donald Trump said on Thursday that Joseph Maguire, the current chief of the National Counterterrorism Center, will become the acting director of national intelligence.

Trump’s announcement on Twitter came after the deputy director of national intelligence, Sue Gordon, resigned. She said in a note to Trump that stepping down was not her “preference,” but added, “You should have your team.”

Trump said Maguire will take over the acting post on Aug. 15, when Dan Coats, the current director of the agency overseeing civilian and military intelligence, steps down.

“Admiral Maguire has a long and distinguished career in the military, retiring from the U.S. Navy in 2010,” Trump said on Twitter.

Maguire has led the National Counterterrorism Center, which is overseen by the Office of the Director of National Intelligence (ODNI), since December. He retired from the Navy after a 36-year career that included leading the Naval Special Warfare Command.

“I’ve known Admiral Maguire for some time and I have confidence in his ability to step into this critical role,” Senate Intelligence Committee Chairman Richard Burr said in a statement.

Coats said he was pleased that Trump had chosen Maguire to serve as acting DNI. “Joe has had a long, distinguished career serving the nation and will lead the men and women in the (intelligence community) with distinction,” he said in a statement.

Last week, Trump dropped his first choice to replace Coats, U.S. Representative John Ratcliffe, after questions arose about the Republican congressman’s lack of experience and possible exaggerations in his resume.

Last week, Trump said he liked Gordon and might name her acting DNI. Gordon, a career intelligence official, had the backing of current and former officials because of her deep experience.

“Sue Gordon’s retirement is a significant loss for our Intelligence Community,” Burr said in a statement.

Senator Mark Warner, the top Democrat on the Intelligence Committee, said in a statement that Gordon’s departure was a “great loss.”

Trump had a strained relationship with Coats, who endorsed the U.S. intelligence community’s assessment that Russia interfered in the 2016 election with the objective of promoting Trump over his Democratic rival, Hillary Clinton.

Trump also has objected to U.S. intelligence community analyses of major issues - from Iran’s nuclear program to North Korea - that have clashed with his own assessments.

“President Trump has repeatedly demonstrated that he is seemingly incapable of hearing facts that contradict his own views,” Warner said in his statement on Gordon’s resignation.

The post of director of national intelligence, which was created after the Sept. 11, 2001, attacks on the United States, oversees the 17 U.S. civilian and military intelligence agencies including the CIA.

Under the law, Trump needed to name a new acting director from the senior staff of the agency. The National Counterterrorism Center is part of ODNI.

His choice for the permanent job must be confirmed by the Senate.

Among the potential candidates for permanent director are Republican congressmen Mike McCaul and Devin Nunes, and U.S. Ambassador to the Netherlands Pete Hoekstra, according to administration officials and media reports.

McCaul is a former chairman of the House of Representatives Homeland Security Committee and Nunes is a former chairman of the House Intelligence Committee. Hoekstra is a former nine-term member of the House who spent more than six years in top positions on the intelligence committee.