A Newark, N.J., City Council meeting to decide who would fill a vacant council seat descended into chaos, with angry residents rushing the stage and police using pepper spray to end the near-riot, according to media reports.

Dozens of people rushed the stage Tuesday night after Mayor Cory Booker made a rare appearance at the meeting and cast the deciding vote to fill the vacancy left by Donald Payne Jr., who was elected to Congress, the Newark Star-Ledger reported.

Booker, invoking a law that gives the mayor a vote in the absence of a quorum, backed Shanique Davis Speight for the seat, raising the ire of many in the packed council chamber who supported John Sharpe James, the son of former mayor Sharpe James. James is an avowed opponent of Booker, who lost to James’ father in the 2002 mayoral race before winning in 2006.

An attempt was made to swear in Speight, but people in the audience protested, with some chanting, "Cory's gotta go!" Several people in the audience shouted and gestured animatedly toward the stage, ignoring appeals to sit down.

“People in the crowd stood up and said it was unlawful,” South Ward Councilman Ras Baraka told the Montclair Patch.

Speight was ultimately ushered out of the room and sworn in later by the city clerk.

Police moved in to try to control the crowd after a group, led by SEIU Local 617 President Rahaman Muhammad, rushed toward the dais, the Newark Star-Ledger reported. In the chaos, people were shoved, a podium was knocked over and an officer doused Muhammad with pepper spray, according to the Star-Ledger. Others in the hall snapped pictures and video of the chaos on their cellphones and tablet computers.

Earl Best, a community activist known as "Street Doctor," told the Montclair Patch he was also sprayed and had to go to a hospital for treatment. Baraka said his mother had also been sprayed, according to the Montclair Patch.

Muhammad was arrested and charged with assaulting Speight and City Clerk Robert Marasco, resisting arrest and inciting a riot, Police Director Samuel DeMaio told the Star-Ledger.

DeMaio said the officer’s use of the pepper spray will be reviewed but noted that it might be warranted in such a chaotic scenario.

"From what I see right now at face value, in the situation that they had there with the crowd surging toward the council desk … the officer made a decision," he said, according to the Star-Ledger.

The Associated Press contributed to this story.

More content from NBCNews.com:

Follow US news from NBCNews.com on Twitter and Facebook