Jconnor 889893 scheduled sync collisions

Fix for scheduled calls that take longer than an interval to execute
Fix for race condition between updating of next_run field and completion of scheduled call