Skip to content

Failing test - Oban no longer sets priority by default #287

@bryannaegele

Description

@bryannaegele

Not a big deal but it appears Oban stopped setting priority by default on all jobs and is set to nil?

1) test records span on job insertion (OpentelemetryObanTest)
Error:      test/opentelemetry_oban_test.exs:34
     match (=) failed
     code:  assert %{
              "messaging.destination": "events",
              "messaging.destination_kind": :queue,
              "messaging.oban.job_id": _job_id,
              "messaging.oban.max_attempts": 1,
              "messaging.oban.priority": 0,
              "messaging.oban.worker": "TestJob",
              "messaging.system": :oban
            } = :otel_attributes.map(attributes)
     left:  %{
              "messaging.destination": "events",
              "messaging.destination_kind": :queue,
              "messaging.oban.job_id": _job_id,
              "messaging.oban.max_attempts": 1,
              "messaging.oban.priority": 0,
              "messaging.oban.worker": "TestJob",
              "messaging.system": :oban
            }
     right: %{
              "messaging.destination": "events",
              "messaging.destination_kind": :queue,
              "messaging.oban.job_id": 7,
              "messaging.oban.max_attempts": 1,
              "messaging.oban.priority": nil,
              "messaging.oban.worker": "TestJob",
              "messaging.system": :oban
            }
     stacktrace:
       test/opentelemetry_oban_test.exs:47: (test)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions