JOHANNESBURG — The fight to replace South Africa’s scandal-prone President Jacob Zuma began Saturday as thousands of delegates of the ruling African National Congress gathered to elect a new leader, with Zuma acknowledging “failures” that have threatened the party’s future.

The reputation of Nelson Mandela’s liberation movement has been battered during the tenure of Zuma, whose second term as party president is up. The new ANC leader is likely to become South Africa’s next president in 2019 elections.

The two clear front-runners are Deputy President Cyril Ramaphosa and Nkosazana Dlamini-Zuma, former chair of the African Union Commission and Zuma’s ex-wife. The selection is expected to be announced on Sunday.

Voters are frustrated with the ANC as Zuma’s administration has been mired in scandal and corruption allegations. Africa’s oldest liberation movement, which celebrated its 105th anniversary this year, led the fight against the system of white minority rule known as apartheid and has governed South Africa since the first democratic elections in 1994.

Observers say the party needs to restore its reputation or it could be forced into a governing coalition for the first time. Party divisions run so deep that analysts say either outcome, Ramaphosa or Dlamini-Zuma, could mean the end of the ANC’s dominance as members of the losing faction could form a new party.

“We must attend to enormous challenges facing our movement,” Zuma told the gathering, which opened with emotional appeals for unity.

He pushed back against allegations of graft, asserting that “theft and corruption” in the private sector is just as bad as in government and that “being black and successful is being made synonymous to being corrupt.”

But Zuma said “greed is posing a serious threat” to the party and pointed out warnings that the ANC could implode. “We need to find ways of protecting the ANC from corporate greed,” he said.