Festering anti-China tensions have erupted in Vietnam with riots at foreign-owned factories after Beijing moved a deep-sea oil drilling rig into contested waters.

Here are some questions and answers on the sudden surge of violence.

What triggered the unrest?

China's deployment in early May of the oil rig in disputed seas near the Paracel Islands has provided the catalyst for a crisis long in the making.

Hanoi says Beijing sent 80 vessels including warships to guard the drilling platform in the South China Sea, considered one of Asia's most dangerous flashpoints.

Vietnam dispatched about 40 of its own ships to the area -- believed to sit atop vast natural resources -- and both countries have accused the other of ramming their vessels.

"China's message is that it is dominant and Vietnam must submit. This is fuel for patriotic and nationalist anti-China sentiment," said Carl Thayer, a professor at the University of New South Wales in Australia.

The spat taps into deep-seated enmity between the communist neighbours and spurs nationalist fervour in both countries.

The two nations fought bloody naval battles over the contested islands Paracel and Spratly islands in 1974 and 1988, and a border war that left tens of thousands dead on both sides in 1979.

Since Wednesday riots have fanned out across Vietnam affecting hundreds of foreign-owned factories, leaving at least one Chinese worker dead and more than 100 wounded in unrest that provoked an angry response from Beijing.

"I think China has badly miscalculated with its deployment of the oil rig," said Bill Hayton, author of "Vietnam: Rising Dragon".

"It has simultaneously outraged Vietnamese public opinion, hardened attitudes in the Vietnamese government, revitalised the 'China Threat' narrative in Southeast Asia and made the region more receptive to the United States' 'pivot' to Asia," he said.

Why target non-Chinese factories?

Taiwanese, Korean and Singaporean plants have also been targeted by rioters.

Experts say that behind the patriotic fervour lies simmering discontent in Vietnam towards foreign workers and employers.

"There is an undercurrent of resentment toward Chinese workers who have managed to come into Vietnam and take jobs local Vietnamese feel are theirs," said Thayer.

"Then there is resentment at South Korean and Taiwanese managers and bosses who impose strict discipline on their workforce and who fail to pay for overtime and dock pay for trivial infraction of their rules," he said.

What impact on foreign investment?

Export-orientated manufacturing is a key pillar of Vietnam's economy, with electronics giants such as South Korea's Samsung and US sportswear companies like Nike among those producing goods there.

An exodus of foreign firms would deal a heavy blow to an economy already hit by sluggish domestic demand, banking sector troubles and financial malaise among state-owned companies.

"Foreign investors had concerns about the Vietnamese regulatory environment and governance, but they felt they were entering a secure and safe location. The riots have called that safety into question," said Edmund Malesky, associate professor of political economy at Duke University in the United States.

But if authorities bring the situation under control quickly, experts say the impact could be limited.

"My guess is that most investors will see this as a tiny blemish against the large backdrop of Vietnam's structural conditions," such as a pool of cheap labour, favourable demographics, a record of strong economic growth and the country's proximity to export markets, Malesky said.

What next?

Experts say Hanoi has allowed some public protests to go ahead as a means of expressing extreme discontent with Beijing, but must now act to stop the violence spiralling.

The communist leadership "has a difficult task of riding popular opinion in such a way that it doesn't appear to be doing China's bidding but isn't letting the situation get out of control either," said Hayton.

"Initially the riots may have helped Vietnam's diplomatic struggle with China -- it shows how hard it will be for them to back down in the current stand-off and provide an argument for why China needs to back down."

Experts say Vietnam's authoritarian communist rulers, who usually keep a tight rein on public dissent, have the capability to crack down hard on the unrest if needed.

"The government has considerable assets to use to restore law and order including urban local self-defence groups and rural militia, the military and the people's armed police. The situation is uncertain but further outbreaks are likely to be squelched," said Thayer.