It's as predictable as the fixed, two-year calendar for the Olympics themselves.

Before every edition of the Games - winter or summer, rich or developing world - a litany of complaints, criticisms and doomsday predictions play out in the news media and among foreigners and host country locals alike.

Beijing was going to snap under the tension of East versus West sensibilities. London was going to grind to a standstill, paralyzed by security fears. In the days before Sochi started two years ago, social media crackled with criticism and images mocking Russian workmanship.

In Brazil, as Rio de Janeiro gears up for the opening ceremony on Friday, a slew of problems have indeed made many question the success of the Games - from a recession, to cost overruns, to forced evictions, to pernicious pollution, to the collapse of a new bike path that killed two people.

An outbreak of the Zika virus, a corruption investigation that jailed dozens of politicians and rich executives, and a political crisis prompting the president's impeachment have also battered Brazil's reputation and self-confidence.

But with as many as 500,000 foreign visitors descending upon Rio just days before show time, a familiar sense of anticipation and festivity are leading many to come to another habitual realization: Things might actually go okay.

"Despite all the talk and all the media, I think Brazil is going to pull off a great Olympics," said Farhad Panahi, a visitor from Toronto, enjoying the contrast from on high between verdant mountains and playful beaches during a tour of Rio's iconic Christ statue. "It's going to be fun and the city is going to have a good time."

True, plenty could still go wrong, even forgetting the financial hangover expected after Brazil spent about 40 billion reais ($12.3 billion) to host the Games just as it reels from its worst economic downturn since the Great Depression.

Traffic jams and other logistical problems could make for long waits and missed events. Quick fixes and last-minute construction could still cause problems at venues and Olympic housing. And the threat of terrorism, at a time of growing attacks by militants, continues to hang over the event.

Even concerns over Zika infections, which have waned dramatically during Brazil's winter because lower temperatures slow reproduction of the mosquito that spreads the virus, could intensify if a sustained heat wave caused the bugs to rebound.

But Brazil, aware of its possible shortcomings, is relying on massive manpower to help things go smoothly - a trick it has successfully used during previous big events, including the 2014 World Cup soccer tournament and giant annual Carnival and New Year's celebrations.

More than 85,000 police, soldiers and other security personnel will be on hand - over twice the force deployed during the London Olympics in 2012. More than 50,000 volunteers will be in place across the city to help wayward visitors.

'A way to rejoice'

What's more, Brazil has a history of being able to put spectacle first, no matter its other travails.

"You think slaves had reason to party?" asks Haroldo Costa, a historian of Carnival and other popular festivals in Brazil. "Yet it was their song and dance that led to our popular festivals. Brazil, no matter the circumstances, finds a way to rejoice."

After traffic jams early this week, Mayor Eduardo Paes declared that Thursday, when the Olympic torch ends its three-month journey across Brazil, would be yet another official holiday - the fourth now decreed to reduce traffic during the busiest Olympic days. Public holidays helped grease the wheels during the World Cup, too.

Never mind the complaints of industry, small business owners and others who lose revenue, and still pay overheads, with every holiday.

For those here to enjoy themselves, it's all the more reason to have a good time. "This is like a dream," said Miguel Vizcainho, a 23-year-old law student from Argentina.

He and three friends, holders of Olympic volleyball and table-tennis tickets, filled an inflatable boat with ice, vodka bottles and juice on Copacabana beach. The sun beat down from a blue sky as tourists and locals took in its warmth and the pre-Olympic buzz now palpable around town.

It's not that visitors are unaware of the problems.

Vizcainho said reports of rising crime gave him and his friends pause before they decided to come anyway.

Others said they had to brush off fears about Zika despite the fact that infection rates now have fallen to a fraction of what they were at the height of Brazil's scare earlier this year.

And even those well aware of the nightmare scenario at such a big sports and tourism events - terrorism - say they are expecting things to go well.

"It's probably safer here than being in a European country," said Jon Lane, a 30-year-old physical education teacher from England, noting the recent tide of attacks in Germany, Belgium and France.