diff --git a/doc/1.10/book/admin/backups.rst b/doc/1.10/book/admin/backups.rst index 94cf1ce3ab..639196bd63 100644 --- a/doc/1.10/book/admin/backups.rst +++ b/doc/1.10/book/admin/backups.rst @@ -21,21 +21,9 @@ backup.start() and backup.stop() Two functions are helpful for backups in certain situations. -``box.backup.start()`` informs the server that some activities -that might interfer with backup should be suspended -- suspend checkpointing, -suspend Tarantool garbage collection, and effectively enter read-only mode. - -Later ``box.backup.stop()`` informs the server that -normal operations may resume. Starting with Tarantool 1.10.1 there is a new -optional argument, ``box.backup.start(n)``, where ``n`` indicates the checkpoint -to use relative to the latest checkpoint -- for example ``n = 0`` means -"backup will be based on the latest checkpoint", ``n = 1`` means "backup will -be based on the first checkpoint before the latest checkpoint -(counting backwards)", and so on, -and the default value for ``n`` is zero. - -``box.backup.start()`` returns a table with the names of snapshot -and vinyl files that should be copied. Example: +``box.backup.start()`` informs the server that activities related to the removal +of outdated backups must be suspended and returns a table with the names of +snapshot and vinyl files that should be copied. Example: .. code-block:: tarantoolsession @@ -47,6 +35,21 @@ and vinyl files that should be copied. Example: - ./513/0/00000000000000000002.run ... +.. NOTE:: + + To guarantee an opportunity to copy these files Tarantool will not delete them. + But there will be no read-only mode and checkpoints will continue by schedule + as usual. + +Later ``box.backup.stop()`` informs the server that +normal operations may resume. Starting with Tarantool 1.10.1 there is a new +optional argument, ``box.backup.start(n)``, where ``n`` indicates the checkpoint +to use relative to the latest checkpoint -- for example ``n = 0`` means +"backup will be based on the latest checkpoint", ``n = 1`` means "backup will +be based on the first checkpoint before the latest checkpoint +(counting backwards)", and so on, +and the default value for ``n`` is zero. + .. _admin-backups-hot_backup_memtx: -------------------------------------------------------------------------------- diff --git a/doc/1.10/book/box/authentication.rst b/doc/1.10/book/box/authentication.rst index 8b9aa657f6..8315890f29 100644 --- a/doc/1.10/book/box/authentication.rst +++ b/doc/1.10/book/box/authentication.rst @@ -39,7 +39,7 @@ the current user, by default, is '**guest**'. If the connection is using an :ref:`admin-console port `, the current user is '**admin**'. When executing a :ref:`Lua initialization script `, -the current user is also ‘admin’. +the current user is also ‘**admin**’. The current user name can be found with :ref:`box.session.user() `. @@ -96,9 +96,9 @@ choose long unobvious passwords, but it is ultimately up to the users to choose or change their own passwords. There are two functions for managing passwords in Tarantool: -:ref:`box.schema.user.password() ` for changing -a user's password and :ref:`box.schema.user.passwd() ` -for getting a hash-password. +:ref:`box.schema.user.passwd() ` for changing a user's password and +:ref:`box.schema.user.password() ` for getting a hash +of a user's password. .. _authentication-owners_privileges: @@ -112,8 +112,8 @@ spaces, indexes, users, roles, sequences, and functions. The **owner** of a database object is the user who created it. The owner of the database itself, and the owner of objects that -are created initially -- the system spaces and the default users -- -is 'admin'. +are created initially (the system spaces and the default users) +is '**admin**'. Owners automatically have **privileges** for what they create. They can share these privileges with other users or with roles, diff --git a/doc/1.10/book/box/box_index.rst b/doc/1.10/book/box/box_index.rst index 78e2482deb..3c761d60dd 100644 --- a/doc/1.10/book/box/box_index.rst +++ b/doc/1.10/book/box/box_index.rst @@ -133,7 +133,7 @@ Below is a list of all ``box.index`` functions and members. .. _box_index-index_pairs: - .. method:: pairs([key [, iterator-type]]) + .. method:: pairs([key [,{iterator = iterator-type}]]) Search for a tuple or a set of tuples via the given index, and allow iterating over one tuple at a time. @@ -781,7 +781,7 @@ Below is a list of all ``box.index`` functions and members. :param scalar/table key: values to be matched against the index key :param iterator: comparison method - :return: the number of matching index keys. + :return: the number of matching tuples. :rtype: number **Example:** diff --git a/doc/1.10/book/box/box_txn_management.rst b/doc/1.10/book/box/box_txn_management.rst index bdcbb1b358..8626ac6fef 100644 --- a/doc/1.10/book/box/box_txn_management.rst +++ b/doc/1.10/book/box/box_txn_management.rst @@ -75,7 +75,7 @@ Below is a list of all functions for transaction management. | :ref:`box.on_rollback() | Define a trigger that will be | | ` | activated by ``box.rollback`` | +--------------------------------------+---------------------------------+ - | :ref:`is_in_txn() | State whether a transaction is | + | :ref:`box.is_in_txn() | State whether a transaction is | | ` | in progress | +--------------------------------------+---------------------------------+ diff --git a/doc/1.10/book/box/data_model.rst b/doc/1.10/book/box/data_model.rst index c219c9b1c2..1a8ed947e9 100644 --- a/doc/1.10/book/box/data_model.rst +++ b/doc/1.10/book/box/data_model.rst @@ -49,7 +49,7 @@ Any given tuple may have any number of fields, and the fields may be of different :ref:`types `. The identifier of a field is the field's number, base 1 (in Lua and other 1-based languages) or base 0 (in PHP or C/C++). -For example, “1” or "0" can be used in some contexts to refer to the first +For example, ``1`` or ``0`` can be used in some contexts to refer to the first field of a tuple. Tuples in Tarantool are stored as diff --git a/doc/1.10/book/box/triggers.rst b/doc/1.10/book/box/triggers.rst index 4383fae4ba..8ef52d7ce1 100644 --- a/doc/1.10/book/box/triggers.rst +++ b/doc/1.10/book/box/triggers.rst @@ -14,10 +14,10 @@ There are four types of triggers in Tarantool: when a session begins or ends, * :ref:`authentication triggers `, which are - executed during authentication, and + executed during authentication, * :ref:`replace triggers `, which are for database - events. + events, and * :ref:`transaction triggers `, which are executed during commit or rollback. @@ -73,7 +73,7 @@ To get a list of triggers, you can use: * on_connect() – with no arguments – to return a table of all connect-trigger functions; * on_auth() to return all authentication-trigger functions; * on_disconnect() to return all disconnect-trigger functions; -* on_replace() to return all replace-trigger functions made for on_replace(). +* on_replace() to return all replace-trigger functions made for on_replace(); * before_replace() to return all replace-trigger functions made for before_replace(). **Example** diff --git a/doc/1.10/book/connectors/__python.rst b/doc/1.10/book/connectors/__python.rst index 8addf0028e..beed23e545 100644 --- a/doc/1.10/book/connectors/__python.rst +++ b/doc/1.10/book/connectors/__python.rst @@ -2,6 +2,10 @@ Python ===================================================================== +`tarantool-python `_ +is the official Python connector for Tarantool. It is not supplied as part +of the Tarantool repository and must be installed separately (see below for details). + Here is a complete Python program that inserts ``[99999,'Value','Value']`` into space ``examples`` via the high-level Python API. @@ -18,7 +22,9 @@ To prepare, paste the code into a file named :file:`example.py` and install the ``tarantool-python`` connector with either :samp:`pip install tarantool\>0.4` to install in :file:`/usr` (requires **root** privilege) or :samp:`pip install tarantool\>0.4 --user` to install in :file:`~` i.e. user's -default directory. Before trying to run, check that the server instance is :ref:`listening ` at +default directory. + +Before trying to run, check that the server instance is :ref:`listening ` at ``localhost:3301`` and that the space ``examples`` exists, as :ref:`described earlier `. To run the program, say :samp:`python example.py`. The program will connect @@ -32,3 +38,9 @@ necessary for good practice. For that, please see For an example of using Python API with `queue managers for Tarantool `_, see `queue-python `_ project at GitHub. + +Also there are several community-driven Python connectors: + + * `asynctnt `_ with asyncio support + * `aiotarantool `_ also with asyncio support + * `gtarantool `_ with gevent support **no active maintenance** diff --git a/doc/1.10/reference/reference_lua/fiber.rst b/doc/1.10/reference/reference_lua/fiber.rst index a5317f2237..0a3f6aa27a 100644 --- a/doc/1.10/reference/reference_lua/fiber.rst +++ b/doc/1.10/reference/reference_lua/fiber.rst @@ -399,7 +399,12 @@ recommended. .. NOTE:: - This exception cannot be caught by pcall or xpcall. + Even if you catch the exception, the fiber will remain cancelled. + Most types of calls will check ``fiber.testcancel()``. + However, some functions (``id``, ``status``, ``join`` etc.) will return no error. + We recommend application developers to implement occasional checks with + :ref:`fiber.testcancel() ` and to end fiber's execution + as soon as possible in case it has been cancelled. **Example:** @@ -515,7 +520,7 @@ recommended. Cancel a fiber. Running and suspended fibers can be cancelled. After a fiber has been cancelled, attempts to operate on it will - cause errors, for example :ref:`fiber_object:id() ` + cause errors, for example :ref:`fiber_object:name() ` will cause ``error: the fiber is dead``. :param fiber_object: generally this is an object referenced in the return diff --git a/doc/1.10/reference/reference_rock/vshard/index.rst b/doc/1.10/reference/reference_rock/vshard/index.rst index 28fabf97aa..edddd78c60 100644 --- a/doc/1.10/reference/reference_rock/vshard/index.rst +++ b/doc/1.10/reference/reference_rock/vshard/index.rst @@ -1477,6 +1477,9 @@ Router public API :param timeout: a timeout, in seconds + :return: ``true`` if the dataset was synchronized successfully; or ``nil`` and + ``err`` explaining why the dataset cannot be synchronized. + .. _router_api-discovery_wakeup: .. function:: vshard.router.discovery_wakeup() @@ -1753,6 +1756,9 @@ Storage public API :param timeout: a timeout, in seconds + :return: ``true`` if the dataset was synchronized successfully; or ``nil`` and + ``err`` explaining why the dataset cannot be synchronized. + .. _storage_api-bucket_pin: .. function:: vshard.storage.bucket_pin(bucket_id) diff --git a/locale/ru/LC_MESSAGES/doc.po b/locale/ru/LC_MESSAGES/doc.po index 4c2e63a0f5..f8254522f9 100644 --- a/locale/ru/LC_MESSAGES/doc.po +++ b/locale/ru/LC_MESSAGES/doc.po @@ -22677,12 +22677,12 @@ msgstr "полям не нужны имена." msgid "" "Any given tuple may have any number of fields, and the fields may be of different :ref:" "`types `. The identifier of a field is the field's number, base 1 (in " -"Lua and other 1-based languages) or base 0 (in PHP or C/C++). For example, “1” or \"0\" can " +"Lua and other 1-based languages) or base 0 (in PHP or C/C++). For example, ``1`` or ``0`` can " "be used in some contexts to refer to the first field of a tuple." msgstr "" "В любом кортеже может быть любое количество полей, и это могут быть поля разных :ref:`типов " "`. Идентификатором поля является его номер, начиная с 1 (в Lua и " -"других языках с индексацией с 1) или с 0 (в PHP или C/C++). Например, “1” или \"0\" могут " +"других языках с индексацией с 1) или с 0 (в PHP или C/C++). Например, ``1`` или ``0`` могут " "использоваться в некоторых контекстах для обозначения первого поля кортежа." #: ../doc/1.10/book/box/data_model.rst:89 @@ -26014,16 +26014,16 @@ msgstr "" #: ../doc/1.10/book/box/triggers.rst:50 msgid "" ":ref:`authentication triggers `, which are executed during " -"authentication, and" +"authentication," msgstr "" ":ref:`триггеры для обработки аутентификации `, которые выполняются при " -"аутентификации, и" +"аутентификации," #: ../doc/1.10/book/box/triggers.rst:53 -msgid ":ref:`replace triggers `, which are for database events." +msgid ":ref:`replace triggers `, which are for database events, and" msgstr "" ":ref:`триггеры для обработки замены `, которые предназначены для " -"событий в базе данных." +"событий в базе данных, и" #: ../doc/1.10/book/box/triggers.rst:56 msgid "" @@ -26159,10 +26159,10 @@ msgid "on_disconnect() to return all disconnect-trigger functions;" msgstr "on_disconnect(), чтобы вернуть все триггерные функции для обработки отключений;" #: ../doc/1.10/book/box/triggers.rst:110 -msgid "on_replace() to return all replace-trigger functions made for on_replace()." +msgid "on_replace() to return all replace-trigger functions made for on_replace();" msgstr "" "on_replace(), чтобы вернуть все триггерные функции для обработки замены, сделанные для " -"on_replace()." +"on_replace();" #: ../doc/1.10/book/box/triggers.rst:111 msgid "before_replace() to return all replace-trigger functions made for before_replace()." @@ -28134,8 +28134,8 @@ msgstr "" " > })" #: ../doc/1.10/book/getting_started/using_binary.rst:145 -msgid "Create the first :ref:`index ` (named ``'primary'``):" -msgstr "Создайте первый :ref:`индекс ` (с именем``'primary'``):" +msgid "Create the first :ref:`index ` (named ``primary``):" +msgstr "Создайте первый :ref:`индекс ` (с именем``primary``):" #: ../doc/1.10/book/getting_started/using_binary.rst:147 msgid "" @@ -28155,9 +28155,9 @@ msgstr "Это первичный индекс по полю ``id`` в кажд #: ../doc/1.10/book/getting_started/using_binary.rst:156 #: ../doc/1.10/book/getting_started/using_docker.rst:159 -msgid "Insert three :ref:`tuples ` (our name for \"records\") into the space:" +msgid "Insert three :ref:`tuples ` (our name for records) into the space:" msgstr "" -"Вставьте в созданный спейс три :ref:`кортежа ` (наш термин для «записей»):" +"Вставьте в созданный спейс три :ref:`кортежа ` (наш термин для записей):" #: ../doc/1.10/book/getting_started/using_binary.rst:159 msgid "" @@ -28170,8 +28170,8 @@ msgstr "" "tarantool> s:insert{3, 'Ace of Base', 1993}" #: ../doc/1.10/book/getting_started/using_binary.rst:165 -msgid "To select a tuple using the ``'primary'`` index, say:" -msgstr "Для выборки кортежей по первичному индексу ``'primary'`` выполните команду:" +msgid "To select a tuple using the ``primary`` index, say:" +msgstr "Для выборки кортежей по первичному индексу ``primary`` выполните команду:" #: ../doc/1.10/book/getting_started/using_binary.rst:167 msgid "tarantool> s:select{3}" @@ -28269,8 +28269,8 @@ msgstr "" "..." #: ../doc/1.10/book/getting_started/using_binary.rst:217 -msgid "To add a secondary index based on the ``'band_name'`` field, say:" -msgstr "Для добавления вторичного индекса по полю ``'band_name'`` используйте эту команду:" +msgid "To add a secondary index based on the ``band_name`` field, say:" +msgstr "Для добавления вторичного индекса по полю ``band_name`` используйте эту команду:" #: ../doc/1.10/book/getting_started/using_binary.rst:219 msgid "" @@ -28285,8 +28285,8 @@ msgstr "" " > })" #: ../doc/1.10/book/getting_started/using_binary.rst:226 -msgid "To select tuples using the ``'secondary'`` index, say:" -msgstr "Для выборки кортежей по вторичному индексу ``'secondary'`` выполните команду:" +msgid "To select tuples using the ``secondary`` index, say:" +msgstr "Для выборки кортежей по вторичному индексу ``secondary`` выполните команду:" #: ../doc/1.10/book/getting_started/using_binary.rst:228 msgid "" @@ -45013,7 +45013,7 @@ msgstr "Способы ссылки на объект" #: ../doc/1.10/reference/lua_tips.rst:56 msgid "First, there are three **object reference variations**:" -msgstr "Во-первых, есть пять *способов ссылки на объект*:" +msgstr "Во-первых, есть три **способа ссылки на объект**:" #: ../doc/1.10/reference/lua_tips.rst:58 msgid "" @@ -45039,7 +45039,7 @@ msgid "" "this is a matter of user preference and all the variations exist in the wild." msgstr "" "Для примеров в документации, как правило, используется вариант синтаксиса №1, например \":" -"samp:`box.space.{tester}:`\". Но вы можете с тем же успехом пользоваться любым из пяти " +"samp:`box.space.{tester}:`\". Но вы можете с тем же успехом пользоваться любым из трех " "описанных выше вариантов." #: ../doc/1.10/reference/lua_tips.rst:72 @@ -51908,6 +51908,7 @@ msgstr "расположение, например 'https://tarantool.org/doc'" msgid "optional initial message, for example 'My text string!'" msgstr "необязательное начальное сообщение, например 'My text string!'" +#, fuzzy #: ../doc/1.10/reference/reference_lua/http.rst:107 msgid "" "table of connection options, with any of these components: * ``timeout`` - number of "