Reindexer is an embeddable, in-memory, document-oriented database with a high-level Query builder interface. Reindexer's goal is to provide fast search with complex queries. The Reindexer is compact and fast. It has not heavy dependencies. Complete reindexer docker image with all libraries and web interface size is just 15MB. Reindexer is fast.
- Reindexer REST API
- Methods
- List available databases
- Create new database
- Drop database
- List available namespaces
- Create namespace
- Get namespace description
- Drop namespace
- Get documents from namespace
- Update documents in namespace
- Insert documents to namespace
- Delete documents from namespace
- List available indexes
- Update index in namespace
- Add new index to namespace
- Drop index from namespace
- SQL Query documents from namespace
- DSL Query documents from namespace
- Delete documents from namespace by query
- Get system information
- Get memory stats information
- Get performance stats information
- Get SELECT queries performance stats information
- Update system config
- Definitions
- AggregationResDef
- AggregationsDef
- CacheMemStats
- CommonPerfStats
- Database
- DatabaseMemStats
- DatabasePerfStats
- Databases
- ExplainDef
- FilterDef
- FulltextConfig
- Index
- IndexCacheMemStats
- IndexMemStat
- Indexes
- Items
- JoinCacheMemStats
- JoinedDef
- NamespacesConfig
- Namespace
- NamespaceMemStats
- NamespacePerfStats
- Namespaces
- OnDef
- ProfilingConfig
- QueriesPerfStats
- Query
- QueryCacheMemStats
- QueryItems
- QueryPerfStats
- ReplicationConfig
- SelectPerfStats
- SortDef
- StatusResponse
- SysInfo
- SystemConfigItem
- UpdatePerfStats
- UpdateResponse
- Methods
Version : 2.0.0
License : Apache 2.0
License URL : http://www.apache.org/licenses/LICENSE-2.0.html
Terms of service : null
BasePath : /api/v1
Schemes : HTTP
- databases : Databases managment
- indexes : Indexes management
- items : Documents managment
- namespaces : Namespaces managment
- queries : Queries to reindexer (dsl/sql)
- system : System methods
application/json
GET /db
This operation will output list of all available databases
Type | Name | Description | Schema |
---|---|---|---|
Query | sort_order optional |
Sort Order | enum (asc, desc) |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | Databases |
400 | Invalid arguments supplied | StatusResponse |
- databases
POST /db
This operation will create new database. If database is already exists, then error will be returned.
Type | Name | Description | Schema |
---|---|---|---|
Body | body required |
Database definintion | Database |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | StatusResponse |
400 | Invalid parameters | StatusResponse |
- databases
DELETE /db/{database}
This operation will remove complete database from memory and disk. All data, including namespaces, their documents and indexes will be erased. Can not be undone. USE WITH CAUTION.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | StatusResponse |
400 | Invalid arguments supplied | StatusResponse |
- databases
GET /db/{database}/namespaces
This operation will list all availavle namespaces in specified database. If database is not exists, then error will be returned.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Query | sort_order optional |
Sort Order | enum (asc, desc) |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | Namespaces |
400 | Invalid arguments supplied | StatusResponse |
- namespaces
POST /db/{database}/namespaces
This operation will create new namespace in specified database. If namespace is already exists, then operation do not nothing.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Body | body required |
Namespace definintion | Namespace |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | StatusResponse |
400 | Invalid parameters | StatusResponse |
- namespaces
GET /db/{database}/namespaces/{name}
This operation will return specified namespace description, including options of namespace, and available indexes
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | Namespace |
400 | Invalid arguments supplied | StatusResponse |
- namespaces
DELETE /db/{database}/namespaces/{name}
This operation will delete completely namespace from memory and disk. All documents, indexes and metadata from namespace will be removed. Can not be undone. USE WITH CAUTION.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | StatusResponse |
400 | Invalid arguments supplied | StatusResponse |
- namespaces
GET /db/{database}/namespaces/{name}/items
This operation will select documents from namespace with specified filters, and sort them by specified sort order. Paging with limit and offset are supported.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
Query | fields optional |
Comma-separated list of returned fields | string |
Query | filter optional |
Filter with SQL syntax, e.g: field1 = 'v1' AND field2 > 'v2' | string |
Query | limit optional |
Maximum count of returned items | integer |
Query | offset optional |
Offset of first returned item | integer |
Query | sort_field optional |
Sort Field | string |
Query | sort_order optional |
Sort Order | enum (asc, desc) |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | Items |
400 | Invalid arguments supplied | StatusResponse |
- items
PUT /db/{database}/namespaces/{name}/items
This operation will UPDATE documents in namespace, by their primary keys. Each document should be in request body as separate JSON object, e.g.
{"id":100, "name": "Pet"}
{"id":101, "name": "Dog"}
...
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
Body | body required |
object |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | UpdateResponse |
400 | Invalid status value | StatusResponse |
- items
POST /db/{database}/namespaces/{name}/items
This operation will INSERT documents to namespace, by their primary keys. Each document should be in request body as separate JSON object, e.g.
{"id":100, "name": "Pet"}
{"id":101, "name": "Dog"}
...
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
Body | body required |
object |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | UpdateResponse |
400 | Invalid status value | StatusResponse |
- items
DELETE /db/{database}/namespaces/{name}/items
This operation will DELETE documents from namespace, by their primary keys. Each document should be in request body as separate JSON object, e.g.
{"id":100}
{"id":101}
...
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
Body | body required |
object |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | UpdateResponse |
400 | Invalid status value | StatusResponse |
- items
GET /db/{database}/namespaces/{name}/indexes
This operation will return list of available indexes, from specified database and namespace.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | Indexes |
400 | Invalid arguments supplied | StatusResponse |
- indexes
PUT /db/{database}/namespaces/{name}/indexes
This operation will update index parameters. E.g. type of field or type of index. Operation is synchronious, so it can take long time, if namespace contains bunch of documents
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
Body | body required |
Index definition | Index |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | StatusResponse |
400 | Invalid status value | StatusResponse |
- indexes
POST /db/{database}/namespaces/{name}/indexes
This operation will create new index. If index is already exists with the different parameters, then error will be returned. Operation is synchronious, so it can take long time, if namespace contains bunch of documents.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | name required |
Namespace name | string |
Body | body required |
Index definition | Index |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | StatusResponse |
400 | Invalid status value | StatusResponse |
- indexes
DELETE /db/{database}/namespaces/{name}/indexes/{indexname}
This operation will remove index from namespace. No data will be erased. Operation is synchronious, so it can take long time, if namespace contains bunch of documents.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Path | indexname required |
Index name | string |
Path | name required |
Namespace name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | StatusResponse |
400 | Invalid status value | StatusResponse |
- indexes
GET /db/{database}/query
This opertaion queries documents from namespace by SQL query. Query can be preced by EXPLAIN
statement, then query execution plan will be returned with query results.
Two level paging is supported. At first, applied normal SQL LIMIT
and OFFSET
,
then limit
and offset
from http request.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Query | limit optional |
Maximum count of returned items | integer |
Query | offset optional |
Offset of first returned item | integer |
Query | q required |
SQL query | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | QueryItems |
400 | Invalid status value | StatusResponse |
- queries
POST /db/{database}/query
This opertaion queries documents from namespace by DSL query.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Body | body required |
DSL query | Query |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | QueryItems |
400 | Invalid status value | StatusResponse |
- queries
DELETE /db/{database}/query
This opertaion removes documents from namespace by DSL query.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Body | body required |
DSL query | Query |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | No Content |
400 | Invalid status value | StatusResponse |
- queries
GET /db/{database}/suggest
This operation pareses SQL query, and suggests autocompletion variants
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Query | pos required |
Cursor position for suggest | integer |
Query | q required |
SQL query | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | SuggestItems |
400 | Invalid status value | StatusResponse |
- queries
POST /db/{database}/sqlquery
This opertaion queries documents from namespace by SQL query. Query can be preced by EXPLAIN
statement, then query execution plan will be returned with query results.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Body | q required |
SQL query | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | QueryItems |
400 | Invalid status value | StatusResponse |
- queries
GET /check
This operation will return system informatiom about server version, uptime, and resources consumtion
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | SysInfo |
400 | Invalid arguments supplied | StatusResponse |
- system
GET /db/{database}/namespaces/%23memstats/items
This operation will return detailed informatiom about database memory consumption
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | DatabaseMemStats |
400 | Invalid arguments supplied | StatusResponse |
- system
GET /db/{database}/namespaces/%23perfstats/items
This operation will return detailed informatiom about database performance timings. By default performance stats is turned off.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | DatabasePerfStats |
400 | Invalid arguments supplied | StatusResponse |
- system
GET /db/{database}/namespaces/%23queriesperfstats/items
This operation will return detailed informatiom about database memory consumption. By default qureis performance stat is turned off.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | QueriesPerfStats |
400 | Invalid arguments supplied | StatusResponse |
- system
PUT /db/{database}/namespaces/%23config/items
This operation will update system configuration:
- profiling configuration. It is used to enable recording of queries and overal performance;
- log queries configurating.
Type | Name | Description | Schema |
---|---|---|---|
Path | database required |
Database name | string |
Body | body required |
SystemConfigItem |
HTTP Code | Description | Schema |
---|---|---|
200 | successful operation | UpdateResponse |
400 | Invalid status value | StatusResponse |
- system
Name | Description | Schema |
---|---|---|
facets optional |
Facets, calculated by aggregator | < facets > array |
field optional |
Field or index name for aggregation function | string |
type optional |
Aggregation function | enum (SUM, AVG, MIN, MAX, FACET) |
value optional |
Value, calculated by aggregator | number |
facets
Name | Description | Schema |
---|---|---|
count optional |
Count of elemens this field value | integer |
value optional |
Facet field value | string |
Name | Description | Schema |
---|---|---|
field optional |
Field or index name for aggregation function | string |
type optional |
Aggregation function | enum (SUM, AVG, MIN, MAX, FACET) |
Name | Description | Schema |
---|---|---|
empty_count optional |
Count of empty elements slots in this cache | integer |
hit_count_limit optional |
Number of hits of queries, to store results in cache | integer |
items_count optional |
Count of used elements stored in this cache | integer |
total_size optional |
Total memory consumption by this cache | integer |
Name | Description | Schema |
---|---|---|
last_sec_avg_lock_time_us optional |
Average waiting time for acquiring lock to this object at last second | integer |
last_sec_qps optional |
Count of queries to this object, requested at last second | integer |
latency_stddev optional |
Standard deviation of latency values | number |
max_latency_us optional |
Maximum latency value | integer |
min_latency_us optional |
Minimal latency value | integer |
total_avg_latency_us optional |
Average latency (execution time) for queries to this object | integer |
total_avg_lock_latency_us optional |
Average waiting time for acquiring lock to this object | integer |
total_queries_count optional |
Total count of queries to this object | integer |
total_sec_avg_latency_us optional |
Average latency (execution time) for queries to this object at last second | integer |
Name | Description | Schema |
---|---|---|
name optional |
Name of database Pattern : "^[A-Za-z0-9_\\-]*$" |
string |
Name | Description | Schema |
---|---|---|
items optional |
Documents, matched specified filters | < NamespaceMemStats > array |
total_items optional |
Total count of documents, matched specified filters | integer |
Name | Description | Schema |
---|---|---|
items optional |
Documents, matched specified filters | < NamespacePerfStats > array |
total_items optional |
Total count of documents, matched specified filters | integer |
Name | Description | Schema |
---|---|---|
items optional |
< string > array | |
total_items optional |
Total count of databases | integer |
Query execution explainings
Name | Description | Schema |
---|---|---|
indexes_us optional |
Indexes keys selection time | integer |
loop_us optional |
Intersection loop time | integer |
postprocess_us optional |
Query post process time | integer |
prepare_us optional |
Query prepare and optimize time | integer |
selectors optional |
Filter selectos, used to proccess query conditions | < selectors > array |
sort_index optional |
Index, which used for sort results | string |
total_us optional |
Total query execution time | integer |
selectors
Name | Description | Schema |
---|---|---|
comparators optional |
Count of comparators used, for this selector | integer |
cost optional |
Cost expectation of this selector | integer |
field optional |
Field or index name | string |
items optional |
Count of scanned documents by this selector | integer |
keys optional |
Number of uniq keys, processed by this selector (may be incorrect, in case of internal query optimization/caching | integer |
matched optional |
Count of processed documents, matched this selector | integer |
method optional |
Method, used to process condition | enum (scan, index, inner_join, left_join) |
Name | Description | Schema |
---|---|---|
cond required |
Condition operator | enum (EQ, GT, GE, LE, LT, RANGE, SET, EMPTY) |
field required |
Field json path or index name for filter | string |
op optional |
Logic operator | enum (AND, OR, NOT) |
value optional |
Value of filter. Single integer or string for EQ, GT, GE, LE, LT condition, array of 2 elements for RANGE condition, or variable len array for SET condition | object |
Fulltext Index configuration
Name | Description | Schema |
---|---|---|
bm25_boost optional |
Boost of bm25 ranking Default : 1.0 Minimum value : 0 Maximum value : 10 |
number (float) |
bm25_weight optional |
Weight of bm25 rank in final rank 0: bm25 will not change final rank. 1: bm25 will affect to finl rank in 0 - 100% range Default : 0.5 Minimum value : 0 Maximum value : 1 |
number (float) |
distance_boost optional |
Boost of search query term distance in found document Default : 1.0 Minimum value : 0 Maximum value : 10 |
number (float) |
distance_weght optional |
Weight of search query terms distance in found document in final rank 0: distance will not change final rank. 1: distance will affect to final rank in 0 - 100% range Default : 0.5 Minimum value : 0 Maximum value : 1 |
number (float) |
enable_kb_layout optional |
Enable wrong keyboard layout variants processing. e.g. term 'keynbr' will match word 'лунтик' Default : true |
boolean |
enable_numbers_search optional |
Enable number variants processing. e.g. term '100' will match words one hundred Default : false |
boolean |
enable_translit optional |
Enable russian translit variants processing. e.g. term 'luntik' will match word 'лунтик' Default : true |
boolean |
extra_word_symbols optional |
List of symbols, which will be threated as word part, all other symbols will be thrated as wors separators Default : "-/+" |
string |
log_level optional |
Log level of full text search engine Minimum value : 0 Maximum value : 4 |
integer |
max_rebuild_steps optional |
Maximum steps withou full rebuild of ft - more steps faster commit slower select - optimal about 15. Minimum value : 0 Maximum value : 500 |
integer |
max_step_size optional |
Maximum unique words to step Minimum value : 5 Maximum value : 1000000000 |
integer |
max_typo_len optional |
Maximum word length for building and matching variants with typos. Minimum value : 0 Maximum value : 100 |
integer |
max_typos_in_word optional |
Maximum possible typos in word. 0: typos is disabled, words with typos will not match. N: words with N possible typos will match. It is not recommended to set more than 1 possible typo -It will seriously increase RAM usage, and decrease search speed Minimum value : 0 Maximum value : 2 |
integer |
merge_limit optional |
Maximum documents count which will be processed in merge query results. Increasing this value may refine ranking of queries with high frequency words, but will decrease search speed Minimum value : 0 Maximum value : 65535 |
integer |
min_relevancy optional |
Minimum rank of found documents. 0: all found documents will be returned 1: only documents with relevancy >= 100% will be returned Default : 0.05 Minimum value : 0 Maximum value : 1 |
number (float) |
stemmers optional |
List of stemmers to use | < string > array |
stop_words optional |
List of stop words. Words from this list will be ignored in documents and queries | < string > array |
term_len_boost optional |
Boost of search query term length Default : 1.0 Minimum value : 0 Maximum value : 10 |
number (float) |
term_len_weght optional |
Weight of search query term length in final rank. 0: term length will not change final rank. 1: term length will affect to final rank in 0 - 100% range Default : 0.3 Minimum value : 0 Maximum value : 1 |
number (float) |
Name | Description | Schema |
---|---|---|
collate_mode optional |
String collate mode Default : "none" |
enum (none, ascii, utf8, numeric) |
config optional |
FulltextConfig | |
field_type required |
Field data type | enum (int, int64, double, string, bool, composite) |
index_type required |
Index structure type Default : "hash" |
enum (hash, tree, text, -) |
is_array optional |
Specifies, that index is array. Array indexes can work with array fields, or work with multiple fields Default : false |
boolean |
is_dense optional |
Reduces the index size. For hash and tree it will save ~8 bytes per unique key value. Useful for indexes with high selectivity, but for tree and hash indexes with low selectivity can seriously decrease update performance; Default : false |
boolean |
is_pk optional |
Specifies, that index is primary key. The update opertations will checks, that PK field is unique. The namespace MUST have only 1 PK index | boolean |
is_sparse optional |
Value of index may not present in the document, and threfore, reduce data size but decreases speed operations on index Default : false |
boolean |
json_paths required |
Fields path in json object, e.g 'id' or 'subobject.field'. If index is 'composite' or 'is_array', than multiple json_paths can be specified, and index will get values from all specified fields. | < string > array |
name required |
Name of index, can contains letters, digits and underscores Default : "id" Pattern : "^[A-Za-z0-9_\\-]*$" |
string |
sort_order_letters optional |
Sort order letters Default : "" |
string |
Number of elements in idset cache. Stores merged reverse index results of SELECT field IN(...) by IN(...) keys
Polymorphism : Composition
Name | Description | Schema |
---|---|---|
empty_count optional |
Count of empty elements slots in this cache | integer |
hit_count_limit optional |
Number of hits of queries, to store results in cache | integer |
items_count optional |
Count of used elements stored in this cache | integer |
total_size optional |
Total memory consumption by this cache | integer |
Name | Description | Schema |
---|---|---|
fulltext_size optional |
Total memory consumption of fulltext search structures | integer |
idset_btree_size optional |
Total memory consumption of reverse index b-tree structures. For dense and store indexes always 0 |
integer |
idset_cache optional |
IndexCacheMemStats | |
idset_plain_size optional |
Total memory consumption of reverse index vectors. For store ndexes always 0 |
integer |
name optional |
Name of index. There are special index with name -tuple . It's stores original document's json structure with non indexe fields |
string |
sort_orders_size optional |
Total memory consumption of SORT statement and GT , LT conditions optimized structures. Applicabe only to tree indexes |
integer |
unique_keys_count optional |
Count of unique keys values stored in index | integer |
Name | Description | Schema |
---|---|---|
items optional |
< Index > array | |
total_items optional |
Total count of indexes | integer |
Name | Description | Schema |
---|---|---|
items optional |
Documents, matched specified filters | < object > array |
total_items optional |
Total count of documents, matched specified filters | integer |
Number of elements in join cache. Stores results of selects to right table by ON condition
Polymorphism : Composition
Name | Description | Schema |
---|---|---|
empty_count optional |
Count of empty elements slots in this cache | integer |
hit_count_limit optional |
Number of hits of queries, to store results in cache | integer |
items_count optional |
Count of used elements stored in this cache | integer |
total_size optional |
Total memory consumption by this cache | integer |
Name | Description | Schema |
---|---|---|
filters optional |
Filter for results documents | < FilterDef > array |
limit optional |
Maximum count of returned items | integer |
namespace required |
Namespace name | string |
offset optional |
Offset of first returned item | integer |
op optional |
Logic operator | enum (AND, OR, NOT) |
sort optional |
SortDef | |
true optional |
Join ON statement | < OnDef > array |
type required |
Join type | enum (LEFT, INNER) |
Name | Description | Schema |
---|---|---|
indexes optional |
< Index > array | |
name optional |
Name of namespace Pattern : "^[A-Za-z0-9_\\-]*$" |
string |
storage optional |
storage |
storage
Name | Description | Schema |
---|---|---|
enabled optional |
If true, then documents will be stored to disc storage, else all data will be lost on server shutdown | boolean |
Name | Description | Schema |
---|---|---|
data_size optional |
Raw size of documents, stored in the namespace, except string fields | integer |
indexes optional |
Memory consumption of each namespace index | < IndexMemStat > array |
items_count optional |
Total count of documents in namespace | integer |
join_cache optional |
JoinCacheMemStats | |
name optional |
Name of namespace | string |
query_cache optional |
QueryCacheMemStats | |
storage_ok optional |
Status of disk storage | boolean |
storage_path optional |
Filesystem path to namespace storage | boolean |
total optional |
Summary of total namespace memory consumption | total |
updated_unix_nano optional |
[[deperecated]]. do not use | integer |
total
Name | Description | Schema |
---|---|---|
cache_size optional |
Total memory consumption of namespace's caches. e.g. idset and join caches | integer |
data_size optional |
Total memory size of stored documents, including system structures | integer |
indexes_size optional |
Total memory consumption of namespace's indexes | integer |
Name | Description | Schema |
---|---|---|
indexes optional |
Memory consumption of each namespace index | < indexes > array |
name optional |
Name of namespace | string |
selects optional |
SelectPerfStats | |
updates optional |
UpdatePerfStats |
indexes
Name | Description | Schema |
---|---|---|
name optional |
Name of index | string |
selects optional |
SelectPerfStats | |
updates optional |
UpdatePerfStats |
Name | Description | Schema |
---|---|---|
items optional |
< items > array | |
total_items optional |
Total count of namespaces | integer |
items
Name | Description | Schema |
---|---|---|
name optional |
Name of namespace | string |
storage_enabled optional |
If true, then documents will be stored to disc storage, else all data will be lost on server shutdown | boolean |
Name | Description | Schema |
---|---|---|
log_level optional |
Log level of queries core logger | enum (none, error, warning, info, trace) |
namespace optional |
Name of namespace, or * for setting to all namespaces |
string |
Name | Description | Schema |
---|---|---|
cond required |
Condition operator | enum (EQ, GT, GE, LE, LT, RANGE, SET, EMPTY) |
left_field required |
Field from left namespace (main query namespace) | string |
op optional |
Logic operator | enum (AND, OR, NOT) |
right_field required |
Field from right namespace (joined query namespace) | string |
Name | Description | Schema |
---|---|---|
memstats optional |
Enables tracking memory statistics Default : true |
boolean |
perfstats optional |
Enables tracking overal perofrmance statistics Default : false |
boolean |
queries_threshold_us optional |
Minimum query execution time to be recoreded in #queriesperfstats namespace | integer |
queriesperfstats optional |
Enables record queries perofrmance statistics Default : false |
boolean |
Name | Description | Schema |
---|---|---|
items optional |
Documents, matched specified filters | < QueryPerfStats > array |
total_items optional |
Total count of documents, matched specified filters | integer |
Name | Description | Schema |
---|---|---|
aggregations optional |
Ask query calculate aggregation | < AggregationsDef > array |
distinct optional |
Distinct field/index name. Results will contain's document with distinct field value | string |
explain optional |
Add query execution explain information Default : false |
boolean |
filters optional |
Filter for results documents | < FilterDef > array |
join_queries optional |
Nested queries to be joined on right side of main query | < JoinedDef > array |
limit optional |
Maximum count of returned items | integer |
merge_queries optional |
Merged queries to be merged with main query | < Query > array |
namespace required |
Namespace name | string |
offset optional |
Offset of first returned item | integer |
req_total optional |
Ask query to calculate total documents, match condition Default : "disabled" |
enum (disabled, enabled, cached) |
select_filter optional |
Filter fields of returned document. Can be dot separated, e.g 'subobject.field' | < string > array |
select_functions optional |
Add extra select functions to query | < string > array |
sort optional |
Specifies results sorting order | < SortDef > array |
Number of elements in query cache. Stores results of SELECT COUNT(*) by Where conditions
Polymorphism : Composition
Name | Description | Schema |
---|---|---|
empty_count optional |
Count of empty elements slots in this cache | integer |
hit_count_limit optional |
Number of hits of queries, to store results in cache | integer |
items_count optional |
Count of used elements stored in this cache | integer |
total_size optional |
Total memory consumption by this cache | integer |
Name | Description | Schema |
---|---|---|
aggregations optional |
Aggregation functions results | < AggregationResDef > array |
cache_enabled optional |
Enables to client cache returned items. If false, then returned items has been modified by reindexer, e.g. by select filter, or by functions, and can't be cached | boolean |
explain optional |
ExplainDef | |
items optional |
Documents, matched query | < object > array |
namespaces optional |
Namespaces, used in query | < string > array |
query_total_items optional |
Total count of documents, matched query | integer |
Performance statistics per each query
Polymorphism : Composition
Name | Description | Schema |
---|---|---|
last_sec_avg_lock_time_us optional |
Average waiting time for acquiring lock to this object at last second | integer |
last_sec_qps optional |
Count of queries to this object, requested at last second | integer |
latency_stddev optional |
Standard deviation of latency values | number |
max_latency_us optional |
Maximum latency value | integer |
min_latency_us optional |
Minimal latency value | integer |
query optional |
SQL representation of query | string |
total_avg_latency_us optional |
Average latency (execution time) for queries to this object | integer |
total_avg_lock_latency_us optional |
Average waiting time for acquiring lock to this object | integer |
total_queries_count optional |
Total count of queries to this object | integer |
total_sec_avg_latency_us optional |
Average latency (execution time) for queries to this object at last second | integer |
Name | Description | Schema |
---|---|---|
cluster_id optional |
Cluser ID - must be same for client and for master | integer |
force_sync_on_logic_error optional |
force resync on logic error conditions | boolean |
force_sync_on_wrong_data_hash optional |
force resync on wrong data hash conditions | boolean |
master_dsn optional |
DSN to master. Only cproto schema is supported | string |
namespaces optional |
List of namespaces for replication. If emply, all namespaces. All replicated namespaces will become read only for slave | < string > array |
role optional |
Replication role | enum (none, slave, master) |
Performance statistics for select operations
Polymorphism : Composition
Name | Description | Schema |
---|---|---|
last_sec_avg_lock_time_us optional |
Average waiting time for acquiring lock to this object at last second | integer |
last_sec_qps optional |
Count of queries to this object, requested at last second | integer |
latency_stddev optional |
Standard deviation of latency values | number |
max_latency_us optional |
Maximum latency value | integer |
min_latency_us optional |
Minimal latency value | integer |
total_avg_latency_us optional |
Average latency (execution time) for queries to this object | integer |
total_avg_lock_latency_us optional |
Average waiting time for acquiring lock to this object | integer |
total_queries_count optional |
Total count of queries to this object | integer |
total_sec_avg_latency_us optional |
Average latency (execution time) for queries to this object at last second | integer |
Specifies results sorting order
Name | Description | Schema |
---|---|---|
desc optional |
Descent or ascent sorting direction | boolean |
field required |
Field or index name for sorting | string |
values optional |
Optional: Documents with this values of field will be returned first | < object > array |
Name | Description | Schema |
---|---|---|
description optional |
Text description of error details | string |
response_code optional |
Error code: * 0 - errOK * 1 - errParseSQL * 2 - errQueryExec * 3 - errParams * 4 - errLogic * 5 - errParseJson * 6 - errParseDSL * 7 - errConflict * 8 - errParseBin * 9 - errForbidden * 10 - errWasRelock * 11 - errNotValid * 12 - errNetwork * 13 - errNotFound * 14 - errStateInvalidated * 15 - errBadTransaction * 16 - errOutdatedWAL * 17 - errNoWAL * 18 - errDataHashMismatch |
integer |
success optional |
Status of operation | boolean |
Name | Description | Schema |
---|---|---|
suggests optional |
Suggested query autocompletion variants | < string > array |
Name | Description | Schema |
---|---|---|
current_allocated_bytes optional |
Current inuse allocated memory size in bytes | integer |
heap_size optional |
Current heap size in bytes | integer |
pageheap_free optional |
Heap free size in bytes | integer |
pageheap_unmapped optional |
Unmapped free heap size in bytes | integer |
start_time optional |
Server start time in unix timestamp | integer |
uptime optional |
Server uptime in seconds | integer |
version optional |
Server version | string |
Name | Description | Schema |
---|---|---|
namespaces optional |
< NamespacesConfig > array | |
profiling optional |
ProfilingConfig | |
replication optional |
ReplicationConfig | |
type required |
Default : "profiling" |
enum (profiling, namespaces, replication) |
Performance statistics for update operations
Polymorphism : Composition
Name | Description | Schema |
---|---|---|
last_sec_avg_lock_time_us optional |
Average waiting time for acquiring lock to this object at last second | integer |
last_sec_qps optional |
Count of queries to this object, requested at last second | integer |
latency_stddev optional |
Standard deviation of latency values | number |
max_latency_us optional |
Maximum latency value | integer |
min_latency_us optional |
Minimal latency value | integer |
total_avg_latency_us optional |
Average latency (execution time) for queries to this object | integer |
total_avg_lock_latency_us optional |
Average waiting time for acquiring lock to this object | integer |
total_queries_count optional |
Total count of queries to this object | integer |
total_sec_avg_latency_us optional |
Average latency (execution time) for queries to this object at last second | integer |
Name | Description | Schema |
---|---|---|
updated optional |
Count of updated items | integer |