Browse Source

! And the DB structure of the background tasks subsystem.

Signed-off-by: Peter Spicer <sleeping@myperch.org>
Peter Spicer 11 years ago
parent
commit
4fda2835e4

+ 13 - 0
other/install_2-1_mysql.sql

@@ -66,6 +66,19 @@ CREATE TABLE {$db_prefix}attachments (
   KEY attachment_type (attachment_type)
 ) ENGINE=MyISAM;
 
+#
+# Table structure for table `background_tasks`
+#
+
+CREATE TABLE {$db_prefix}background_tasks (
+  id_task int(10) unsigned NOT NULL auto_increment,
+  task_file varchar(255) NOT NULL default '',
+  task_class varchar(255) NOT NULL default '',
+  task_data mediumtext NOT NULL,
+  claimed_time int(10) unsigned NOT NULL default '0',
+  PRIMARY KEY (id_task)
+) ENGINE=MyISAM;
+
 #
 # Table structure for table `ban_groups`
 #

+ 19 - 0
other/install_2-1_postgresql.sql

@@ -223,6 +223,25 @@ CREATE UNIQUE INDEX {$db_prefix}attachments_id_member ON {$db_prefix}attachments
 CREATE INDEX {$db_prefix}attachments_id_msg ON {$db_prefix}attachments (id_msg);
 CREATE INDEX {$db_prefix}attachments_attachment_type ON {$db_prefix}attachments (attachment_type);
 
+#
+# Sequence for table `background_tasks`
+#
+
+CREATE SEQUENCE {$db_prefix}background_tasks_seq;
+
+#
+# Table structure for table `background_tasks`
+#
+
+CREATE TABLE {$db_prefix}background_tasks (
+  id_task int default nextval('{$db_prefix}background_tasks_seq'),
+  task_file varchar(255) NOT NULL default '',
+  task_class varchar(255) NOT NULL default '',
+  task_data text NOT NULL,
+  claimed_time int unsigned NOT NULL default '0',
+  PRIMARY KEY (id_task)
+);
+
 #
 # Sequence for table `ban_groups`
 #

+ 13 - 0
other/install_2-1_sqlite.sql

@@ -74,6 +74,19 @@ CREATE UNIQUE INDEX {$db_prefix}attachments_id_member ON {$db_prefix}attachments
 CREATE INDEX {$db_prefix}attachments_id_msg ON {$db_prefix}attachments (id_msg);
 CREATE INDEX {$db_prefix}attachments_attachment_type ON {$db_prefix}attachments (attachment_type);
 
+#
+# Table structure for table `background_tasks`
+#
+
+CREATE TABLE {$db_prefix}background_tasks (
+  id_task integer primary key,
+  task_file varchar(255) NOT NULL default '',
+  task_class varchar(255) NOT NULL default '',
+  task_data text NOT NULL,
+  claimed_time int NOT NULL default '0',
+  PRIMARY KEY (id_task)
+);
+
 #
 # Table structure for table `ban_groups`
 #

+ 13 - 0
other/install_2-1_sqlite3.sql

@@ -74,6 +74,19 @@ CREATE UNIQUE INDEX {$db_prefix}attachments_id_member ON {$db_prefix}attachments
 CREATE INDEX {$db_prefix}attachments_id_msg ON {$db_prefix}attachments (id_msg);
 CREATE INDEX {$db_prefix}attachments_attachment_type ON {$db_prefix}attachments (attachment_type);
 
+#
+# Table structure for table `background_tasks`
+#
+
+CREATE TABLE {$db_prefix}background_tasks (
+  id_task integer primary key,
+  task_file varchar(255) NOT NULL default '',
+  task_class varchar(255) NOT NULL default '',
+  task_data text NOT NULL,
+  claimed_time int NOT NULL default '0',
+  PRIMARY KEY (id_task)
+);
+
 #
 # Table structure for table `ban_groups`
 #