ЛР5: RabbitMQ + worker, async pipeline, outbox, retry/backoff, variants
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
-- lab5: constraint attachments_error_code должен знать про queued/processing.
|
||||
-- Идемпотентно: DROP IF EXISTS — можно применять повторно.
|
||||
ALTER TABLE attachments DROP CONSTRAINT IF EXISTS attachments_error_code;
|
||||
ALTER TABLE attachments ADD CONSTRAINT attachments_error_code CHECK (
|
||||
(status = 'failed') = (error_code IS NOT NULL)
|
||||
);
|
||||
Reference in New Issue
Block a user