Refactor event queue to allow multiple types of events

This commit is contained in:
Dominic Ferrando
2026-07-12 05:21:33 -04:00
parent 4d1b3bc3ef
commit 4c2acfaede
5 changed files with 88 additions and 60 deletions
@@ -5,6 +5,7 @@ export async function up(db: Kysely<any>): Promise<void> {
// TABLE: EVENTS
await db.schema.createTable("events")
.$call(addDefaultColumns)
.addColumn("group", "text", (cb) => cb.notNull())
.addColumn("type", "text", (cb) => cb.notNull())
.addColumn("source", "text", (cb) => cb.notNull())
.addColumn("payload", "jsonb", (cb) => cb.notNull())