Gary Kearney, who is originally from Crumlin, pleaded guilty at Dublin District Court to animal cruelty and torture.
He also admitted breach of the peace during the incident on 3 July 2011.
The animal's owner, John Byrne, had been begging on O'Connell Bridge when his pet, Barney, was snatched from his arms and thrown into the river.
The 37-year-old risked his life by jumping in after his beloved pet and giving him the kiss of life before both were rescued by firefighters.
Within days, he was given a Compassionate Citizen Award for going above and beyond the call of duty to help an animal in need.
Outside the court, Mr Byrne, who has been living on the streets for 23 years, said he was in shock when he saw his pet swimming around in circles.
"I wasn't going to leave him there," he said.
"I had to get him, I had to jump in to get him. Barney died in my arms. I got him under the bridge and gave him the kiss of life."