Skip to content

Commit 0df4408

Browse files
Number of tuples in hash index (#4435)
1 parent f61f57f commit 0df4408

File tree

1 file changed

+72
-53
lines changed

1 file changed

+72
-53
lines changed

doc/reference/limitations.rst

+72-53
Original file line numberDiff line numberDiff line change
@@ -1,107 +1,126 @@
11
.. _limitations_fields_in_index:
22
.. _tarantool_limitations:
33

4-
================================================================================
54
Limitations
6-
================================================================================
5+
===========
76

8-
**Number of parts in an index**
7+
.. _limitations_parts_in_index:
98

10-
For TREE or HASH indexes, the maximum
11-
is 255 (``box.schema.INDEX_PART_MAX``). For :ref:`RTREE <box_index-rtree>` indexes, the
12-
maximum is 1 but the field is an ARRAY of up to 20 dimensions.
13-
For BITSET indexes, the maximum is 1.
9+
Number of parts in an index
10+
---------------------------
11+
12+
For TREE or HASH indexes, the maximum
13+
is 255 (``box.schema.INDEX_PART_MAX``). For :ref:`RTREE <box_index-rtree>` indexes, the
14+
maximum is 1 but the field is an ARRAY of up to 20 dimensions.
15+
For BITSET indexes, the maximum is 1.
16+
17+
.. _limitations_tuples_in_hash_index:
18+
19+
Number of tuples in a hash index
20+
--------------------------------
21+
22+
4,294,967,288 (2\ :sup:`32`-8).
1423

1524
.. _limitations_indexes_in_space:
1625

17-
**Number of indexes in a space**
26+
Number of indexes in a space
27+
----------------------------
1828

19-
128 (``box.schema.INDEX_MAX``).
29+
128 (``box.schema.INDEX_MAX``).
2030

2131
.. _limitations_fields_in_tuple:
2232

23-
**Number of fields in a tuple**
33+
Number of fields in a tuple
34+
---------------------------
2435

25-
The theoretical maximum is 2,147,483,647 (``box.schema.FIELD_MAX``). The
26-
practical maximum is whatever is specified by the space's
27-
:ref:`field_count <box_space-field_count>`
28-
member, or the maximal tuple length.
36+
The theoretical maximum is 2,147,483,647 (``box.schema.FIELD_MAX``). The
37+
practical maximum is whatever is specified by the space's
38+
:ref:`field_count <box_space-field_count>`
39+
member, or the maximal tuple length.
2940

3041
.. _limitations_bytes_in_tuple:
3142

32-
**Number of bytes in a tuple**
43+
Number of bytes in a tuple
44+
--------------------------
3345

34-
The maximal number of bytes in a tuple is roughly equal to
35-
:ref:`memtx_max_tuple_size <cfg_storage-memtx_max_tuple_size>` or
36-
:ref:`vinyl_max_tuple_size <cfg_storage-vinyl_max_tuple_size>`
37-
(with a metadata
38-
overhead of about 20 bytes per tuple, which is added on top of useful bytes).
39-
By default, the value of either ``memtx_max_tuple_size`` or
40-
``vinyl_max_tuple_size`` is 1,048,576. To increase it,
41-
specify a larger value when starting the Tarantool instance.
42-
For example, ``box.cfg{memtx_max_tuple_size=2*1048576}``.
46+
The maximal number of bytes in a tuple is roughly equal to
47+
:ref:`memtx.max_tuple_size <configuration_reference_memtx_max_size>` or
48+
:ref:`vinyl.max_tuple_size <configuration_reference_vinyl_max_tuple_size>`
49+
(with a metadata
50+
overhead of about 20 bytes per tuple, which is added on top of useful bytes).
51+
By default, the value of either ``memtx.max_tuple_size`` or
52+
``vinyl.max_tuple_size`` is 1,048,576.
4353

4454
.. _limitations_bytes_in_index_key:
4555

46-
**Number of bytes in an index key**
56+
Number of bytes in an index key
57+
-------------------------------
4758

48-
If a field in a tuple can contain a million bytes, then the index key
49-
can contain a million bytes, so the maximum is determined by factors
50-
such as :ref:`Number of bytes in a tuple <limitations_bytes_in_tuple>`,
51-
not by the index support.
59+
If a field in a tuple can contain a million bytes, then the index key
60+
can contain a million bytes, so the maximum is determined by factors
61+
such as :ref:`Number of bytes in a tuple <limitations_bytes_in_tuple>`,
62+
not by the index support.
5263

5364
.. _limitations_fields_in_tuple_multikey_index:
5465

55-
**Number of elements in array fields in a space with a multikey index**
66+
Number of elements in array fields in a space with a multikey index
67+
-------------------------------------------------------------------
5668

57-
In a Tarantool space that has :ref:`multikey indexes <box_space-path_multikey>`,
58-
any tuple cannot contain more than ~8,000 elements in a field indexed with that multikey index.
59-
This is because every element has 4 bytes of metadata, and the tuple's metadata,
60-
which includes multikey metadata, cannot exceed 2^16 bytes.
69+
In a Tarantool space that has :ref:`multikey indexes <box_space-path_multikey>`,
70+
any tuple cannot contain more than ~8,000 elements in a field indexed with that multikey index.
71+
This is because every element has 4 bytes of metadata, and the tuple's metadata,
72+
which includes multikey metadata, cannot exceed 2^16 bytes.
6173

6274
.. _limitations_number_of_spaces:
6375

64-
**Number of spaces**
76+
Number of spaces
77+
----------------
6578

66-
The theoretical maximum is 2147483646 (``box.schema.SPACE_MAX``)
67-
but the practical maximum is around 65,000.
79+
The theoretical maximum is 2,147,483,646 (``box.schema.SPACE_MAX``)
80+
but the practical maximum is around 65,000.
6881

6982
.. _limitations_number_of_connections:
7083

71-
**Number of connections**
84+
Number of connections
85+
---------------------
7286

73-
The practical limit is the number of file descriptors that one can set
74-
with the operating system.
87+
The practical limit is the number of file descriptors that one can set
88+
with the operating system.
7589

7690
.. _limitations_space_size:
7791

78-
**Space size**
92+
Space size
93+
----------
7994

80-
The total maximum size for all spaces is in effect set by
81-
:ref:`memtx.memory <configuration_reference_memtx_memory>`, which in turn
82-
is limited by the total available memory.
95+
The total maximum size for all spaces is in effect set by
96+
:ref:`memtx.memory <configuration_reference_memtx_memory>`, which in turn
97+
is limited by the total available memory.
8398

8499
.. _limitations_update_ops:
85100

86-
**Update operations count**
101+
Update operations count
102+
-----------------------
87103

88-
The maximum number of operations per tuple that can be in a single update
89-
is 4000 (``BOX_UPDATE_OP_CNT_MAX``).
104+
The maximum number of operations per tuple that can be in a single update
105+
is 4,000 (``BOX_UPDATE_OP_CNT_MAX``).
90106

91107
.. _limitations_users_and_roles:
92108

93-
**Number of users and roles**
109+
Number of users and roles
110+
-------------------------
94111

95-
32 (``BOX_USER_MAX``).
112+
32 (``BOX_USER_MAX``).
96113

97114
.. _limitations_length:
98115

99-
**Length of an index name or space name or user name**
116+
Length of an index name or space name or user name
117+
--------------------------------------------------
100118

101-
65000 (``box.schema.NAME_MAX``).
119+
65,000 (``box.schema.NAME_MAX``).
102120

103121
.. _limitations_replicas:
104122

105-
**Number of replicas in a replica set**
123+
Number of replicas in a replica set
124+
-----------------------------------
106125

107-
32 (``vclock.VCLOCK_MAX``).
126+
32 (``vclock.VCLOCK_MAX``).

0 commit comments

Comments
 (0)