Service Desk errors should be logged with structured logging
Right now we have no observability into why Service Desk or other incoming email handlers are working. The current logging goes into Rails.logger
, which does no one any good: https://gitlab.com/gitlab-org/gitlab/blob/87fa73c53935669c665a3e451a854c7c35483f93/app/workers/email_receiver_worker.rb#L21-55
We should log more data about each incoming e-mail:
- Success/failure (
job_status
) - Failure reason
- Destination e-mail/project
- Source e-mail
Metrics
Additionally, we should ensure that Service Desk failures should emit the correct metrics via our normal sidekiq metrics.
Edited by Andrew Newdigate