diff --git a/bin/taskrunner.php b/bin/taskrunner.php new file mode 100644 index 0000000..0a3e861 --- /dev/null +++ b/bin/taskrunner.php @@ -0,0 +1,55 @@ +. + * + * You can contact The Jam Warehouse Software (Pty) Limited, Unit 1, Tramber Place, + * Blake Street, Observatory, 7925 South Africa. or email info@knowledgetree.com. + * + * The interactive user interfaces in modified source and object code versions + * of this program must display Appropriate Legal Notices, as required under + * Section 5 of the GNU General Public License version 3. + * + * In accordance with Section 7(b) of the GNU General Public License version 3, + * these Appropriate Legal Notices must retain the display of the "Powered by + * KnowledgeTree" logo and retain the original copyright notice. If the display of the + * logo is not reasonably feasible for technical reasons, the Appropriate Legal Notices + * must display the words "Powered by KnowledgeTree" and retain the original + * copyright notice. + * Contributor( s): ______________________________________ + * + */ + +// Setup php binary path +$phpPath = realpath('../../php/bin/php'); +if (!is_file($phpPath)) +{ + die('Cannot find php.exe'); +} + +// Main Scheduler Service Loop +while (1) { + + // Run the scheduler script + system("$phpPath scheduler.php"); + + sleep(10); // Run every 10 seconds + +} + +?> diff --git a/plugins/housekeeper/HouseKeeperPlugin.php b/plugins/housekeeper/HouseKeeperPlugin.php index da499a9..5e461f5 100644 --- a/plugins/housekeeper/HouseKeeperPlugin.php +++ b/plugins/housekeeper/HouseKeeperPlugin.php @@ -6,32 +6,32 @@ * KnowledgeTree Open Source Edition * Document Management Made Simple * Copyright (C) 2004 - 2007 The Jam Warehouse Software (Pty) Limited - * + * * This program is free software; you can redistribute it and/or modify it under * the terms of the GNU General Public License version 3 as published by the * Free Software Foundation. - * + * * This program is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more * details. - * + * * You should have received a copy of the GNU General Public License * along with this program. If not, see . - * + * * You can contact The Jam Warehouse Software (Pty) Limited, Unit 1, Tramber Place, * Blake Street, Observatory, 7925 South Africa. or email info@knowledgetree.com. - * + * * The interactive user interfaces in modified source and object code versions * of this program must display Appropriate Legal Notices, as required under * Section 5 of the GNU General Public License version 3. - * + * * In accordance with Section 7(b) of the GNU General Public License version 3, * these Appropriate Legal Notices must retain the display of the "Powered by - * KnowledgeTree" logo and retain the original copyright notice. If the display of the + * KnowledgeTree" logo and retain the original copyright notice. If the display of the * logo is not reasonably feasible for technical reasons, the Appropriate Legal Notices - * must display the words "Powered by KnowledgeTree" and retain the original - * copyright notice. + * must display the words "Powered by KnowledgeTree" and retain the original + * copyright notice. * Contributor( s): ______________________________________ */ @@ -75,26 +75,34 @@ class HouseKeeperPlugin extends KTPlugin 'folder'=>$logDir, 'pattern'=>'.+\.txt$', 'canClean'=>true - ), + )); + + if (!OS_WINDOWS) + { + $this->folders[] = array( 'name'=>_kt('System Temporary Folder'), 'folder'=>$systemDir, 'pattern'=>'(sess_.+)?(.+\.log$)?', 'canClean'=>true - ), + ); + } + + $this->folders[] = array( 'name'=>_kt('KnowledgeTree Documents'), 'folder'=>$docsDir, 'pattern'=>'', 'canClean'=>false - ), + ); + $this->folders[] = array( 'name'=>_kt('KnowledgeTree Lucene Indexes'), 'folder'=>$luceneDir, 'pattern'=>'', 'canClean'=>false - ), - ); + ); + } function getDirectories() diff --git a/plugins/search2/ExternalDashlet.php b/plugins/search2/ExternalDashlet.php index ce0155e..b22eacc 100644 --- a/plugins/search2/ExternalDashlet.php +++ b/plugins/search2/ExternalDashlet.php @@ -6,32 +6,32 @@ * KnowledgeTree Open Source Edition * Document Management Made Simple * Copyright (C) 2004 - 2007 The Jam Warehouse Software (Pty) Limited - * + * * This program is free software; you can redistribute it and/or modify it under * the terms of the GNU General Public License version 3 as published by the * Free Software Foundation. - * + * * This program is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more * details. - * + * * You should have received a copy of the GNU General Public License * along with this program. If not, see . - * + * * You can contact The Jam Warehouse Software (Pty) Limited, Unit 1, Tramber Place, * Blake Street, Observatory, 7925 South Africa. or email info@knowledgetree.com. - * + * * The interactive user interfaces in modified source and object code versions * of this program must display Appropriate Legal Notices, as required under * Section 5 of the GNU General Public License version 3. - * + * * In accordance with Section 7(b) of the GNU General Public License version 3, * these Appropriate Legal Notices must retain the display of the "Powered by - * KnowledgeTree" logo and retain the original copyright notice. If the display of the + * KnowledgeTree" logo and retain the original copyright notice. If the display of the * logo is not reasonably feasible for technical reasons, the Appropriate Legal Notices - * must display the words "Powered by KnowledgeTree" and retain the original - * copyright notice. + * must display the words "Powered by KnowledgeTree" and retain the original + * copyright notice. * Contributor( s): ______________________________________ * */ @@ -75,6 +75,7 @@ class ExternalResourceStatusDashlet extends KTBaseDashlet { $this->checkOpenOffice(); $this->checkLucene(); + $this->checkDF(); $_SESSION['ExternalResourceStatus']['time'] = time(); $_SESSION['ExternalResourceStatus']['resources'] = $this->resources; } @@ -97,11 +98,23 @@ class ExternalResourceStatusDashlet extends KTBaseDashlet $diagnose = $indexer->diagnose(); if (!is_null($diagnose)) { - $this->addIssue(_kt('Lucene Indexer'), $diagnose); + $this->addIssue(_kt('Document Indexer'), $diagnose); + } + } + + function checkDF() + { + $df = KTUtil::findCommand('externalBinary','df'); + + if (false === $df) + { + $this->addIssue(_kt('Storage Utilization'), _kt('Could not locate the df binary.')); } } - function is_active($oUser) + + + function is_active($oUser) { if (!Permission::userIsSystemAdministrator()) { diff --git a/search2/indexing/indexers/JavaXMLRPCLuceneIndexer.inc.php b/search2/indexing/indexers/JavaXMLRPCLuceneIndexer.inc.php index 8fb9878..5fd3113 100644 --- a/search2/indexing/indexers/JavaXMLRPCLuceneIndexer.inc.php +++ b/search2/indexing/indexers/JavaXMLRPCLuceneIndexer.inc.php @@ -195,7 +195,7 @@ class JavaXMLRPCLuceneIndexer extends Indexer */ public function getDisplayName() { - return _kt('Lucene Indexing Server'); + return _kt('Document Indexer Service'); } diff --git a/search2/indexing/indexers/PHPLuceneIndexer.inc.php b/search2/indexing/indexers/PHPLuceneIndexer.inc.php index 1e198fe..cabc819 100644 --- a/search2/indexing/indexers/PHPLuceneIndexer.inc.php +++ b/search2/indexing/indexers/PHPLuceneIndexer.inc.php @@ -239,7 +239,7 @@ class PHPLuceneIndexer extends Indexer */ public function getDisplayName() { - return _kt('Lucene PHP Indexer'); + return _kt('Document Indexer Library'); } } ?> \ No newline at end of file diff --git a/templates/ktcore/search2/adv_query_builder.smarty b/templates/ktcore/search2/adv_query_builder.smarty index 5fca80a..7ae92ec 100644 --- a/templates/ktcore/search2/adv_query_builder.smarty +++ b/templates/ktcore/search2/adv_query_builder.smarty @@ -766,7 +766,12 @@ function butSearchClick()
{i18n}Advanced Search{/i18n} +{capture assign=options} +Search Criteria Editor +{/capture} +{i18n arg_options=$options}The #options# may also be used to create more complex search criteria expressions.{/i18n} +

