mirror of
https://github.com/penpot/penpot.git
synced 2025-08-03 12:48:28 +02:00
🎉 Add more reliable presence mechanism.
This commit is contained in:
parent
4b31a147a9
commit
817c22dc3c
8 changed files with 105 additions and 49 deletions
|
@ -24,8 +24,6 @@ CREATE TRIGGER task__modified_at__tgr
|
|||
BEFORE UPDATE ON task
|
||||
FOR EACH ROW EXECUTE PROCEDURE update_modified_at();
|
||||
|
||||
|
||||
|
||||
CREATE TABLE scheduled_task (
|
||||
id text PRIMARY KEY,
|
||||
|
||||
|
|
9
backend/resources/migrations/0006.presence.sql
Normal file
9
backend/resources/migrations/0006.presence.sql
Normal file
|
@ -0,0 +1,9 @@
|
|||
CREATE TABLE presence (
|
||||
file_id uuid NOT NULL REFERENCES file(id) ON DELETE CASCADE,
|
||||
profile_id uuid NOT NULL REFERENCES profile(id) ON DELETE CASCADE,
|
||||
session_id uuid NOT NULL,
|
||||
|
||||
updated_at timestamptz NOT NULL DEFAULT clock_timestamp(),
|
||||
|
||||
PRIMARY KEY (file_id, session_id, profile_id)
|
||||
);
|
Loading…
Add table
Add a link
Reference in a new issue