• Stan Hu's avatar
    Make Sidekiq timestamps consistently ISO 8601 · f89237f0
    Stan Hu authored
    Previously when an exception occurred in Sidekiq, Sidekiq would export
    logs with timestamps (e.g. created_at, enqueued_at) in floating point
    seconds, while other jobs would report in ISO 8601 format. This
    inconsistency in data types would cause Elasticsearch to drop logs that
    did not match the schema type (date in most cases).
    
    This commit moves the responsibility of formatting timestamps to the
    Sidekiq JSON formatter where it properly belongs. The job logger now
    generates timestamps with floats, just as Sidekiq does. This ensures
    that timestamps are manipulated only in one place.
    
    See https://gitlab.com/gitlab-com/gl-infra/infrastructure/issues/8269
    f89237f0
sh-fix-sidekiq-timestamps.yml 98 Bytes