Implement lab4 S3 attachments and resilience

This commit is contained in:
2026-11-16 23:15:06 +03:00
parent ec540a1a72
commit 6fd4f402aa
28 changed files with 1899 additions and 18 deletions
@@ -0,0 +1,13 @@
-- Lab4: messages with attachments may have empty text.
-- The API checks that a message contains text or attachments.
ALTER TABLE messages
DROP CONSTRAINT IF EXISTS message_length;
ALTER TABLE messages
DROP CONSTRAINT IF EXISTS message_not_blank;
ALTER TABLE messages
ADD CONSTRAINT message_length
CHECK (char_length(text) <= 4000);