Metaswitch/sprout — pull request #156 by mike-evans (2013-07-17 09:13:46+00:00)
Title: [Reviewer Andy] Restart flow idle timer when forwarding REGISTER to sprout

Andy

Can you review this fix to https://github.com/Metaswitch/sprout/issues/155. I was continuing to get periodic live-test failure emails from Jenkins, and investigating one of these showed there is an issue with flows timing out while REGISTERs are still pending at sprout. It seems like a pretty small race condition, possibly made more likely by some resonance with the frequency with which Jenkins runs the live tests (15 minutes, vs the 10 minute idle timer for a flow) - but the traces were absolutely definitive that this is what had happened.

I also took the opportunity to clear up a couple of places where the tracing wasn't 100% clear.

I've tested it by running the UTs and the live tests a few times - trying to hit the 10 minute window - but the acid test will be whether I stop getting these damn emails from Jenkins. I will look at whether it would be possible to create a UT which hits it - but the timing may be too difficult.

Mike