comparison db/pubsub.sql @ 403:1dc606612405

implemented experimental "consistent_publisher" option: /!\ pgsql schema needs to be updated /!\ New "consistent_publisher" option has been implemented to allow node owners + admins to modify an item while preserving the original publisher. This way, original publisher can still edit the item. In addition to `consistent_publisher`, `max_items` has been added to PGQSL schema to prepare for future implementation.
author Goffi <goffi@goffi.org>
date Wed, 12 Jun 2019 21:51:50 +0200
parents a772f7dac930
children 5a0ada3b61ca
comparison
equal deleted inserted replaced
402:724e39d596a9 403:1dc606612405
11 CHECK (node_type IN ('leaf', 'collection')), 11 CHECK (node_type IN ('leaf', 'collection')),
12 access_model text NOT NULL DEFAULT 'open' 12 access_model text NOT NULL DEFAULT 'open'
13 CHECK (access_model IN ('open', 'presence', 'publisher-roster', 'whitelist', 'publish-only', 'self-publisher')), 13 CHECK (access_model IN ('open', 'presence', 'publisher-roster', 'whitelist', 'publish-only', 'self-publisher')),
14 persist_items boolean, 14 persist_items boolean,
15 deliver_payloads boolean NOT NULL DEFAULT TRUE, 15 deliver_payloads boolean NOT NULL DEFAULT TRUE,
16 max_items integer NOT NULL DEFAULT 0
17 CHECK (max_items >= 0),
16 serial_ids boolean NOT NULL DEFAULT FALSE, 18 serial_ids boolean NOT NULL DEFAULT FALSE,
19 consistent_publisher boolean NOT NULL DEFAULT FALSE,
17 send_last_published_item text NOT NULL DEFAULT 'on_sub' 20 send_last_published_item text NOT NULL DEFAULT 'on_sub'
18 CHECK (send_last_published_item IN ('never', 'on_sub')), 21 CHECK (send_last_published_item IN ('never', 'on_sub')),
19 publish_model text NOT NULL DEFAULT 'publishers' 22 publish_model text NOT NULL DEFAULT 'publishers'
20 CHECK (publish_model IN ('publishers', 'subscribers', 'open')), 23 CHECK (publish_model IN ('publishers', 'subscribers', 'open')),
21 schema xml 24 schema xml
100 CREATE TABLE metadata ( 103 CREATE TABLE metadata (
101 key text PRIMARY KEY, 104 key text PRIMARY KEY,
102 value text 105 value text
103 ); 106 );
104 107
105 INSERT INTO metadata VALUES ('version', '4'); 108 INSERT INTO metadata VALUES ('version', '5');