[MDEV-31106] Introduce innodb_fts_threads for processing the fts message Created: 2023-04-21  Updated: 2023-11-28

Status: Open
Project: MariaDB Server
Component/s: Full-text Search, Storage Engine - InnoDB
Affects Version/s: 10.6, 10.8, 10.9, 10.10, 10.11, 11.0
Fix Version/s: 10.6, 10.11, 11.0

Type: Bug Priority: Major
Reporter: Thirunarayanan Balathandayuthapani Assignee: Thirunarayanan Balathandayuthapani
Resolution: Unresolved Votes: 0
Labels: None

Attachments: File fts_thd.patch     File tpool_fts.patch    

 Description   

Create innodb_fts_threads variable to process the background fts message and optimization
of the table during idle time. By doing this, InnoDB can do sync/optimize
the multiple table at the same time. This could lead to reduce time for removing
the table from fts_optimize queue.

Points to consider:

1) DELETE_MESSAGE should be processed after inserting the table into the slot
and wait for concurrent sync or optimization to complete
2) Try to use existing thread pool mechanism for it
3) Try to reduce the usage of THD* object for sync message (in case more fts threads)
4) While reducing the number of threads(1), InnoDB shouldn't hang while drop
the table.

Here by attaching prototype patch using thread pool and normal THD approach.
I did use normal THD approach and later @marko suggested me to use existing
thread pool. So attaching both patches for future reference.


Generated at Thu Feb 08 10:21:19 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.