{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "insights/v1/events/honeybadger-ruby/perform.active_job.json",
  "title": "ActiveJob: perform",
  "description": "An Active Job job ran, whether it succeeded or raised an exception.",
  "x-hb": {
    "notifiers": [
      "honeybadger-ruby"
    ],
    "category": "jobs",
    "component": "Active Job"
  },
  "examples": [
    {
      "event_type": "perform.active_job",
      "job_class": "WelcomeEmailJob",
      "job_id": "b1d2e3f4-5a6b-4c7d-8e9f-0a1b2c3d4e5f",
      "queue_name": "default",
      "adapter_class": "ActiveJob::QueueAdapters::SidekiqAdapter",
      "status": "success",
      "duration": 532.18,
      "instrumenter_id": "d6a5b3f4c2e1908a7b6c",
      "request_id": "0f5e4bb2-3c46-4b1c-91d5-2f4e8a6b9c01",
      "hostname": "worker-1.example.com",
      "environment": "production"
    }
  ],
  "type": "object",
  "properties": {
    "event_type": {
      "type": "string",
      "const": "perform.active_job"
    },
    "job_class": {
      "type": "string",
      "description": "ActiveJob class name.",
      "examples": [
        "WelcomeEmailJob"
      ]
    },
    "job_id": {
      "type": "string",
      "description": "Unique job identifier.",
      "examples": [
        "b1d2e3f4-5a6b-4c7d-8e9f-0a1b2c3d4e5f"
      ]
    },
    "queue_name": {
      "type": "string",
      "description": "Queue the job ran on.",
      "examples": [
        "default"
      ]
    },
    "adapter_class": {
      "type": "string",
      "description": "ActiveJob adapter class, e.g. \"SidekiqAdapter\".",
      "examples": [
        "ActiveJob::QueueAdapters::SidekiqAdapter"
      ]
    },
    "status": {
      "type": "string",
      "enum": [
        "success",
        "failure"
      ],
      "description": "Job execution outcome: 'success' if completed without exception, 'failure' if an exception was raised.",
      "examples": [
        "success"
      ]
    },
    "exception_object": {
      "type": "string",
      "description": "The exception instance if the job raised, absent on success. Serialized as a string in JSON format.",
      "examples": [
        "#<ActiveRecord::RecordNotFound: Couldn't find User with 'id'=123>"
      ]
    },
    "duration": {
      "type": "number",
      "description": "Duration in milliseconds.",
      "examples": [
        532.18
      ]
    },
    "instrumenter_id": {
      "type": "string",
      "description": "Rails ActiveSupport::Notifications instrumenter UUID.",
      "examples": [
        "d6a5b3f4c2e1908a7b6c"
      ]
    },
    "request_id": {
      "type": "string",
      "description": "Rails request UUID from the active web request context, if any. Merged globally by the Honeybadger agent.",
      "examples": [
        "0f5e4bb2-3c46-4b1c-91d5-2f4e8a6b9c01"
      ]
    },
    "hostname": {
      "type": "string",
      "description": "Server hostname. Attached to every event by default (events.attach_hostname).",
      "examples": [
        "web-1.example.com"
      ]
    },
    "environment": {
      "type": "string",
      "description": "Application environment, e.g. \"production\". Attached to every event by default (events.attach_environment).",
      "examples": [
        "production"
      ]
    }
  },
  "required": [
    "event_type",
    "job_class",
    "job_id",
    "status"
  ]
}
