During this rapid expansion, the faults of the strategy started to show.
“They set the bar very high and they went too fast,” said Andreas Theophanatos, a regional director of Aqualis, an offshore services company. “They overheated the market, basically, and they promised things that were unrealistic.”
In Niterói, a city of half a million people just a half-hour drive from Rio, the Mauá shipyard struggled with an order to build four ships for Petrobras. The energy company modified its design, pushing up the cost, said Ricardo Vanderlei, Mauá’s chief executive.
Despite the financial difficulties on the initial order, the shipyard in 2008 signed up to build more vessels, believing profit would eventually materialize. It did not. Mauá delivered the first ship in the new contract, but Petrobras stopped paying for the rest, according to Mr. Vanderlei.
Mauá was left with the two unfinished vessels in the Niterói harbor, as well as another half-built ship. Mr. Vanderlei described the pair that sit unfinished in Niterói waters as “an embarrassment” that between them cost nearly $200 million and are “stuck in the Guanabara Bay, rotting.”
Petrobras’s distribution arm said in an email that it had canceled 20 contracts, including the unfinished ships at Mauá “as a result of noncompliance with contract obligations.” It did not comment further.
Despite the experience of Mauá, Brazil’s political leaders were unwavering, turning vessel launches into political rallies.
In June 2011, Mr. da Silva’s handpicked successor, President Dilma Rousseff, told thousands of cheering workers at the BrasFELS shipyard near Rio that Brazil had silenced the doubters, leaving no question that she would continue the industry efforts.
“You today can look at all of this and say, ‘We produced it. We were capable,’” she said.
The orders kept coming in. By early 2014, Petrobras’s $221 billion investment plan included building more than 100 production platforms, drilling rigs and oil tankers. In all, the country’s shipyards were employing 82,000 workers.
But many Brazilian shipyards soon started coming up against the same harsh truth as Mauá: Modern shipbuilding is a complex, highly technical and capital-intensive business.
Asian yards had a decades-long head start, said Carlos Rocha, the director of costs and technology at the Rio offices of IHS, an international consulting firm. He said Brazilian shipyards were 20 percent to 55 percent more expensive than rivals in Japan, South Korea and China. Some Brazilian deliveries took three times as long.