WASHINGTON — James Comey defended his handling of the Clinton email investigation in a closed-door meeting with congressional investigators on Friday, while Republicans accused the former FBI director of sidestepping key questions about the origins of the Russia investigation.

Comey testified for more than six hours on Capitol Hill as part of a GOP-led inquiry into the FBI’s decision-making before the 2016 election. The House Judiciary and Oversight Committees are racing to finish interviews before Democrats assume control of the House in January.

Comey initially waged a legal fight against a Judiciary Committee subpoena as he pressed lawmakers to allow him to answer questions in a public hearing, but he ultimately reached an agreement to provide testimony on the condition that a transcript be made public within 24 hours.

After the hearing Friday, Comey continued to express frustration with the process.

"After a full day of questioning, two things are clear to me: One, we could have done this in open setting. And two, when you read the transcript, you will see that we're talking again about Hillary Clinton's emails, for heaven's sake, so I'm not sure that we need to do this at all," he said.

Today wasn’t a search for truth, but a desperate attempt to find anything that can be used to attack the institutions of justice investigating this president. They came up empty today but will try again. In the long run, it'll make no difference because facts are stubborn things. — James Comey (@Comey) December 8, 2018

Republicans, without going into specifics about Comey’s testimony, had their own complaints. Justice Department lawyers who accompanied Comey prevented him from answering questions about whether the FBI began probing Trump associates’ ties to Russia earlier than has been publicly stated, and how much information from the so-called Steele dossier was used as predicate for a secret surveillance warrant on Carter Page, a former Trump foreign policy adviser.

"I’ve been in probably more of these transcribed interviews than most, and there’s been a consistent theme where the FBI does not want questions that may relate to the Mueller investigation to be answered," said Rep. Mark Meadows, R-N.C.

President Donald Trump also weighed in as he returned to Washington from a visit to Missouri:

It is being reported that Leakin' James Comey was told by Department of Justice attorneys not to answer the most important questions. Total bias and corruption at the highest levels of previous Administration. Force him to answer the questions under oath! — Donald J. Trump (@realDonaldTrump) December 7, 2018

Republicans are also seeking testimony from Deputy Attorney General Rod Rosenstein and former Attorney General Loretta Lynch — with just weeks left in the current congressional term. Lynch and Comey are expected to return just before lawmakers are set to break before Christmas; Meadows defended the 11th-hour questioning.

"For us to just pack it up and go home is not what the American people deserve and for the most part it’s not what they expect," he said.

But Rep. Jerry Nadler, D-N.Y., who will serve as Judiciary Committee chairman when Democrats gain control of the House in January, blasted Republicans for pursuing an investigation he called a "waste of time."

"The entire purpose of this investigation is to cast aspersions on the real investigation with Mueller. There’s no evidence whatsoever of bias at the FBI or any of this other nonsense they’re talking about," he said.

Rep. Jimmy Gomez, D-Calif., said that while Republicans were focused on the perceived bias of Justice Department officials who had roles in both the Clinton and Russia probes, he pressed Comey on whether Trump’s new nominee to lead the Justice Department, former Attorney General William Barr, could impartially oversee the Mueller probe if confirmed.

Comey, who worked in the Southern District of New York when Barr first served as attorney general, later told reporters that he was confident Barr would consult with career officials to make the appropriate determination about potential recusal.

“I know he's an institutionalist who cares deeply about the integrity of the Justice Department, so I'm sure he'll use the standard career resources he has to judge what he should be involved in and what he shouldn't be involved in,” he said.

It is unclear what Republicans’ end game is after they complete their final scheduled interviews. Rep. Jim Jordan, R-Ohio, who will be the top Republican on the House Oversight Committee in the next congress, said he did not know whether the committees’ current Republican chairmen, Rep. Bob Goodlatte, R-Va., and Rep. Trey Gowdy, R-S.C., planned to issue a final report.