Dylan Teuns held on to win the Tour of Poland by just two seconds from home favourite Rafal Majka following Friday's seventh and final stage won by Wout Poels.
Majka finished third on the 132.5km stage from Bukovina Resort to Bukowina Tatrzanska behind Briton Adam Yates in second to pick up four bonus seconds.
But having started the day six seconds back from Belgian Tuens, the 2014 champion missed out on a second victory in his home Tour by just two seconds.
Dutchman Poels of Team Sky finished third at 3sec thanks to his 10sec bonus for winning the stage, while Yates moved up to fifth thanks to his 6sec bonus.
Teuns succeeded compatriot Tim Wellens as champion.
But it was a poor final stage from Italian Vincenzo Nibali ahead of his tilt at the Vuelta a Espana later this month.
One of just six cyclists to have won all three Grand Tours, Nibali started the day just 25sec off the lead but came home almost a minute down and finished ninth overall.
Winner of the Tour de France in 2014 and the Giro d'Italia in 2013 and 2016, Nibali is aiming to add a second Vuelta crown following his 2010 success but will face stiff opposition in current Tour champion Chris Froome, Frenchman Romain Bardet, compatriot Fabio Aru and Yates.