Canada's Olympic men's rugby sevens dream was extinguished Sunday in a 14-12 loss to Russia in the quarter-finals of a last-ditch qualifying tournament.

Trailing 14-7 late in the game, Canada had a chance to tie when Ciaran Hearn crashed over the line on the right flank leaving a tough conversion. Nathan Hirayama, one of the leading point-scorers on the World Series circuit, missed the kick and Russia coralled the ensuing kickoff, booting the ball into touch when the clock ran down to end the game.

The first half was a cagey affair with Russia taking a 7-0 lead with no time remaining on a converted try by German Davydov. Conor Trainor answered for Canada early in the second half with Hirayama's conversion knotting the score at 7-7.

Captain Vladimir Ostroushko broke through a pair of tackles for a converted try that gave the Russians a 14-7 lead with under three minutes to play.

In semifinal action, Spain downed Russia 17-12 and Samoa defeated Germany 26-14. Spain then topped Samoa 22-19 on a last second try by Ignacio Martin to advance to the Olympics.

Spain joins host Brazil, Argentina, Australia, Britain, Fiji, France, Japan, Kenya, New Zealand, South Africa, and the U.S. at Rio 2016.

Canada rallied to down Ireland in consolation play, then easily beat Hong Kong 24-17 to take fifth place.

It's the latest in a series of disappointments for the Canadians, who were denied making the Cup quarter-finals on tiebreakers at three stops of the World Series tour this season.

The Canadians made things difficult for themselves Saturday by losing 21-19 to Germany in their final game on Day 1 after crushing Uruguay 33-0 and Sri Lanka 57-0.

The loss meant the Canadians finished runner-up in Group B to unbeaten Germany and had to play Group C winner Russia rather than runner-up Chile.

Canada, Russia and Samoa are the only three teams in the 16th-country qualifying field that competed on the HSBC World Series this season. Samoa, which won the Paris Sevens, finished ninth overall while Canada was 13th and Russia 14th.

Canada and Russia split their six meetings on the World Series this season with the Russians winning the last two — 19-14 in Hong Kong and 33-0 in Paris.

Canada had to go the repechage route after losing 21-5 to the U.S. last June in the NACRA Sevens Cup final and finishing ninth overall in the 2014-15 World Series. The top four on the circuit that season qualified automatically for Rio.

Ireland, which upset Samoa, joined Germany as a surprise team on Day 1 in Monaco. Both sides went unbeaten along with Russia and Hong Kong.

The Canadian women have already qualified for the Olympics.