From fa27de6ba42f99adaeba422364219f8718e0eb8a Mon Sep 17 00:00:00 2001 From: conradverm Date: Tue, 13 Nov 2007 08:27:11 +0000 Subject: [PATCH] KTS-2687 "update the db install/upgrade scripts so that the php scripts that must be scheduled are referenced correctly" Updated. --- sql/mysql/install/data.sql | 5 ++++- sql/mysql/upgrade/3.5.1/indexing_tasks_registration.sql | 12 ++++++++++++ 2 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 sql/mysql/upgrade/3.5.1/indexing_tasks_registration.sql diff --git a/sql/mysql/install/data.sql b/sql/mysql/install/data.sql index 1dfc12a..6ba7f51 100644 --- a/sql/mysql/install/data.sql +++ b/sql/mysql/install/data.sql @@ -794,7 +794,10 @@ UNLOCK TABLES; LOCK TABLES `scheduler_tasks` WRITE; /*!40000 ALTER TABLE `scheduler_tasks` DISABLE KEYS */; -INSERT INTO `scheduler_tasks` VALUES (1,'Indexing','../bin/indexingTask.sh','',0,'1min','2007-10-01',NULL,0),(2,'Index Migration','../bin/indexMigrationTask.sh','',0,'5mins','2007-10-01',NULL,0),(3,'Index Optimisation','../bin/optimizeIndexes.sh','',0,'weekly','2007-10-01',NULL,0); +INSERT INTO `scheduler_tasks` VALUES +(1,'Indexing','search2/indexing/bin/cronIndexer.php','',0,'1min','2007-10-01',NULL,0), +(2,'Index Migration','search2/indexing/bin/cronMigration.php','',0,'5mins','2007-10-01',NULL,0), +(3,'Index Optimisation','search2/indexing/bin/optimise.php','',0,'weekly','2007-10-01',NULL,0); /*!40000 ALTER TABLE `scheduler_tasks` ENABLE KEYS */; UNLOCK TABLES; diff --git a/sql/mysql/upgrade/3.5.1/indexing_tasks_registration.sql b/sql/mysql/upgrade/3.5.1/indexing_tasks_registration.sql new file mode 100644 index 0000000..1e40ef0 --- /dev/null +++ b/sql/mysql/upgrade/3.5.1/indexing_tasks_registration.sql @@ -0,0 +1,12 @@ +DELETE FROM scheduler_tasks where task in ('Indexing','Index Migration','Index Optimisation'); + +select @id:=ifnull(max(id),0)+1 from scheduler_tasks; +INSERT INTO `scheduler_tasks` (id,task,script_url,script_params,is_complete,frequency,run_time,previous_run_time,run_duration) VALUES (@id,'Indexing','search2/indexing/bin/cronIndexer.php','',0,'1min','2007-10-01',NULL,0); + +select @id:=max(id)+1 from scheduler_tasks; +INSERT INTO `scheduler_tasks` (id,task,script_url,script_params,is_complete,frequency,run_time,previous_run_time,run_duration) VALUES (@id,'Index Migration','search2/indexing/bin/cronMigration.php','',0,'5mins','2007-10-01',NULL,0); + +select @id:=max(id)+1 from scheduler_tasks; +INSERT INTO `scheduler_tasks` (id,task,script_url,script_params,is_complete,frequency,run_time,previous_run_time,run_duration) VALUES (@id,'Index Optimisation','search2/indexing/bin/optimise.php','',0,'weekly','2007-10-01',NULL,0); + +UPDATE zseq_scheduler_tasks set id=@id; \ No newline at end of file -- libgit2 0.21.4