fix(server): Add missing PG migrations (#7619)

missing migrations
This commit is contained in:
Aarushi
2024-07-26 14:38:05 +01:00
committed by GitHub
parent b2dba39810
commit da2111bafb
2 changed files with 12 additions and 1 deletions

View File

@@ -0,0 +1,8 @@
/*
Warnings:
- A unique constraint covering the columns `[referencedByInputExecId,referencedByOutputExecId,name]` on the table `AgentNodeExecutionInputOutput` will be added. If there are existing duplicate values, this will fail.
*/
-- CreateIndex
CREATE UNIQUE INDEX "AgentNodeExecutionInputOutput_referencedByInputExecId_refer_key" ON "AgentNodeExecutionInputOutput"("referencedByInputExecId", "referencedByOutputExecId", "name");

View File

@@ -127,6 +127,9 @@ model AgentNodeExecutionInputOutput {
ReferencedByInputExec AgentNodeExecution? @relation("AgentNodeExecutionInput", fields: [referencedByInputExecId], references: [id])
referencedByOutputExecId String?
ReferencedByOutputExec AgentNodeExecution? @relation("AgentNodeExecutionOutput", fields: [referencedByOutputExecId], references: [id])
// Input and Output pin names are unique for each AgentNodeExecution.
@@unique([referencedByInputExecId, referencedByOutputExecId, name])
}
// This model describes the recurring execution schedule of an Agent.
@@ -145,4 +148,4 @@ model AgentGraphExecutionSchedule {
lastUpdated DateTime @updatedAt
@@index([isEnabled])
}
}