From 7511da0f266e61fa12c640bd418606baca4c78ed Mon Sep 17 00:00:00 2001 From: Evgeny Khramtsov Date: Wed, 27 Feb 2019 13:06:17 +0300 Subject: Add SQL schemas for MQTT tables --- sql/mysql.new.sql | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'sql/mysql.new.sql') diff --git a/sql/mysql.new.sql b/sql/mysql.new.sql index 39df58c55..a10e21d91 100644 --- a/sql/mysql.new.sql +++ b/sql/mysql.new.sql @@ -480,3 +480,19 @@ CREATE TABLE mix_pam ( CREATE UNIQUE INDEX i_mix_pam ON mix_pam (username(191), server_host(191), channel(191), service(191)); CREATE INDEX i_mix_pam_us ON mix_pam (username(191), server_host(191)); + +CREATE TABLE mqtt_pub ( + username varchar(191) NOT NULL, + server_host varchar(191) NOT NULL, + resource varchar(191) NOT NULL, + topic text NOT NULL, + qos tinyint NOT NULL, + payload blob NOT NULL, + payload_format tinyint NOT NULL, + content_type text NOT NULL, + response_topic text NOT NULL, + correlation_data blob NOT NULL, + user_properties blob NOT NULL, + expiry int unsigned NOT NULL, + UNIQUE KEY i_mqtt_topic_server (topic(191), server_host) +); -- cgit v1.2.3