Peter Sagan became the first rider since 2007 to retain his world championship road race title when he perfectly timed his sprint in Doha on Sunday.