diff --git a/packages/db/drizzle/meta/0008_snapshot.json b/packages/db/drizzle/meta/0008_snapshot.json
index 3c1309b4..96112d0f 100644
--- a/packages/db/drizzle/meta/0008_snapshot.json
+++ b/packages/db/drizzle/meta/0008_snapshot.json
@@ -58,12 +58,8 @@
"name": "incident_workspace_id_workspace_id_fk",
"tableFrom": "incident",
"tableTo": "workspace",
- "columnsFrom": [
- "workspace_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["workspace_id"],
+ "columnsTo": ["id"],
"onDelete": "no action",
"onUpdate": "no action"
}
@@ -132,12 +128,8 @@
"name": "incident_update_incident_id_incident_id_fk",
"tableFrom": "incident_update",
"tableTo": "incident",
- "columnsFrom": [
- "incident_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["incident_id"],
+ "columnsTo": ["id"],
"onDelete": "cascade",
"onUpdate": "no action"
}
@@ -169,12 +161,8 @@
"name": "incidents_to_monitors_monitor_id_monitor_id_fk",
"tableFrom": "incidents_to_monitors",
"tableTo": "monitor",
- "columnsFrom": [
- "monitor_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["monitor_id"],
+ "columnsTo": ["id"],
"onDelete": "cascade",
"onUpdate": "no action"
},
@@ -182,22 +170,15 @@
"name": "incidents_to_monitors_incident_id_incident_id_fk",
"tableFrom": "incidents_to_monitors",
"tableTo": "incident",
- "columnsFrom": [
- "incident_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["incident_id"],
+ "columnsTo": ["id"],
"onDelete": "cascade",
"onUpdate": "no action"
}
},
"compositePrimaryKeys": {
"incidents_to_monitors_monitor_id_incident_id_pk": {
- "columns": [
- "incident_id",
- "monitor_id"
- ]
+ "columns": ["incident_id", "monitor_id"]
}
},
"uniqueConstraints": {}
@@ -270,12 +251,8 @@
"name": "integration_workspace_id_workspace_id_fk",
"tableFrom": "integration",
"tableTo": "workspace",
- "columnsFrom": [
- "workspace_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["workspace_id"],
+ "columnsTo": ["id"],
"onDelete": "no action",
"onUpdate": "no action"
}
@@ -364,9 +341,7 @@
"indexes": {
"page_slug_unique": {
"name": "page_slug_unique",
- "columns": [
- "slug"
- ],
+ "columns": ["slug"],
"isUnique": true
}
},
@@ -375,12 +350,8 @@
"name": "page_workspace_id_workspace_id_fk",
"tableFrom": "page",
"tableTo": "workspace",
- "columnsFrom": [
- "workspace_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["workspace_id"],
+ "columnsTo": ["id"],
"onDelete": "cascade",
"onUpdate": "no action"
}
@@ -440,7 +411,7 @@
},
"url": {
"name": "url",
- "type": "text(512)",
+ "type": "text(2048)",
"primaryKey": false,
"notNull": true,
"autoincrement": false
@@ -515,12 +486,8 @@
"name": "monitor_workspace_id_workspace_id_fk",
"tableFrom": "monitor",
"tableTo": "workspace",
- "columnsFrom": [
- "workspace_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["workspace_id"],
+ "columnsTo": ["id"],
"onDelete": "no action",
"onUpdate": "no action"
}
@@ -552,12 +519,8 @@
"name": "monitors_to_pages_monitor_id_monitor_id_fk",
"tableFrom": "monitors_to_pages",
"tableTo": "monitor",
- "columnsFrom": [
- "monitor_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["monitor_id"],
+ "columnsTo": ["id"],
"onDelete": "cascade",
"onUpdate": "no action"
},
@@ -565,22 +528,15 @@
"name": "monitors_to_pages_page_id_page_id_fk",
"tableFrom": "monitors_to_pages",
"tableTo": "page",
- "columnsFrom": [
- "page_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["page_id"],
+ "columnsTo": ["id"],
"onDelete": "cascade",
"onUpdate": "no action"
}
},
"compositePrimaryKeys": {
"monitors_to_pages_monitor_id_page_id_pk": {
- "columns": [
- "monitor_id",
- "page_id"
- ]
+ "columns": ["monitor_id", "page_id"]
}
},
"uniqueConstraints": {}
@@ -654,9 +610,7 @@
"indexes": {
"user_tenant_id_unique": {
"name": "user_tenant_id_unique",
- "columns": [
- "tenant_id"
- ],
+ "columns": ["tenant_id"],
"isUnique": true
}
},
@@ -688,12 +642,8 @@
"name": "users_to_workspaces_user_id_user_id_fk",
"tableFrom": "users_to_workspaces",
"tableTo": "user",
- "columnsFrom": [
- "user_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["user_id"],
+ "columnsTo": ["id"],
"onDelete": "no action",
"onUpdate": "no action"
},
@@ -701,22 +651,15 @@
"name": "users_to_workspaces_workspace_id_workspace_id_fk",
"tableFrom": "users_to_workspaces",
"tableTo": "workspace",
- "columnsFrom": [
- "workspace_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["workspace_id"],
+ "columnsTo": ["id"],
"onDelete": "no action",
"onUpdate": "no action"
}
},
"compositePrimaryKeys": {
"users_to_workspaces_user_id_workspace_id_pk": {
- "columns": [
- "user_id",
- "workspace_id"
- ]
+ "columns": ["user_id", "workspace_id"]
}
},
"uniqueConstraints": {}
@@ -800,16 +743,12 @@
"indexes": {
"workspace_slug_unique": {
"name": "workspace_slug_unique",
- "columns": [
- "slug"
- ],
+ "columns": ["slug"],
"isUnique": true
},
"workspace_stripe_id_unique": {
"name": "workspace_stripe_id_unique",
- "columns": [
- "stripe_id"
- ],
+ "columns": ["stripe_id"],
"isUnique": true
}
},
@@ -879,12 +818,8 @@
"name": "notification_workspace_id_workspace_id_fk",
"tableFrom": "notification",
"tableTo": "workspace",
- "columnsFrom": [
- "workspace_id"
- ],
- "columnsTo": [
- "id"
- ],
+ "columnsFrom": ["workspace_id"],
+ "columnsTo": ["id"],
"onDelete": "no action",
"onUpdate": "no action"
}
@@ -902,8 +837,8 @@
"notNull": true,
"autoincrement": false
},
- "notificationId": {
- "name": "notificationId",
+ "notification_id": {
+ "name": "notification_id",
"type": "integer",
"primaryKey": false,
"notNull": true,
@@ -916,35 +851,24 @@
"name": "notifications_to_monitors_monitor_id_monitor_id_fk",
"tableFrom": "notifications_to_monitors",
"tableTo": "monitor",
- "columnsFrom": [
- "monitor_id"
- ],
- "columnsTo": [
- "id"
- ],
- "onDelete": "no action",
+ "columnsFrom": ["monitor_id"],
+ "columnsTo": ["id"],
+ "onDelete": "cascade",
"onUpdate": "no action"
},
- "notifications_to_monitors_notificationId_notification_id_fk": {
- "name": "notifications_to_monitors_notificationId_notification_id_fk",
+ "notifications_to_monitors_notification_id_notification_id_fk": {
+ "name": "notifications_to_monitors_notification_id_notification_id_fk",
"tableFrom": "notifications_to_monitors",
"tableTo": "notification",
- "columnsFrom": [
- "notificationId"
- ],
- "columnsTo": [
- "id"
- ],
- "onDelete": "no action",
+ "columnsFrom": ["notification_id"],
+ "columnsTo": ["id"],
+ "onDelete": "cascade",
"onUpdate": "no action"
}
},
"compositePrimaryKeys": {
- "notifications_to_monitors_monitor_id_notificationId_pk": {
- "columns": [
- "monitor_id",
- "notificationId"
- ]
+ "notifications_to_monitors_monitor_id_notification_id_pk": {
+ "columns": ["monitor_id", "notification_id"]
}
},
"uniqueConstraints": {}
@@ -956,4 +880,4 @@
"tables": {},
"columns": {}
}
-}
\ No newline at end of file
+}
diff --git a/packages/db/src/schema/monitor.ts b/packages/db/src/schema/monitor.ts
index 52fc10e5..e76d970b 100644
--- a/packages/db/src/schema/monitor.ts
+++ b/packages/db/src/schema/monitor.ts
@@ -54,7 +54,7 @@ export const monitor = sqliteTable("monitor", {
regions: text("regions").default("").notNull(),
- url: text("url", { length: 512 }).notNull(),
+ url: text("url", { length: 2048 }).notNull(),
name: text("name", { length: 256 }).default("").notNull(),
description: text("description").default("").notNull(),
diff --git a/packages/db/src/schema/page.ts b/packages/db/src/schema/page.ts
index f26792f4..0b7e5bce 100644
--- a/packages/db/src/schema/page.ts
+++ b/packages/db/src/schema/page.ts
@@ -3,7 +3,7 @@ import { integer, sqliteTable, text } from "drizzle-orm/sqlite-core";
import { createInsertSchema, createSelectSchema } from "drizzle-zod";
import { z } from "zod";
-import { monitor, monitorsToPages, selectMonitorSchema } from "./monitor";
+import { monitorsToPages } from "./monitor";
import { workspace } from "./workspace";
export const page = sqliteTable("page", {
diff --git a/packages/emails/emails/welcome.tsx b/packages/emails/emails/welcome.tsx
index 76a1beab..9acfa766 100644
--- a/packages/emails/emails/welcome.tsx
+++ b/packages/emails/emails/welcome.tsx
@@ -17,7 +17,7 @@ const WelcomeEmail = () => {
What kind of apps are going to monitor?
- Where do you host your apps?
+ How do you handle your incidents?
Thank you,