A Texas man convicted of murdering a Harris County Sheriff's deputy during a traffic stop in 2019 was sentenced to death on Wednesday, Sheriff Ed Gonzalez said. 

It took a jury just half an hour of deliberations to convict 50-year-old Robert Solis of capital murder earlier this month for shooting and killing Sandeep Dhaliwal, the first Sikh deputy in the history of the Houston-area sheriff's office. 

Robert Solis murderer

Robert Solis, 50, was sentenced to death for the murder of a sheriff's deputy in 2019.  (Fox 26 Houston)

Solis, who had a warrant out for his arrest for violating parole at the time of the shooting, shot Dhaliwal in the back of the head as the deputy walked back to his cruiser during a traffic stop. 

TEXAS MAN KILLED AFTER POINTING GUN AT FORT WORTH OFFICER, POLICE SAY

Gonzalez described Dhaliwal, who was granted a religious accommodation to wear the traditional turban and beard of the Sikh religion, as a "trailblazer" after joining the force in 2009. 

"We are extremely grateful that justice has been served," Gonzalez tweeted after the sentence came down on Wednesday. 

Sandeep Dhaliwal

Harris County Sheriff's Deputy Sandeep Dhaliwal was murdered during a traffic stop at the age of 42 in 2019.  (Harris County Sheriff's Office)

Pyara Singh Dhaliwal

Pyara Singh Dhaliwal, father of Harris County Sheriff's deputy Sandeep Dhaliwal, center, pays respects to his son during his funeral at Berry Center on Oct. 2, 2019, in Houston.  (Brett Coomer/Houston Chronicle via AP)

Solis, who represented himself in court and claimed that he accidentally shot Dhaliwal, has a criminal record dating back to 2002, when he was convicted of aggravated assault with a deadly weapon for shooting his cousin's boyfriend then holding his 4-year-old son hostage, according to Fox 26 Houston

CLICK TO GET THE FOX NEWS APP

He served 12 years of a two-decade prison sentence before being discharged in 2014. Solis was convicted of DWI in 2016, but was allowed to remain on parole. He was a fugitive at the time of Dhaliwal's murder for parole violations. 

The Associated Press contributed to this report.