Alkaline consumes 100% of CPU. What can I do to limit the aggressive resource consumption during indexing?

While indexing, Alkaline creates so-called indexing threads. Each thread is in charge of indexing a single document at a time. Each document comes from an indexing queue. The queue has a virtually unlimited size, but the number of threads is upper-bound by the -mi=N command-line setting. The default number of maximum indexing threads is 10. This number is high by design and Alkaline will try to consume all available resources when indexing.

While searching, Alkaline creates a pool of search threads. Each thread is in charge of executing a single search operation at a time. The number of search threads is upper-bound by the -mt=N command-line setting. The default maximum number of search threads is 25. Naturally, a lot of priority is given to search threads.

To reduce CPU usage while indexing, especially when indexing in background, use a single indexing thread and an interval of a second between each document being indexed. To achieve this, use the following command line options: -mi=1 -sf=1 .

If search performance suffers because of indexing, disable background indexing with --noreindex .