{capture assign=options}
@@ -139,11 +148,11 @@ function txtQueryChange(el)
{i18n}Grammar{/i18n} -{i18n}Expressions may be built up using the following grammar:{/i18n}
+{i18n}Criteria may be built up using the following grammar:{/i18n}
expr ::= expr {literal}{{/literal} AND | OR {literal}}{/literal} expr
expr ::= NOT expr
expr ::= (expr)
-expr ::= expr {literal}{ < | <= | = | > | >= | CONTAINS |STARTS WITH | ENDS WITH }{/literal} value
+expr ::= field {literal}{ < | <= | = | > | >= | CONTAINS |STARTS WITH | ENDS WITH }{/literal} value
expr ::= field BETWEEN value AND value
expr ::= field DOES [ NOT ] CONTAIN value
expr ::= field IS [ NOT ] LIKE value
@@ -167,12 +176,11 @@ sq.value += word + ' ';
{i18n}Fields{/i18n} -{i18n}The following fields may be used in expressions:{/i18n} +{i18n}The following fields may be used in search criteria:{/i18n} {assign var=i value=0} {foreach item=alias from=$aliases} {if (substr($alias,0,2) != '["')} {if $i>0}, {/if} - {if (($i % 8) == 0)}
{/if} {$alias} {assign var=i value=$i+1} diff --git a/templates/ktcore/search2/lucene_migration.smarty b/templates/ktcore/search2/lucene_migration.smarty index 258fdd0..2e1000b 100644 --- a/templates/ktcore/search2/lucene_migration.smarty +++ b/templates/ktcore/search2/lucene_migration.smarty @@ -1,5 +1,5 @@

-{i18n}Migration to using the new search requires text to be moved from the database full text indexes into the Lucene indexes. This may take some time depending +{i18n}Migration to using the new search requires text to be moved from the database full text indexes into the Document Indexer Service. This may take some time depending on the size of the repository. For this reason, the process is a background task.{/i18n}

diff --git a/templates/ktcore/search2/lucene_statistics.smarty b/templates/ktcore/search2/lucene_statistics.smarty index 6be2f38..1fc1c54 100644 --- a/templates/ktcore/search2/lucene_statistics.smarty +++ b/templates/ktcore/search2/lucene_statistics.smarty @@ -1,5 +1,5 @@

-{i18n}This dashlet provides some basic statistics on the Lucene index.{/i18n} +{i18n}This dashlet provides some basic statistics from the KnowledgeTree Document Indexer.{/i18n}

@@ -18,7 +18,7 @@
*{i18n}Not all documents contain text. This will explain why the indexing coverage percentage my vary.{/i18n}
*{i18n}The queue coverage indicates how many documents are in the queue in relation to the repository size.{/i18n} {if $stats.noOptimisation} -
*{i18n}To get the best performance out of Lucene, the indexes must be optimised periodically. This is managed by a background task.{/i18n} +
*{i18n}To get the best performance out of Document Indexer, the indexes must be optimised periodically. This is managed by a background task.{/i18n} {/if}