Skip to content

Commit 9c97020

Browse files
committed
Round 7
1 parent 717f4a4 commit 9c97020

File tree

2 files changed

+12
-76
lines changed

2 files changed

+12
-76
lines changed
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
/*
2+
Warnings:
3+
4+
- You are about to drop the `JobVersion` table. If the table is not empty, all the data it contains will be lost.
5+
- You are about to drop the `TriggerHttpEndpoint` table. If the table is not empty, all the data it contains will be lost.
6+
7+
*/
8+
-- DropTable
9+
DROP TABLE IF EXISTS "JobVersion" CASCADE;
10+
11+
-- DropTable
12+
DROP TABLE IF EXISTS "TriggerHttpEndpoint" CASCADE;

internal-packages/database/prisma/schema.prisma

Lines changed: 0 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,6 @@ model Organization {
144144
environments RuntimeEnvironment[]
145145
endpoints Endpoint[]
146146
jobs Job[]
147-
jobVersions JobVersion[]
148147
149148
apiRateLimiterConfig Json?
150149
realtimeRateLimiterConfig Json?
@@ -337,7 +336,6 @@ model RuntimeEnvironment {
337336
tunnelId String?
338337
339338
endpoints Endpoint[]
340-
jobVersions JobVersion[]
341339
JobQueue JobQueue[]
342340
ExternalAccount ExternalAccount[]
343341
concurrencyLimitGroups ConcurrencyLimitGroup[]
@@ -404,8 +402,6 @@ model Project {
404402
environments RuntimeEnvironment[]
405403
endpoints Endpoint[]
406404
jobs Job[]
407-
jobVersion JobVersion[]
408-
httpEndpoints TriggerHttpEndpoint[]
409405
backgroundWorkers BackgroundWorker[]
410406
backgroundWorkerTasks BackgroundWorkerTask[]
411407
taskRuns TaskRun[]
@@ -460,8 +456,6 @@ model Endpoint {
460456
beforeCompleteTaskThreshold Int @default(750)
461457
afterCompleteTaskThreshold Int @default(750)
462458
463-
jobVersions JobVersion[]
464-
465459
@@unique([environmentId, slug])
466460
}
467461

@@ -477,8 +471,6 @@ model Job {
477471
project Project @relation(fields: [projectId], references: [id], onDelete: Cascade, onUpdate: Cascade)
478472
projectId String
479473
480-
versions JobVersion[]
481-
482474
createdAt DateTime @default(now())
483475
updatedAt DateTime @default(now()) @updatedAt
484476
@@ -487,48 +479,6 @@ model Job {
487479
@@unique([projectId, slug])
488480
}
489481

490-
model JobVersion {
491-
id String @id @default(cuid())
492-
version String
493-
eventSpecification Json
494-
495-
properties Json?
496-
triggerLink String?
497-
triggerHelp Json?
498-
499-
job Job @relation(fields: [jobId], references: [id], onDelete: Cascade, onUpdate: Cascade)
500-
jobId String
501-
502-
endpoint Endpoint @relation(fields: [endpointId], references: [id], onDelete: Cascade, onUpdate: Cascade)
503-
endpointId String
504-
505-
environment RuntimeEnvironment @relation(fields: [environmentId], references: [id], onDelete: Cascade, onUpdate: Cascade)
506-
environmentId String
507-
508-
organization Organization @relation(fields: [organizationId], references: [id], onDelete: Cascade, onUpdate: Cascade)
509-
organizationId String
510-
511-
project Project @relation(fields: [projectId], references: [id], onDelete: Cascade, onUpdate: Cascade)
512-
projectId String
513-
514-
queue JobQueue? @relation(fields: [queueId], references: [id])
515-
queueId String?
516-
517-
startPosition JobStartPosition @default(INITIAL)
518-
preprocessRuns Boolean @default(false)
519-
520-
concurrencyLimit Int?
521-
concurrencyLimitGroup ConcurrencyLimitGroup? @relation(fields: [concurrencyLimitGroupId], references: [id])
522-
concurrencyLimitGroupId String?
523-
524-
createdAt DateTime @default(now())
525-
updatedAt DateTime @updatedAt
526-
527-
status JobVersionStatus @default(ACTIVE)
528-
529-
@@unique([jobId, version, environmentId])
530-
}
531-
532482
enum JobVersionStatus {
533483
ACTIVE
534484
DISABLED
@@ -546,8 +496,6 @@ model ConcurrencyLimitGroup {
546496
createdAt DateTime @default(now())
547497
updatedAt DateTime @updatedAt
548498
549-
jobVersion JobVersion[]
550-
551499
@@unique([environmentId, name])
552500
}
553501

@@ -564,8 +512,6 @@ model JobQueue {
564512
jobCount Int @default(0)
565513
maxJobs Int @default(100)
566514
567-
jobVersion JobVersion[]
568-
569515
@@unique([environmentId, name])
570516
}
571517

@@ -634,7 +580,6 @@ model SecretReference {
634580
provider SecretStoreProvider @default(DATABASE)
635581
636582
integrations Integration[]
637-
httpEndpoints TriggerHttpEndpoint[]
638583
environmentVariableValues EnvironmentVariableValue[]
639584
640585
createdAt DateTime @default(now())
@@ -664,27 +609,6 @@ enum TriggerChannel {
664609
SMTP
665610
}
666611

667-
model TriggerHttpEndpoint {
668-
id String @id @default(cuid())
669-
670-
key String
671-
672-
title String?
673-
icon String?
674-
properties Json?
675-
676-
secretReference SecretReference @relation(fields: [secretReferenceId], references: [id], onDelete: Cascade, onUpdate: Cascade)
677-
secretReferenceId String
678-
679-
project Project @relation(fields: [projectId], references: [id], onDelete: Cascade, onUpdate: Cascade)
680-
projectId String
681-
682-
createdAt DateTime @default(now())
683-
updatedAt DateTime @updatedAt
684-
685-
@@unique([key, projectId])
686-
}
687-
688612
model DataMigration {
689613
id String @id @default(cuid())
690614
name String @unique

0 commit comments

Comments
 (0)