Sha256: d3ef0e0b1eeb31e4adea264894317101029759f70b873491b228424e2ae09c30

Contents?: true

Size: 510 Bytes

Versions: 3

Compression:

Stored size: 510 Bytes

Contents

# frozen_string_literal: true

module Panoptic
  class FailedJob < SolidQueue::Job
    # TODO: use the `failed` scope available in SolidQueue next release
    default_scope { joins(:failed_execution) }

    def enqueued_at
      Time.parse(arguments["enqueued_at"])
    end

    def exception_class
      failed_execution.error["exception_class"]
    end

    def exception_message
      failed_execution.error["message"]
    end

    def stacktrace
      failed_execution.error["backtrace"]
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
panoptic-0.4.1 app/models/panoptic/failed_job.rb
panoptic-0.4.0 app/models/panoptic/failed_job.rb
panoptic-0.3.0 app/models/panoptic/failed_job.rb