-
Notifications
You must be signed in to change notification settings - Fork 113
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[front] - chore: agent message deletion relation (#9152)
* [front/lib/api/assistant/conversation] - feature: add agent message content deletion in conversation destruction - Include AgentMessageContent destruction in the `destroyConversation` flow to ensure clean-up of message contents [front/lib/models/assistant] - refactor: change delete behavior for AgentMessageContent associations - Modify onDelete and onUpdate behavior from "CASCADE" to "RESTRICT" to prevent automatic deletion or updates [front/poke/temporal] - feature: integrate agent message content deletion in temporal activities - Implement deletion of AgentMessageContent within the deleteConversationsActivity to maintain consistency * [db] - fix: update foreign key constraint on agent_message_contents - Drop the old foreign key constraint on agentMessageId - Re-add the foreign key constraint to enforce referential integrity with agent_messages table with both DELETE and UPDATE actions restricted * [migrations] - refactor: rename migration file from 125 to 126 - Incremented migration file to reflect the correct sequencing in migrations directory * [migrations] - refactor: rename migration file from 126 to 128 - Incremented migration file to reflect the correct sequencing in migrations directory --------- Co-authored-by: Aubin <aubin@dust.tt>
- Loading branch information
1 parent
7e4d33f
commit b53a7d5
Showing
4 changed files
with
21 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
ALTER TABLE "agent_message_contents" | ||
DROP CONSTRAINT "agent_message_contents_agentMessageId_fkey", | ||
ADD CONSTRAINT "agent_message_contents_agentMessageId_fkey" | ||
FOREIGN KEY ("agentMessageId") | ||
REFERENCES "agent_messages"("id") | ||
ON DELETE RESTRICT | ||
ON UPDATE RESTRICT; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters