President Donald Trump has nominated a law professor who previously worked as a prosecutor, defense attorney and journalist to fill the nation’s longest federal judiciary vacancy.

Trump nominated Richard E. Myers on Wednesday to be a trial judge in the Eastern District of North Carolina. The state’s two Republican senators recommended Myers for the job.

Raleigh lawyer Thomas Farr had been nominated to become a U.S. District judge four times — twice by President George W. Bush and twice by Trump — but never received confirmation.

Civil rights groups had heavily criticized Farr for his work defending state voting and redistricting laws that judges had declared discriminated against black voters, as well as for his role as a campaign lawyer for then-Sen. Jesse Helms. Last year, Farr’s elevation was stopped when two Republican senators from outside North Carolina announced their opposition to Farr’s nomination.

There’s been an eastern North Carolina judicial vacancy since January 2006, the longest in the country, according to a list from the U.S. Administrative Office of the Courts. President Barack Obama nominated two black women for the judgeship during his tenure, but Republicans blocked both candidates.

Myers was born in Jamaica and grew up in the coastal North Carolina city of Wilmington, where he worked as a newspaper reporter in the early 1990s. Myers got his law degree from the University of North Carolina’s School of Law in Chapel Hill and is now a professor there. He previously clerked at the U.S. Court of Appeals for the District of Columbia Circuit and was a federal prosecutor in both California and later North Carolina, when he worked on white collar and violent crime cases.

North Carolina Sens. Richard Burr and Thom Tillis, both supporters of Farr, praised the new nominee. Burr cited Myers’ work advising the University of North Carolina’s Federalist Society chapter as a demonstration of his “strong commitment to mentoring the next generation of legal minds.”

Myers’ prosecutorial work, “as well as his well-deserved reputation as one of our state’s best legal scholars provide him with the background and qualifications required to serve the Eastern District with distinction,” Tillis said in a release.

While in private practice in California, Myers also was on the legal team defending Wen Ho Lee, a Taiwan-born scientist once charged with mishandling nuclear weapons secrets. Lee was released after the government dropped all but one charge.