Don't collect alerts until the alert agent has loaded the persistent
services.

This potentialy saves a lot of work when receiving the alert triggers
rescanning the shard, which leads to duplicating the definitions
of persistent alerts in database.
When alert agent saves persistent service definition to the database
use coiteration instead of unleashing all the call at once.

This fixes a problem when there is a lot of new services
to save, which could cause other components to fail with
timeouts on startup.