Cancel failed tasks every 5 ticks instead of 100 to save time/space