zuul/zuul/trigger
James E. Blair 9b41a0b502 Properly shutdown apscheduler on reconfigure
This addresses a recent increase in test_idle failures.  The
existing apscheduler was not being shut down during reconfigurations
which caused us to end up with two apschedulers running during the
test.  This could cause a trigger event to fire while the test
was expecting the system to be idle.

The triggers were not previously shut down during reconfigurations.
Instead, the timer trigger relied on having its postConfig method
called on each reconfiguration, where it would begin by cleaning
up any existing jobs.  However, since the connections changes,
triggers are stopped, discarded, and recreated during reconfiguration.
Because the stop method of the timer trigger was not actually being
called, a new trigger was created each time we reconfigured, and old
ones were never cleaned up.

This likely had a production impact as well, however, it was not
likely to be visible unless a configuration change altered the
scheduled times for periodic queues (in that case, we would see jobs
run at both the old and new times).

Change-Id: Ia7c61984a9c47a9b1554a4ccb99309674dffec11
2016-05-12 11:36:16 -07:00
..
__init__.py Add support for 'connection' concept 2015-12-06 14:48:32 +11:00
gerrit.py Add support for 'connection' concept 2015-12-06 14:48:32 +11:00
timer.py Properly shutdown apscheduler on reconfigure 2016-05-12 11:36:16 -07:00
zuultrigger.py Add support for 'connection' concept 2015-12-06 14:48:32 +11:00