Refactor collector service for better error handling

The following discussions from !73557 (merged) should be addressed:

Edited by Peter Leitzen