initial code to set the number of parallel requests when indexing

This commit is contained in:
Uwe Steinmann 2024-10-02 14:59:40 +02:00
parent ccab32bb42
commit 5275a50d6d
2 changed files with 3 additions and 1 deletions

View File

@ -81,6 +81,7 @@ if($view) {
$view->setParam('folder', $folder);
$view->setParam('converters', $settings->_converters['fulltext']);
$view->setParam('timeout', $settings->_cmdTimeout);
$view->setParam('maxrequests', 1); // not yet used
$view->setParam('accessobject', $accessop);
$view($_GET);
exit;

View File

@ -110,12 +110,13 @@ class SeedDMS_View_Indexer extends SeedDMS_Theme_Style {
function js() { /* {{{ */
$dms = $this->params['dms'];
$user = $this->params['user'];
$maxrequests = 5;
header('Content-Type: application/javascript; charset=UTF-8');
?>
var queue_count = 0; // Number of functions being called
var funcArray = []; // Array of functions waiting
var MAX_REQUESTS = 5; // Max requests
var MAX_REQUESTS = <?= $maxrequests ?>; // Max requests
var CALL_WAIT = 20; // 100ms
var docstoindex = 0; // total number of docs to index