NEW YORK (CNN) -- For more than two decades, David Ranta has been behind bars for the killing of a Brooklyn rabbi during a botched diamond heist.
In the years since his 1991 conviction, another man's widow has identified her husband as the killer; a onetime jail inmate has said he made up statements about Ranta to boost his own fortunes; and a now-grown boy who once picked him out of a lineup has come forward to say he was coached by a detective.
Now, Brooklyn prosecutors have recommended that Ranta go free -- and if a judge agrees, he could walk out of court as early as Thursday.
"There was never a doubt in my mind that he was innocent," said Michael Baum, the lawyer who represented Ranta at his 1991 trial.
The rabbi, Chaskel Werzberger, died four days after being shot, a victim of the attempted holdup of a diamond courier. The courier escaped, but the would-be robber shot Werzberger through the window of his parked car, hauled him out of the vehicle and drove off, according to the Brooklyn district attorney's office.
Louis Scarcella, one of the detectives who investigated the case, told CNN that Ranta admitted his involvement in the heist attempt and that he stands by the arrest. As for claims that police coached a witness, he said, "No way that happened."
But the now-retired Scarcella added, "If they release him tomorrow, I say, God bless him. I have nothing personal involved in this, and I was just doing my job. "
Ranta, now 58, was arrested six months after Werzberger's February 1990 killing. He was picked up after two men facing trial on their own robbery charges gave his name to police, prosecutors recounted in asking that his second-degree murder conviction be tossed out and the charges dismissed.
One of them, Alan Bloom, identified Ranta as the gunman. Another acquaintance -- a woman who had brought charges against Ranta in a "prior altercation" -- told police that Ranta had confided in her about the planned jewelry robbery and the murder of the rabbi, prosecutors wrote.
In an initial lineup, only one witness recognized Ranta, and that was after a lengthy conversation with a Yiddish interpreter, they noted. In the second lineup, three youths identified him and repeated that identification in court. One witness who didn't identify him was the courier, the intended target of the holdup.
When questioned by detectives, Ranta initially denied any involvement in the killing. Then he acknowledged knowing Bloom, according to prosecutors. Then he admitted he had been near the scene and knowing his friends had planned a holdup. Then he admitted he had been involved in planning the diamond heist, acted as the lookout and had seen Bloom and the second jailed witness, Dmitry Drikman, with a gun.
"Two witnesses testified implicating him," Baum told CNN. "The police had an alleged confession from him, but there was no physical evidence. The jewelry courier, he testified for the defense, saying that Ranta wasn't the guy. A woman came forward saying Ranta was innocent, that her husband was the one who did it," said Baum.
Despite that testimony for the defense, the jury found Ranta guilty. He was sentenced to 37 ½ years to life in prison.
Four years later, Theresa Astin came forward to say that her husband, Joseph -- who died in a 1990 car accident -- had been the killer. He'd been named as a possible suspect before, and Scarcella had brought the courier to the morgue in hopes that he would identify Astin's body as the gunman. He didn't.
Baum sought a new trial for his client based on Astin's testimony, but a judge refused to grant one. Then in 2011, he said, one of the kids who picked Ranta out of a lineup got in touch with him.
"I got a call saying, 'I've lived with this for 20 years. The detective told me who to pick out,' " Baum said.
The call was from Menachem Lieberman, who later told investigators he identified Ranta after being told by a detective to "Pick the guy with the big nose."
"It was on his conscience for all these years," Baum said. "He was 13 years old at the time. He was just a kid. He was just doing what they told him to do."
The Brooklyn district attorney's office had recently started a Conviction Integrity Unit to look into claims like Ranta's. Baum told them about Lieberman's call, and the unit began to dig into Ranta's case.
Bloom is now dead. But Drikman admitted he had fabricated earlier statements he made about Ranta, hoping that his cooperation would help his own criminal case. Drikman's girlfriend at the time confessed that her account was manufactured to assist him. Astin reiterated her previous testimony.
Scarcella said the case against Ranta was "very simple."
"We had eyewitnesses who said they saw him shoot him," he said. "We had statements that he made to other people, implicating himself, who have since died. We have the confession he gave to me."
And he sharply disputes Lieberman's account of being coached, telling CNN, "As far as I'm concerned, it's fiction."
"No way that happened," he said, noting that dozens of prosecutors and police were watching the lineup.
"They're saying that I framed it," Scarcella said. "I want to go on record saying this: I never framed anyone in my life, and you would have to be a low, low devil to do something like that. I slept very good for the last 22 years."
But eventually, Brooklyn District Attorney Charles Hynes recommended that the case be thrown out. Sandy Silverstein, a spokesman for Hynes, told CNN that Ranta will be brought back to Brooklyn from a prison upstate on Thursday. There, he'll await the judge's decision on his fate.
CNN's calls to Pierre Sussman, Ranta's current lawyer, were not immediately returned.
Although Baum had been working with district attorney's investigators for months, he wasn't sure of what Hynes had decided until he read about it.
"I actually didn't know the end result. I prayed and prayed when I read it in the paper this morning. There were tears coming out of my eyes," he said.