Real-time table

Real-time table is the main type of tables in Manticore. It allows adding, updating and deleting documents with immediate availability of the changes. Real-time table settings can be defined in a configuration file or online via CREATE/UPDATE/DELETE/ALTER commands.

Real-time table internally consists of one or multiple plain tables called chunks. There can be:

  • multiple disk chunks. They are stored on disk with the same structure as any plain table
  • single ram chunk. Stored in memory and used as an accumulator of changes

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.

‹›
  • SQL
  • JSON
  • PHP
  • Python
  • Javascript
  • Java
  • CONFIG
📋
CREATE TABLE products(title text, price float) morphology='stem_en';
‹›
Response
Query OK, 0 rows affected (0.00 sec)
‹›
Creating a real-time table via JSON over HTTP:

👍 What you can do with a real-time table:

⛔ What you cannot do with a real-time table:

  • Index data with help of indexer
  • Link it with sources for easy indexing from external storages
  • Update it's killlist_target, it's just not needed as the real-time table takes controls of it automatically

Real-time table files structure

Extension Description
.lock lock file
.ram RAM chunk
.meta RT table headers
.*.sp* disk chunks (see plain table format)