Real-time index is a main type of Manticore indexes.
It allows adding, updating and deleting documents with immediate
availability of the changes. Real-time index settings can be defined in
a configuration file or online via
CREATE/UPDATE/DELETE/ALTER
commands.
Real-time index internally consists of one or multiple plain indexes called chunks. There can be:
RAM chunk size is controlled by rt_mem_limit. Once the limit is exceeded the RAM chunk is flushed to disk in a form of a disk chunk. When there are too many disk chunks they can be merged into one for better performance using command OPTIMIZE.
CREATE TABLE products(title text, price float) morphology='stem_en';Query OK, 0 rows affected (0.00 sec)POST /cli -d "CREATE TABLE products(title text, price float) morphology='stem_en'"
{
"total":0,
"error":"",
"warning":""
}$index = new \Manticoresearch\Index($client);
$index->setName('products');
$index->create([
'title'=>['type'=>'text'],
'price'=>['type'=>'float'],
]);utilsApi.sql('mode=raw&query=CREATE TABLE forum(title text, price float)')res = await utilsApi.sql('mode=raw&query=CREATE TABLE forum(title text, price float)');utilsApi.sql("mode=raw&query=CREATE TABLE forum(title text, price float)");index products {
type = rt
path = idx
rt_field = title
rt_attr_uint = price
stored_fields = title
}ALTER| Extension | Description |
|---|---|
.lock |
lock file |
.ram |
RAM chunk |
.meta |
RT index headers |
.*.sp* |
disk chunks (see plain index format) |