Skip to content

omdb db alert webhook receiver show <NAME> does a full scan for some reason #10850

Description

@hawkw
[dublin]root@oxz_switch0:~# omdb db alert webhook rx show test-webhook-rx-colo
note: database URL not specified.  Will search DNS.
note: (override with --db-url or OMDB_DB_URL)
note: using DNS from system config (typically /etc/resolv.conf)
note: (if this is not right, use --dns-server to specify an alternate DNS server)
note: using database URL postgresql://root@[fd46:767a:52cb:103::3]:32221,[fd46:767a:52cb:101::3]:32221,[fd46:767a:52cb:104::3]:32221,[fd46:767a:52cb:104::4]:32221,[fd46:767a:52cb:102::3]:32221/omicron?sslmode=disable
note: database schema version matches expected (278.0.0)
Error: loading webhook receiver test-webhook-rx-colo

Caused by:
    0: loading webhook_receiver test-webhook-rx-colo
    1: query `SELECT "alert_receiver"."id", "alert_receiver"."name", "alert_receiver"."description", "alert_receiver"."time_created", "alert_receiver"."time_modified", "alert_receiver"."time_deleted", "alert_receiver"."endpoint", "alert_receiver"."secret_gen", "alert_receiver"."subscription_gen" FROM "alert_receiver" WHERE ("alert_receiver"."name" = $1) LIMIT $2` contains a full table/index scan which is explicitly disallowed
[dublin]root@oxz_switch0:~# omdb db alert webhook rx show 86683493-5c37-4c9f-91b9-844aed280475
note: database URL not specified.  Will search DNS.
note: (override with --db-url or OMDB_DB_URL)
note: using DNS from system config (typically /etc/resolv.conf)
note: (if this is not right, use --dns-server to specify an alternate DNS server)
note: using database URL postgresql://root@[fd46:767a:52cb:103::3]:32221,[fd46:767a:52cb:101::3]:32221,[fd46:767a:52cb:104::3]:32221,[fd46:767a:52cb:104::4]:32221,[fd46:767a:52cb:102::3]:32221/omicron?sslmode=disable
note: database schema version matches expected (278.0.0)

== RECEIVER ====================================================================
                     name: test-webhook-rx-colo
                       ID: 86683493-5c37-4c9f-91b9-844aed280475
              description: Test webhook receiver on colo rack
                 endpoint: http://45.154.216.89/

               created at: 2026-07-16 22:00:32.687511 UTC
              modified at: 2026-07-16 22:00:32.687511 UTC

== SECRETS =====================================================================
               generation: 2
id                                   created                  deleted
50930ee0-02a4-4e8a-9583-d84e1e271ef1 2026-07-16T22:00:32.693Z -

== SUBSCRIPTIONS ===============================================================
               generation: 3
      exact subscriptions: 0
       glob subscriptions: 1
    - hardware.**
               created at: 2026-07-16 22:00:32.689619 UTC
           schema version: 278.0.0
                    regex: ^hardware\..+$
      exact subscriptions: 2
      - hardware.power_shelf.psu.insert
      - hardware.power_shelf.psu.remove
[dublin]root@oxz_switch0:~#

This made me wonder if I had forgotten to add an index for looking them up by name. But, when I actually request it through the API it works, at least, so it's only omdb that's broken?

eliza@theseus ~/Code/oxide/oxide.rs $ ./cli.sh alert receiver view --receiver test-webhook-rx-colo
    Finished `release` profile [optimized] target(s) in 0.18s
     Running `target/release/oxide alert receiver view --receiver test-webhook-rx-colo`
{
  "description": "Test webhook receiver on colo rack",
  "id": "86683493-5c37-4c9f-91b9-844aed280475",
  "kind": {
    "kind": "webhook",
    "endpoint": "http://45.154.216.89/",
    "secrets": [
      {
        "id": "50930ee0-02a4-4e8a-9583-d84e1e271ef1",
        "time_created": "2026-07-16T22:00:32.693604Z"
      }
    ]
  },
  "name": "test-webhook-rx-colo",
  "subscriptions": [
    "hardware.**"
  ],
  "time_created": "2026-07-16T22:00:32.687511Z",
  "time_modified": "2026-07-16T22:00:32.687511Z"
}

eliza@theseus ~/Code/oxide/oxide.rs $

Metadata

Metadata

Assignees

Labels

DebuggingFor when you want better data in debugging an issue (log messages, post mortem debugging, and more)fault-managementEverything related to the fault-management initiative (RFD480 and others)

Type

Fields

No fields configured for Bug.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions