From d0ece72f800d8ed0632597929d0c0d022e0ff3bc Mon Sep 17 00:00:00 2001 From: Peter Gulutzan Date: Tue, 13 Jul 2021 16:33:10 -0600 Subject: [PATCH 1/6] Fixes gh-2185 IPROTO_BALLOT rework and a new field --- doc/dev_guide/internals/box_protocol.rst | 35 +++++++++++++++++++----- 1 file changed, 28 insertions(+), 7 deletions(-) diff --git a/doc/dev_guide/internals/box_protocol.rst b/doc/dev_guide/internals/box_protocol.rst index 300b1a0b29..cbeeb34083 100644 --- a/doc/dev_guide/internals/box_protocol.rst +++ b/doc/dev_guide/internals/box_protocol.rst @@ -168,11 +168,12 @@ The IPROTO constants that appear within requests or responses that we will descr IPROTO_EXPR=0x27 IPROTO_OPS=0x28 IPROTO_BALLOT=0x29 - IPROTO_BALLOT_IS_RO=0x01 + IPROTO_BALLOT_IS_RO_CFG=0x01 IPROTO_BALLOT_VCLOCK=0x02 IPROTO_BALLOT_GC_VCLOCK=0x03 - IPROTO_BALLOT_IS_LOADING=0x04 + IPROTO_BALLOT_IS_RO=0x04 IPROTO_BALLOT_IS_ANON=0x05 + IPROTO_BALLOT_IS_BOOTED=0x06 IPROTO_TUPLE_META=0x2a IPROTO_OPTIONS=0x2b IPROTO_DATA=0x30 @@ -1273,16 +1274,36 @@ The fields within IPROTO_BALLOT are map items: .. code-block:: none - IPROTO_BALLOT_IS_RO (0x01) + MP_BOOL + IPROTO_BALLOT_IS_RO_CFG (0x01) + MP_BOOL IPROTO_BALLOT_VCLOCK (0x02) + vclock IPROTO_BALLOT_GC_VCLOCK (0x03) + vclock - IPROTO_BALLOT_IS_LOADING (0x04) + MP_BOOL + IPROTO_BALLOT_IS_RO (0x04) + MP_BOOL IPROTO_BALLOT_IS_ANON = 0x05 + MP_BOOL + IPROTO_BALLOT_IS_BOOTED = 0x06 + MP_BOOL -IPROTO_BALLOt-IS_ANON corresponds to :ref:`box.cfg.replication_anon `. +IPROTO_BALLOT_IS_RO_CFG and IPRO_BALLOT_VCLOCK and IPROTO_BALLOT_GC_VCLOCK and IPROTO_BALLOT_IS_RO +were added in version :doc:`2.6.1 `. +IPROTO_BALLOT_IS_ANON was added in version :doc:`2.7.1 `. +IPROTO_BALLOT_IS_BOOTED was added in version 2.7.2. +There have been some name changes starting with version 2.7.2: +IPROTO_BALLOT_IS_RO_CFG was formerly called IPROTO_BALLOT_IS_RO, +and IPROTO_BALLOT_IS_RO was formerly called IPROTO_BALLOT_IS_LOADING. -The items other than IPROTO_BALLOT_IS_ANON were added in version :doc:`2.6.1 `. -PROTO_BALLOT_IS_ANON was added in version :doc:`2.7.1 `. +IPROTO_BALLOT_IS_RO_CFG corresponds to :ref:`box.cfg.read_only `. + +IPROTO_BALLOT_GC_VCLOCK may have the value of the instance's oldest +WAL entry, which corresponds to :ref:`box.info.gc().vclock `. + +IPROTO_BALLOT_RO is true if the instance is not writable, +which may happen for a variety of reasons, such as: +it was configured as :ref:`read_only `, +or it has :ref:`orphan status `, +or it is a :ref:`Raft ` follower. + +IPROTO_BALLOT_IS_ANON corresponds to :ref:`box.cfg.replication_anon `. + +IPROTO_BALLOT_IS_BOOTED is true if the instance has finished its +bootstrap or recovery process. .. _box_protocol-flags: From fea09e369be330ba6b6a32b4fc34dad279524d86 Mon Sep 17 00:00:00 2001 From: Peter Gulutzan Date: Tue, 13 Jul 2021 16:48:48 -0600 Subject: [PATCH 2/6] Corrected version numbers of IPROTO_BALLOT change --- doc/dev_guide/internals/box_protocol.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/dev_guide/internals/box_protocol.rst b/doc/dev_guide/internals/box_protocol.rst index cbeeb34083..7158648c28 100644 --- a/doc/dev_guide/internals/box_protocol.rst +++ b/doc/dev_guide/internals/box_protocol.rst @@ -1284,8 +1284,8 @@ The fields within IPROTO_BALLOT are map items: IPROTO_BALLOT_IS_RO_CFG and IPRO_BALLOT_VCLOCK and IPROTO_BALLOT_GC_VCLOCK and IPROTO_BALLOT_IS_RO were added in version :doc:`2.6.1 `. IPROTO_BALLOT_IS_ANON was added in version :doc:`2.7.1 `. -IPROTO_BALLOT_IS_BOOTED was added in version 2.7.2. -There have been some name changes starting with version 2.7.2: +IPROTO_BALLOT_IS_BOOTED was added in version 2.7.3 and 2.8.2 and 2.9.1. +There have been some name changes starting with version 2.7.3 and 2.8.2 and 2.9.1: IPROTO_BALLOT_IS_RO_CFG was formerly called IPROTO_BALLOT_IS_RO, and IPROTO_BALLOT_IS_RO was formerly called IPROTO_BALLOT_IS_LOADING. From 152d90c58a3de566bbcd4c1df8f492c656d2552a Mon Sep 17 00:00:00 2001 From: Peter Gulutzan Date: Fri, 16 Jul 2021 08:13:46 -0600 Subject: [PATCH 3/6] Change iproto_ballot_ro to iproto_ballot_is_ro --- doc/dev_guide/internals/box_protocol.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/dev_guide/internals/box_protocol.rst b/doc/dev_guide/internals/box_protocol.rst index 7158648c28..1158e64ac7 100644 --- a/doc/dev_guide/internals/box_protocol.rst +++ b/doc/dev_guide/internals/box_protocol.rst @@ -1294,7 +1294,7 @@ IPROTO_BALLOT_IS_RO_CFG corresponds to :ref:`box.cfg.read_only `. -IPROTO_BALLOT_RO is true if the instance is not writable, +IPROTO_BALLOT_IS_RO is true if the instance is not writable, which may happen for a variety of reasons, such as: it was configured as :ref:`read_only `, or it has :ref:`orphan status `, From edcc899d4e011aeaaf70c6f3860febd8a75d7388 Mon Sep 17 00:00:00 2001 From: Evgeniy Osintsev <48726281+veod32@users.noreply.github.com> Date: Tue, 20 Jul 2021 15:47:18 +0300 Subject: [PATCH 4/6] Update doc/dev_guide/internals/box_protocol.rst Co-authored-by: Patience Daur <40490252+patiencedaur@users.noreply.github.com> --- doc/dev_guide/internals/box_protocol.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/dev_guide/internals/box_protocol.rst b/doc/dev_guide/internals/box_protocol.rst index 1158e64ac7..e50fd5ff00 100644 --- a/doc/dev_guide/internals/box_protocol.rst +++ b/doc/dev_guide/internals/box_protocol.rst @@ -1291,7 +1291,7 @@ and IPROTO_BALLOT_IS_RO was formerly called IPROTO_BALLOT_IS_LOADING. IPROTO_BALLOT_IS_RO_CFG corresponds to :ref:`box.cfg.read_only `. -IPROTO_BALLOT_GC_VCLOCK may have the value of the instance's oldest +IPROTO_BALLOT_GC_VCLOCK can be the vclock value of the instance's oldest WAL entry, which corresponds to :ref:`box.info.gc().vclock `. IPROTO_BALLOT_IS_RO is true if the instance is not writable, From ccdce481e50a899190bb98432fdba22b7d24e422 Mon Sep 17 00:00:00 2001 From: patiencedaur Date: Tue, 20 Jul 2021 16:20:20 +0000 Subject: [PATCH 5/6] Update translations --- locale/ru/LC_MESSAGES/book/box/data_model.po | 670 ++++++++++-------- .../book/replication/repl_leader_elect.po | 14 +- .../LC_MESSAGES/book/replication/repl_sync.po | 155 +++- locale/ru/LC_MESSAGES/contributing/docs.po | 6 +- .../contributing/docs/sphinx-warnings.po | 3 - .../dev_guide/internals/box_protocol.po | 89 ++- 6 files changed, 564 insertions(+), 373 deletions(-) diff --git a/locale/ru/LC_MESSAGES/book/box/data_model.po b/locale/ru/LC_MESSAGES/book/box/data_model.po index 29b9f6ced3..d546148204 100644 --- a/locale/ru/LC_MESSAGES/book/box/data_model.po +++ b/locale/ru/LC_MESSAGES/book/box/data_model.po @@ -37,12 +37,13 @@ msgstr "" "называются :term:`полями `." msgid "" -"When Tarantool returns a tuple value in the console, by default it uses " +"When Tarantool returns a tuple value in the console, by default, it uses " ":ref:`YAML ` format, for example: ``[3, 'Ace of Base', " "1993]``." msgstr "" -"Когда Tarantool выводит значение в кортеже в консоль, используется формат " -":ref:`YAML `, например: ``[3, 'Ace of Base', 1993]``." +"Когда Tarantool выводит значение кортежа в консоль, по умолчанию " +"используется формат :ref:`YAML `, например: ``[3, 'Ace " +"of Base', 1993]``." msgid "" "Internally, Tarantool stores tuples as `MsgPack " @@ -75,6 +76,8 @@ msgid "" "A given tuple may have any number of fields, and the fields may be of " "different :ref:`types `." msgstr "" +"В кортеже может быть любое количество полей, и это могут быть поля разных " +":ref:`типов `." msgid "" "The field's number is the identifier of the field. Numbers are counted from " @@ -82,47 +85,66 @@ msgid "" "PHP or C/C++. So, ``1`` or ``0`` can be used in some contexts to refer to " "the first field of a tuple." msgstr "" +"Номер поля служит его идентификатором. В Lua и некоторых других языках " +"нумерация начинается с 1, в других — с 0 (например, в PHP или C/C++). Таким " +"образом, в некоторых контекстах у первого поля кортежа будет индекс ``1`` " +"или ``0``." msgid "Spaces" msgstr "Спейсы" msgid "" -"Tarantool stores tuples in containers called spaces. In our example there's " -"a space called ``'tester'``." +"Tarantool stores tuples in containers called spaces. In the example above, " +"there's a space called ``tester``." msgstr "" +"Tarantool хранит кортежи в контейнерах, называемых спейсами (space). Спейс в" +" примере выше называется ``tester``." msgid "space" msgstr "спейс" msgid "" -"In Tarantool, a space is a primary container which stores data. It is " +"In Tarantool, a space is a primary container that stores data. It is " "analogous to tables in relational databases. Spaces contain :term:`tuples " "` — the Tarantool name for database records. The number of tuples in " "a space is unlimited." msgstr "" +"В Tarantool спейс — это первичный контейнер, хранящий данные. Он похож на " +"таблицы в реляционных базах данных. Спейсы содержат :term:`кортежи ` " +"— так в Tarantool называются записи в базе данных. Количество кортежей в " +"спейсе не ограничено." msgid "" "At least one space is required to store data with Tarantool. Each space has " "the following attributes:" msgstr "" +"Для хранения данных с помощью Tarantool требуется хотя бы один спейс. У " +"каждого спейса есть следующие атрибуты:" msgid "a unique **name** specified by the user," -msgstr "" +msgstr "уникальное **имя**, указанное пользователем;" msgid "" "a unique **numeric identifier** which can be specified by the user, but " "usually is assigned automatically by Tarantool," msgstr "" +"уникальный **числовой идентификатор**, обычно Tarantool назначает его " +"автоматически, но пользователь может его указать сам, если посчитает нужным;" msgid "" "an **engine**: *memtx* (default) -- in-memory engine, fast but limited in " "size, or *vinyl* -- on-disk engine for huge data sets." msgstr "" +"**движок**: *memtx* (по умолчанию) — движок «in-memory», быстрый, но " +"ограниченный в размере, или *vinyl* — дисковый движок для огромных наборов " +"данных." msgid "" "To be functional, a space also needs to have a :ref:`primary index `. It can also have secondary indexes." msgstr "" +"Для работы спейсу нужен :ref:`первичный индекс `. Также он может\n" +"использовать вторичные индексы." msgid "Indexes" msgstr "Индексы" @@ -131,32 +153,34 @@ msgid "" "Read the full information about indexes on page :doc:`Indexes " "`." msgstr "" +"Всю информацию про индексы можно найти на странице :doc:`Индексы " +"`." msgid "An **index** is a group of key values and pointers." msgstr "**Индекс** — это совокупность значений ключей и указателей." msgid "" -"As with spaces, you should specify the index **name**, and let Tarantool " -"come up with a unique **numeric identifier** (\"index id\")." +"As with spaces, you should specify the index **name** and let Tarantool come" +" up with a unique **numeric identifier** (\"index id\")." msgstr "" -"Как и для спейсов, индексам следует указать **имена**, а Tarantool определит" -" уникальный **числовой идентификатор** (\"ID индекса\")." +"Как и для спейсов, для индексов следует указать **имена**, а Tarantool " +"определит уникальный **числовой идентификатор** (\"ID индекса\")." msgid "" "An index always has a **type**. The default index type is :ref:`TREE " "`. TREE indexes are provided by all Tarantool engines, can " "index unique and non-unique values, support partial key searches, " -"comparisons and ordered results. Additionally, memtx engine supports " +"comparisons, and ordered results. Additionally, the memtx engine supports " ":ref:`HASH `, :ref:`RTREE ` and :ref:`BITSET " "` indexes." msgstr "" "У индекса всегда есть определенный **тип**. Тип индекса по умолчанию — " -":ref:`TREE `. Все движки Tarantool предоставляют TREE-индексы," -" которые могут индексировать уникальные и неуникальные значения, " -"поддерживают поиск по компонентам ключа, сравнение ключей и упорядоченные " -"результаты. Кроме того, движок memtx поддерживает следующие типы индексов: " -":ref:`HASH `, :ref:`RTREE ` и :ref:`BITSET " -"`." +":ref:`TREE `. TREE-индексы поддерживаются обоими движками " +"Tarantool, могут индексировать уникальные и неуникальные значения, " +"поддерживают поиск по компонентам ключа, сравнение ключей и упорядочивание " +"результатов. Движок memtx поддерживает и другие типы индексов: :ref:`HASH " +"`, :ref:`RTREE ` и :ref:`BITSET `." msgid "" "An index may be **multi-part**, that is, you can declare that an index key " @@ -317,22 +341,22 @@ msgid "Field Type Details" msgstr "Описание типов полей" msgid "" -"**nil**. In Lua a nil type has only one possible value, also called *nil* " -"(which Tarantool displays as ``null`` when using the default :ref:`YAML " -"` format). Nils may be compared to values of any types " +"**nil**. In Lua, the nil type has only one possible value, also called " +"``nil``. Tarantool displays it as ``null`` when using the default :ref:`YAML" +" ` format. Nil may be compared to values of any types " "with == (is-equal) or ~= (is-not-equal), but other comparison operations " -"will not work. Nils may not be used in Lua tables; the workaround is to use " +"will not work. Nil may not be used in Lua tables; the workaround is to use " ":ref:`box.NULL ` because ``nil == box.NULL`` is true. Example: " "``nil``." msgstr "" -"**nil**. В языке Lua nil может иметь только одно значение, также называемое " -"*nil* (отображается как ``null`` в командной строке Tarantool, где значения " -"выводятся в формате :ref:`YAML ` по умолчанию). " -"Значение nil можно сравнивать со значениями любых типов данных с помощью " -"операторов == (равен) или ~= (не равен), но никакие другие операции для nil " -"не доступны. Nil также нельзя использовать в Lua-таблицах — вместо nil в " -"таком случае можно указать :ref:`box.NULL `, поскольку условие " -"``nil == box.NULL`` является истинным. Пример: ``nil``." +"**nil**. В языке Lua у типа nil есть только одно значение, также называемое " +"``nil``. Tarantool отображает его как ``null`` при использовании формата по " +"умолчанию :ref:`YAML `. Значение nil можно сравнивать " +"со значениями любых типов данных с помощью операторов == (равно) или ~= (не " +"равно), но никакие другие операции сравнения к nil не применимы. Значение " +"nil также нельзя использовать в Lua-таблицах — в качестве обходного пути " +"вместо nil в таком случае можно указать :ref:`box.NULL `, " +"поскольку условие ``nil == box.NULL`` является истинным. Пример: ``nil``." msgid "" "**boolean**. A boolean is either ``true`` or ``false``. Example: ``true``." @@ -343,47 +367,52 @@ msgstr "" msgid "" "**integer**. The Tarantool integer type is for integers between " "-9223372036854775808 and 18446744073709551615, which is about 18 " -"quintillion. This corresponds to number in Lua and to integer in MsgPack. " -"Example: ``-2^63``." +"quintillion. This type corresponds to the number type in Lua and to the " +"integer type in MsgPack. Example: ``-2^63``." msgstr "" "**integer**. В Tarantool тип полей integer используется для целых чисел от " "−9 223 372 036 854 775 808 до 18 446 744 073 709 551 615, то есть до " -"примерно 18 квинтиллионов. Такой тип данных соответствует типу number в Lua " -"или integer в MsgPack. Пример: ``-2^63``." +"примерно 18 квинтиллионов. Такой тип данных соответствует типам number в Lua" +" и integer в MsgPack. Пример: ``-2^63``." msgid "" "**unsigned**. The Tarantool unsigned type is for integers between 0 and " "18446744073709551615. So it is a subset of integer. Example: ``123456``." msgstr "" +"**unsigned**. Тип unsigned в Tarantool используется для целых чисел от 0 до " +"18 446 744 073 709 551 615. Он представляет собой подмножество типа integer." +" Пример: ``123456``." + +msgid "" +"**double**. The double field type exists mainly to be equivalent to " +"Tarantool/SQL's :ref:`DOUBLE data type `. In " +"`msgpuck.h `_ (Tarantool's interface to " +"MsgPack), the storage type is ``MP_DOUBLE`` and the size of the encoded " +"value is always 9 bytes. In Lua, fields of the double type can only contain " +"non-integer numeric values and cdata values with double floating-point " +"numbers. Examples: ``1.234``, ``-44``, ``1.447e+44``." +msgstr "" +"**double**. Поле типа double существует главным образом для соответствия " +"типу :ref:`DOUBLE data type ` в Tarantool/SQL . В " +"`msgpuck.h `_ (интерфейс Tarantool к " +"MsgPack) тип в хранилище — ``MP_DOUBLE``, а размер закодированного значения " +"всегда составляет 9 байтов. В Lua поля типа double могут содержать только не" +" целые числовые значения и значения cdata с числами с плавающей точкой " +"двойной точности (double). Примеры: ``1.234``, ``-44``, ``1.447e+44``." msgid "" -"**double**. The double field type exists mainly so that there will be an " -"equivalent to Tarantool/SQL's :ref:`DOUBLE data type " -"`. In `msgpuck.h " -"`_ (Tarantool's interface to MsgPack) " -"the storage type is MP_DOUBLE and the size of the encoded value is always 9 " -"bytes. In Lua, 'double' fields can only contain non-integer numeric values " -"and cdata values with double floating-point numbers. Examples: ``1.234``, " -"``-44``, ``1.447e+44``. |br| To avoid using the wrong kind of values " -"inadvertently, use ``ffi.cast()`` when searching or changing 'double' " -"fields. For example, instead of " -":samp:`{space_object}:insert`:code:`{`:samp:`{value}`:code:`}` say ``ffi = " +"To avoid using the wrong kind of values inadvertently, use ``ffi.cast()`` " +"when searching or changing ``double`` fields. For example, instead of " +":samp:`{space_object}:insert`:code:`{`:samp:`{value}`:code:`}` use ``ffi = " "require('ffi') ...`` " ":samp:`{space_object}:insert`:code:`({ffi.cast('double',`:samp:`{value}`:code:`)})`." " Example:" msgstr "" -"**double**. Тип поля double создан специально для соответствия :ref:`типу " -"данных DOUBLE ` в Tarantool/SQL. В интерфейсе " -"Tarantool к MsgPack, который называется `msgpuck.h " -"`_, используется тип хранения MP_DOUBLE," -" а размер кодируемого значения всегда составляет 9 байтов. В Lua поля " -"'double' могут содержать только нецелые числа и значения типа cdata с " -"плавающей запятой двойной точности. Примеры: ``1.234``, ``-44``, " -"``1.447e+44``. |br| Чтобы случайно не использовать неправильные значения, " -"используйте ``ffi.cast()`` для поиска или изменения полей типа 'double'. " -"Например, вместо " -":samp:`{space_object}:insert`:code:`{`:samp:`{value}`:code:`}` вводите ``ffi" -" = require('ffi') ...`` " +"Чтобы избежать случайного использования неправильного типа значений, " +"используйте явное преобразование типа ``ffi.cast()``, когда вы ищете или " +"изменяете поля типа ``double``. Например, вместо " +":samp:`{space_object}:insert`:code:`{`:samp:`{value}`:code:`}` используйте " +"``ffi = require('ffi') ...`` " ":samp:`{space_object}:insert`:code:`({ffi.cast('double',`:samp:`{value}`:code:`)})`." " Пример:" @@ -407,19 +436,26 @@ msgstr "" "s:select({ffi.cast('double', 1)})" msgid "" -"Arithmetic with cdata 'double' will not work reliably, so for Lua it is " -"better to use the 'number' type. This warning does not apply for " +"Arithmetic with cdata ``double`` will not work reliably, so for Lua, it is " +"better to use the ``number`` type. This warning does not apply for " "Tarantool/SQL because Tarantool/SQL does :ref:`implicit casting " "`." msgstr "" -"Арифметические операции с cdata 'double' не дадут достоверный результат, " -"поэтому для Lua лучше использовать тип 'number'. Это не относится к " -"Tarantool/SQL, так как Tarantool/SQL выполняет :ref:`неявное приведение " +"Арифметические операции с cdata формата ``double`` работают ненадёжно, " +"поэтому для Lua лучше использовать тип ``number``. Это не относится к " +"Tarantool/SQL, так как Tarantool/SQL применяет :ref:`неявное приведение " "типов `." msgid "" -"**number**. In Lua a number is double-precision floating-point, but a " -"Tarantool 'number' field may have both integer and floating-point values. " +"**number**. The Tarantool number field may have both integer and floating-" +"point values, although in Lua a ``number`` is a double-precision floating-" +"point." +msgstr "" +"**number**. Поле number в Tarantool может содержать значения как целые, так " +"и с плавающей точкой, хотя в Lua тип ``number`` означает число с плавающей " +"точкой двойной точности." + +msgid "" "Tarantool will try to store a Lua number as floating-point if the value " "contains a decimal point or is very large (greater than 100 trillion = " "1e14), otherwise Tarantool will store it as an integer. To ensure that even " @@ -430,18 +466,15 @@ msgid "" "``-55``, ``-2.7e+20``, ``100000000000000ULL``, " "``tonumber64('18446744073709551615')``." msgstr "" -"**number**. В Lua number — это числа с плавающей запятой двойной точности, " -"но в Tarantool поле типа 'number' может содержать как целые числа, так и " -"числа с плавающей запятой. Tarantool по возможности сохраняет значения " -"number языка Lua в виде чисел с плавающей запятой, если числовое значение " -"содержит десятичную запятую или если оно очень велико (более 100 триллионов " -"= 1e14). В противном случае, Tarantool сохранит такое значение в виде целого" -" числа. Чтобы даже очень большие числа гарантированно обрабатывались как " -"целые числа, используйте функцию :ref:`tonumber64 ` или же" -" приписывайте в конце суффикс LL (Long Long) или ULL (Unsigned Long Long). " -"Вот примеры записи чисел в обычном представлении, экспоненциальном, с " -"суффиксом ULL и с использованием функции ``tonumber64``: ``-55``, " -"``-2.7e+20``, ``100000000000000ULL``, " +"Tarantool по возможности сохраняет числа языка Lua в виде чисел с плавающей " +"запятой, если числовое значение содержит десятичную запятую или если оно " +"очень велико (более 100 триллионов = 1e14). В противном случае Tarantool " +"сохраняет такое значение в виде целого числа. Чтобы даже очень большие " +"величины гарантированно сохранялись как целые числа, используйте функцию " +":ref:`tonumber64 ` или приписывайте в конце суффикс LL " +"(Long Long) или ULL (Unsigned Long Long). Вот примеры записи чисел в обычном" +" представлении, экспоненциальном, с суффиксом ULL и с использованием функции" +" ``tonumber64``: ``−55``, ``−2.7e+20``, ``100000000000000ULL``, " "``tonumber64('18446744073709551615')``." msgid "" @@ -464,22 +497,22 @@ msgid "" "determine a string's character set or to perform any string conversion -- " "unless there is an optional :ref:`collation `. So, usually," " string sorting and comparison are done byte-by-byte, without any special " -"collation rules applied. (Example: numbers are ordered by their point on the" -" number line, so 2345 is greater than 500; meanwhile, strings are ordered by" -" the encoding of the first byte, then the encoding of the second byte, and " -"so on, so ``'2345'`` is less than ``'500'``.) Example: ``'A, B, C'``." -msgstr "" -"**string**. Значения строкового типа string содержат последовательность " -"байтов переменной длины, обычно представленную буквенно-цифровыми символами " -"в одинарных кавычках. Как в Lua, так и в MsgPack строки рассматриваются как " -"двоичные данные без определения набора символов строки или преобразования " -"строки, кроме случаев :ref:`сортировки `. Таким образом, " -"обычно сортировка и сравнение строк выполняются побайтово, а дополнительные " -"правила сравнения символов не применяются. Например, числа упорядочены по их" -" положению на числовой прямой, поэтому 2345 больше, чем 500. Строки же " -"упорядочены сначала по кодировке первого байта, затем по кодировке второго " -"байта и так далее, таким образом, ``'2345'`` меньше ``'500'``. Пример: ``'A," -" B, C'``." +"collation rules applied. For example, numbers are ordered by their point on " +"the number line, so 2345 is greater than 500; meanwhile, strings are ordered" +" by the encoding of the first byte, then the encoding of the second byte, " +"and so on, so ``'2345'`` is less than ``'500'``. Example: ``'A, B, C'``." +msgstr "" +"**string**. Строка (string) представляет собой последовательность байтов " +"переменной длины. Обычно она записывается буквенно-цифровыми символами в " +"одинарных кавычках. Как Lua, так и MsgPack рассматривают строки как двоичные" +" данные, не пытаясь определить кодировку строки или как-то её преобразовать," +" кроме случаев, когда указаны необязательные :ref:`правила сравнения " +"символов `. Таким образом, обычно сортировка и сравнение " +"строк выполняются побайтово, а дополнительные правила сравнения символов не " +"применяются. Например, числа упорядочены по их положению на числовой прямой," +" поэтому 2345 больше, чем 500. Строки же упорядочены сначала по кодировке " +"первого байта, затем по кодировке второго байта и так далее, так что " +"``'2345'`` меньше ``'500'``. Пример: ``'A, B, C'``." msgid "" "**bin**. A bin (binary) value is not directly supported by Lua but there is " @@ -496,17 +529,26 @@ msgstr "" "\\67\"``." msgid "" -"**uuid**. Since version :doc:`2.4.1 `. The Tarantool uuid " -"type is stored as a MsgPack ext (Extension). Values with the uuid type are " -":ref:`Universally unique identifiers `. |br| Example: " -"64d22e4d-ac92-4a23-899a-e5934af5479." +"**uuid**. The Tarantool uuid type is used for :ref:`Universally Unique " +"Identifiers `. Since version :doc:`2.4.1 ` " +"Tarantool stores ``uuid`` values as a MsgPack ext (Extension)." msgstr "" +"**uuid**. Тип uuid в Tarantool используется для :ref:`универсальных " +"уникальных идентификаторов (UUID) `. Начиная с версии " +":doc:`2.4.1 ` Tarantool хранит значения ``uuid`` в формате " +"MsgPack ext (Extension)." + +msgid "Example: ``64d22e4d-ac92-4a23-899a-e5934af5479``." +msgstr "Пример: ``64d22e4d-ac92-4a23-899a-e5934af5479``." msgid "" "**array**. An array is represented in Lua with ``{...}`` (`braces " -"`_). Examples: as lists of numbers " -"representing points in a geometric figure: ``{10, 11}``, ``{3, 5, 9, 10}``." +"`_). Examples: lists of numbers " +"representing points in geometric figures: ``{10, 11}``, ``{3, 5, 9, 10}``." msgstr "" +"**array**. В Lua массив (array) обозначается ``{...}`` (`фигурными скобками " +"`_). Примеры: списки чисел, которые " +"обозначают точки геометрической фигуры: ``{10, 11}``, ``{3, 5, 9, 10}``." msgid "" "**table**. Lua tables with string keys are stored as MsgPack maps; Lua " @@ -534,23 +576,22 @@ msgstr "" "кортежами см. в разделе :ref:`box.tuple `." msgid "" -"**scalar**. Values in a scalar field can be boolean or integer or unsigned " -"or double or number or decimal or string or varbinary -- but not array or " -"map or tuple. Examples: ``true``, ``1``, ``'xxx'``." +"**scalar**. Values in a scalar field can be boolean, integer, unsigned, " +"double or number, decimal, string, uuid, or varbinary; but not array, map, " +"or tuple. Examples: ``true``, ``1``, ``'xxx'``." msgstr "" -"**scalar**. Значения в поле scalar могут быть типа boolean, или integer, или" -" unsigned, или double, или number, или decimal, или string, или varbinary, " -"но не array, map или tuple. Примеры: ``true``, ``1``, ``'xxx'``." +"**scalar**. Значения в поле scalar могут быть типа boolean, integer, " +"unsigned, double, number, decimal, string, uuid или varbinary, но не могут " +"быть типа array, map или tuple. Примеры: ``true``, ``1``, ``'xxx'``." msgid "" -"**any**. Values in an any field can be boolean or integer or unsigned or " -"double or number or decimal or string or varbinary -- or array or map or " -"tuple. Examples: ``true``, ``1``, ``'xxx'``, ``{box.NULL, 0}``." +"**any**. Values in a field of this type can be boolean, integer, unsigned, " +"double or number, decimal, string, uuid, varbinary, array, map, or tuple. " +"Examples: ``true``, ``1``, ``'xxx'``, ``{box.NULL, 0}``." msgstr "" -"**any**. Значения в поле any могут быть типа boolean, или integer, или " -"unsigned, или double, или number, или decimal, или string, или varbinary, " -"или array, или map, или tuple. Примеры: ``true``, ``1``, ``'xxx'``, " -"``{box.NULL, 0}``." +"**any**. Значения в поле any могут быть типа boolean, integer, unsigned, " +"double, number, decimal, string, uuid, varbinary, array, map или tuple. " +"Примеры: ``true``, ``1``, ``'xxx'``, ``{box.NULL, 0}``." msgid "Examples of insert requests with different field types:" msgstr "Примеры запросов вставки с разными типами полей:" @@ -586,18 +627,18 @@ msgid "Indexed field types" msgstr "Типы индексированных полей" msgid "" -"Indexes restrict values which Tarantool may store with MsgPack. This is why," -" for example, ``'unsigned'`` and ``'integer'`` are different field types " -"although in MsgPack they are both stored as integer values -- an " -"``'unsigned'`` index contains only *non-negative* integer values while an " +"Indexes restrict values that Tarantool can store with MsgPack. This is why, " +"for example, ``'unsigned'`` and ``'integer'`` are different field types, " +"although in MsgPack they are both stored as integer values. An " +"``'unsigned'`` index contains only *non-negative* integer values, while an " "``‘integer’`` index contains *any* integer values." msgstr "" "Индексы ограничивают значения, которые Tarantool может хранить в формате " -"MsgPack. Вот зачем, например, нужны отдельные типы полей ``'unsigned'`` и " -"``'integer'``: хотя в MsgPack оба содержат целочисленные значения, но индекс" -" типа ``'unsigned'`` содержит только *неотрицательные* целочисленные " -"значения, а индекс типа ``'integer'`` содержит *любые* целочисленные " -"значения." +"MsgPack. Вот почему, например, есть отдельные типы полей ``'unsigned'`` " +"(число без знака) и ``'integer'`` (целое число), хотя в MsgPack они оба " +"хранятся как целочисленные значения. Индекс типа ``'unsigned'`` содержит " +"только *неотрицательные* целочисленные значения, а индекс типа ``'integer'``" +" содержит *любые* целочисленные значения." msgid "" "Here again are the field types described in :ref:`Field Type Details " @@ -638,24 +679,25 @@ msgstr ":ref:`TREE или HASH `" msgid "``'integer'`` (may also be called ‘int’)" msgstr "``'integer'`` (также может называться ‘int’)" -msgid ":ref:`integer ` which may include unsigned values" +msgid ":ref:`integer `, which may include unsigned values" msgstr "" -":ref:`integer `, может включать в себя беззнаковые " -"значения unsigned" +":ref:`integer `, может включать в себя значения unsigned " +"(без знака)" msgid "TREE or HASH" msgstr "TREE или HASH" msgid "" -"``'unsigned'`` (may also be called ‘uint’ or ‘num’, but ‘num’ is deprecated)" +"``'unsigned'`` (may also be called ``'uint'`` or ``'num'``, but ``'num'`` is" +" deprecated)" msgstr "" -"``'unsigned'`` (также может называться ‘uint’ или ‘num’, но ‘num’ объявлен " -"устаревшим)" +"``'unsigned'`` (без знака, также может называться ``'uint'`` или ``'num'``, " +"но ``'num'`` объявлен устаревшим)" msgid ":ref:`unsigned `" msgstr ":ref:`unsigned `" -msgid "TREE, BITSET or HASH" +msgid "TREE, BITSET, or HASH" msgstr "TREE, BITSET или HASH" msgid "``'double'``" @@ -668,7 +710,7 @@ msgid "``'number'``" msgstr "``'number'``" msgid "" -":ref:`number ` which may include :ref:`integer `, which may include :ref:`integer ` or :ref:`double ` values" msgstr "" ":ref:`number `, может включать в себя значения типа " @@ -680,8 +722,8 @@ msgstr "``'decimal'``" msgid ":ref:`decimal `" msgstr ":ref:`decimal `" -msgid "``'string'`` (may also be called ``‘str’``)" -msgstr "``'string'`` (также может называться ``‘str’``)" +msgid "``'string'`` (may also be called ``'str'``)" +msgstr "``'string'`` (строка, также может называться ``'str'``)" msgid ":ref:`string `" msgstr ":ref:`string `" @@ -692,8 +734,8 @@ msgstr "``'varbinary'``" msgid ":ref:`varbinary `" msgstr ":ref:`varbinary `" -msgid "TREE, HASH or BITSET (since version 2.7)" -msgstr "" +msgid "TREE, HASH, or BITSET (since version 2.7)" +msgstr "TREE, HASH или BITSET (с версии 2.7)" msgid "``'uuid'``" msgstr "``'uuid'``" @@ -714,17 +756,16 @@ msgid "``'scalar'``" msgstr "``'scalar'``" msgid "" -"may include :ref:`nil ` or :ref:`boolean `" -" or :ref:`integer ` or :ref:`unsigned ` or :ref:`number ` or :ref:`decimal ` or :ref:`string ` or :ref:`varbinary ` values" +"may include :ref:`nil `, :ref:`boolean `, " +":ref:`integer `, :ref:`unsigned `, " +":ref:`number `, :ref:`decimal `, " +":ref:`string `, or :ref:`varbinary ` values" msgstr "" -"может содержания значения :ref:`nil `, или :ref:`boolean " -"`, или :ref:`integer `, или " -":ref:`unsigned `, или :ref:`number `, " -"или :ref:`decimal `, или :ref:`string `, или :ref:`varbinary `" +"может содержать значения :ref:`nil `, :ref:`boolean `, :ref:`integer `, :ref:`unsigned `, :ref:`number `, :ref:`decimal `, :ref:`string ` или :ref:`varbinary `" msgid "" "When a scalar field contains values of different underlying types, the key " @@ -738,33 +779,37 @@ msgid "Collations" msgstr "Сортировка" msgid "" -"By default, when Tarantool compares strings, it uses what we call a " -"**\"binary\" collation**. The only consideration here is the numeric value " -"of each byte in the string. Therefore, if the string is encoded with ASCII " -"or UTF-8, then ``'A' < 'B' < 'a'``, because the encoding of ``'A'`` (what " -"used to be called the \"ASCII value\") is 65, the encoding of ``'B'`` is 66," -" and the encoding of ``'a'`` is 98. Binary collation is best if you prefer " -"fast deterministic simple maintenance and searching with Tarantool indexes." +"By default, when Tarantool compares strings, it uses the so-called **binary " +"collation**. It only considers the numeric value of each byte in a string. " +"For example, the encoding of ``'A'`` (what used to be called the \"ASCII " +"value\") is 65, the encoding of ``'B'`` is 66, and the encoding of ``'a'`` " +"is 98. Therefore, if the string is encoded with ASCII or UTF-8, then ``'A' <" +" 'B' < 'a'``." msgstr "" -"Когда Tarantool сравнивает строки, по умолчанию он использует так называемую" -" **\"двоичную\" сортировку**. Единственный фактор, который учитывается, — " -"это числовое значение каждого байта в строке. Таким образом, если строка " -"кодируется по ASCII или UTF-8, то ``'A' < 'B' < 'a'``, поскольку кодировка " -"``'A'`` (раньше называлась \"значение ASCII\") соответствует 65, ``'B'``— " -"66, а ``'a'`` — 98. Двоичная сортировка лучше всего подходит для быстрого " -"детерминированного простого обслуживания и поиска с помощью индексов " -"Tarantool." +"Когда Tarantool сравнивает строки, по умолчанию он использует **двоичные " +"параметры сортировки** (**binary collation**). При этом он учитывает только " +"числовое значение каждого байта в строке. Например, код символа ``'A'`` " +"(раньше называлась \"значение ASCII\") — число 65, код ``'B'`` — число 66, а" +" код ``'a'`` -- число 98. Поэтому ``'A' < 'B' < 'a'``, если строка " +"закодирована в ASCII или UTF-8." + +msgid "" +"Binary collation is the best choice for fast deterministic simple " +"maintenance and searching with Tarantool indexes." +msgstr "" +"Двоичная сортировка — лучший выбор для быстрого детерминированного простого " +"обслуживания и поиска с использованием индексов Tarantool." msgid "" "But if you want the ordering that you see in phone books and dictionaries, " "then you need Tarantool's optional collations, such as ``unicode`` and " -"``unicode_ci``, which allow for ``'a' < 'A' < 'B'`` and ``'a' = 'A' < 'B'`` " -"respectively." +"``unicode_ci``, which allow for ``'a' < 'A' < 'B'`` and ``'a' == 'A' < 'B'``" +" respectively." msgstr "" -"Если же необходимо такое упорядочение, как в телефонных справочниках и " -"словарях, то вам нужна дополнительная сортировка Tarantool — ``unicode`` или" -" ``unicode_ci`` — которые обеспечивают ``'a' < 'A' < 'B'`` и ``'a' = 'A' < " -"'B'`` соответственно." +"Но если вы хотите такое упорядочение, как в телефонных справочниках и " +"словарях, то вам нужна одна из дополнительных сортировок Tarantool: " +"``unicode`` или ``unicode_ci``. Они обеспечивают ``'a' < 'A' < 'B'`` и ``'a'" +" == 'A' < 'B'`` соответственно." msgid "" "**The unicode and unicode_ci optional collations** use the ordering " @@ -786,18 +831,18 @@ msgstr "" "`_:" msgid "" -"``unicode`` collation observes L1 and L2 and L3 weights (strength = " -"'tertiary')," +"``unicode`` collation observes L1, L2, and L3 weights (strength = " +"'tertiary');" msgstr "" "сортировка ``unicode`` принимает во внимание уровни веса L1, L2 и L3 " -"(уровень = 'tertiary', третичный)," +"(уровень = 'tertiary', третичный);" msgid "" "``unicode_ci`` collation observes only L1 weights (strength = 'primary'), so" -" for example 'a' = 'A' = 'á' = 'Á'." +" for example ``'a' == 'A' == 'á' == 'Á'``." msgstr "" "сортировка ``unicode_ci`` принимает во внимание только вес L1 (уровень = " -"'primary', первичный), поэтому, например, 'a' = 'A' = 'á' = 'Á'." +"'primary', первичный), поэтому, например, ``'a' == 'A' == 'á' == 'Á'``." msgid "As an example, take some Russian words:" msgstr "Для примера возьмем некоторые русские слова:" @@ -921,31 +966,35 @@ msgstr "" "правила для комбинаций символов." msgid "" -"For English: use \"unicode\" and \"unicode_ci\". For Russian: use " -"\"unicode\" and \"unicode_ci\" (although a few Russians might prefer the " -"Kyrgyz collation which says Cyrillic letters 'Е' and 'Ё' are the same with " -"level-1 weights). For Dutch, German (dictionary), French, Indonesian, Irish," -" Italian, Lingala, Malay, Portuguese, Southern Soho, Xhosa, or Zulu: " -"\"unicode\" and \"unicode_ci\" will do." +"For English, Russian, and most other languages and use cases, use the " +"\"unicode\" and \"unicode_ci\" collations. If you need Cyrillic letters 'Е' " +"and 'Ё' to have the same level-1 weights, try the Kyrgyz collation." msgstr "" -"Для английского языка используйте \"unicode\" и \"unicode_ci\". Для русского" -" языка используйте \"unicode\" и \"unicode_ci\" (хотя некоторые русские, " -"возможно, предпочтут киргизскую сортировку, в которой совпадают " -"кириллические буквы 'Е' и 'Ё' с весом 1 уровня). Для голландского, немецкого" -" (словарь), французского, индонезийского, ирландского, итальянского, " -"лингальского, малайского, португальского, сесото, коса или зулу подойдут " -"\"unicode\" и \"unicode_ci\"." +"Для английского, русского и большинства других языков используйте " +"\"unicode\" и \"unicode_ci\". Если вам нужно, чтобы у кириллических букв 'Е'" +" и 'Ё' веса 1 уровня были одинаковыми, попробуйте киргизскую сортировку." msgid "" -"**The tailored optional collations**: For other languages, Tarantool " +"**The tailored optional collations**: for other languages, Tarantool " "supplies tailored collations for every modern language that has more than a " "million native speakers, and for specialized situations such as the " -"difference between dictionary order and telephone book order. To see a " -"complete list say ``box.space._collation:select()``. The tailored collation " -"names have the form unicode_[language code]_[strength] where language code " -"is a standard 2-character or 3-character language abbreviation, and strength" -" is s1 for \"primary strength\" (level-1 weights), s2 for \"secondary\", s3 " -"for \"tertiary\". Tarantool uses the same language codes as the ones in the " +"difference between dictionary order and telephone book order. Run " +"``box.space._collation:select()`` to see the complete list." +msgstr "" +"**Специализированные дополнительные виды сортировки**: Для других языков " +"Tarantool предлагает специализированные виды сортировки для любого " +"современного языка, на котором говорят более миллиона человек. Кроме того, " +"специализированные дополнительные виды сортировки возможны для особых " +"случаев, когда слова в словаре упорядочиваются не так, как в телефонном " +"справочнике. Чтобы увидеть полный список, выполните команду " +"``box.space._collation:select()``." + +msgid "" +"The tailored collation names have the form ``unicode_[language " +"code]_[strength]``, where language code is a standard 2-character or " +"3-character language abbreviation, and strength is ``s1`` for \"primary " +"strength\" (level-1 weights), ``s2`` for \"secondary\", ``s3`` for " +"\"tertiary\". Tarantool uses the same language codes as the ones in the " "\"list of tailorable locales\" on man pages of `Ubuntu " "`_" " and `Fedora " @@ -954,23 +1003,18 @@ msgid "" "`Common Language Data Repository " "`_." msgstr "" -"**Специализированные дополнительные виды сортировки**: Что касается других " -"языков, Tarantool предлагает специализированные виды сортировки для любого " -"современного языка, на котором говорят более миллиона человек, а также для " -"особых случаев, отличных от сортировки в словарном порядке и по примеру " -"телефонного справочника. Чтобы увидеть полный список, выполните команду " -"``box.space._collation:select()``. Названия специализированных видов " -"сортировки составлены по форме unicode_[language code]_[strength], где " -"language code — это стандартный код языка из 2 или 3 символов, а значение " -"strength может быть s1 для уровня \"primary\" (вес уровня 1), s2 для уровня " -"\"secondary\", s3 для уровня \"tertiary\". Tarantool использует те же коды " -"языка, которые указаны в списке специализированных вариантов языковых " -"настроек на страницах справочников по `Ubuntu " +"Названия специализированных видов сортировки имеют вид ``unicode_[language " +"code]_[strength]``], где language code — это стандартный код языка из 2 или " +"3 символов, а значение strength может быть ``s1`` для уровня \"primary\" " +"(вес уровня 1), ``s2`` для уровня \"secondary\", ``s3`` для уровня " +"\"tertiary\". Tarantool использует те же коды языков, что указаны в списке " +"специализированных вариантов языковых настроек на страницах руководств по " +"`Ubuntu " "`_" " и `Fedora " "`_." -" Схемы с объяснением отличий от упорядочения по DUCET можно найти по ссылке " -"`Common Language Data Repository " +" Схемы, в деталях объясняющие отличия от упорядочения по DUCET, можно найти " +"в `Общем репозитории языковых данных (Common Language Data Repository) " "`_." msgid "Sequences" @@ -981,13 +1025,12 @@ msgstr "" "**Последовательность** -- это генератор упорядоченных значений целых чисел." msgid "" -"As with spaces and indexes, you should specify the sequence **name**, and " -"let Tarantool come up with a unique **numeric identifier** (\"sequence " -"id\")." +"As with spaces and indexes, you should specify the sequence **name** and let" +" Tarantool generate a unique numeric identifier (sequence ID)." msgstr "" -"Как и для спейсов и индексов, для последовательностей следует указать " -"**имена**, а Tarantool определит уникальный **числовой идентификатор** (\"ID" -" последовательности\")." +"Как и для спейсов и индексов, для последовательности вы должны указать " +"**имя**, а Tarantool создаст уникальный для неё числовой идентификатор (\"ID" +" последовательности)." msgid "" "As well, you can specify several options when creating a new sequence. The " @@ -998,8 +1041,8 @@ msgstr "" "последовательности. Параметры определяют, какое значение будет " "генерироваться при использовании последовательности." -msgid "Options for ``box.schema.sequence.create()``" -msgstr "Параметры для ``box.schema.sequence.create()``" +msgid "Options for box.schema.sequence.create()" +msgstr "Параметры для box.schema.sequence.create()" msgid "Option name" msgstr "Имя параметра" @@ -1171,11 +1214,11 @@ msgstr "" "составит 6) и так далее." msgid "" -"Then we create a new table, and say that its primary key may be generated " -"from the sequence." +"Then we create a new table and specify that its primary key should be " +"generated from the sequence." msgstr "" -"Затем создадим новую таблицу и скажем, что ее первичный ключ можно получить " -"из последовательности." +"Затем мы создаём новую таблицу и определяем, что ее первичный ключ должен " +"быть получен из последовательности." msgid "" "tarantool> s=box.schema.space.create('T')\n" @@ -1218,9 +1261,8 @@ msgstr "" "---\n" "..." -msgid "" -"Then we insert a tuple, without specifying a value for the primary key." -msgstr "Затем вставим кортеж, не указывая значение первичного ключа." +msgid "Then we insert a tuple without specifying a value for the primary key." +msgstr "Затем вставляем кортеж, не указывая значение первичного ключа." msgid "" "tarantool> box.space.T:insert{nil,'other stuff'}\n" @@ -1255,59 +1297,59 @@ msgid "Persistence" msgstr "Персистентность" msgid "" -"In Tarantool, updates to the database are recorded in the so-called " -":ref:`write ahead log (WAL) ` files. This ensures data " -"persistence. When a power outage occurs or the Tarantool instance is killed " -"incidentally, the in-memory database is lost. In this situation, WAL files " -"are used to restore the data. Namely, Tarantool reads the WAL files and " -"redoes the requests (this is called the \"recovery process\"). You can " -"change the timing of the WAL writer, or turn it off, by setting " -":ref:`wal_mode `." +"To ensure data persistence, Tarantool records updates to the database in the" +" so-called :ref:`write-ahead log (WAL) ` files. When a power " +"outage occurs or the Tarantool instance is killed incidentally, the in-" +"memory database is lost. In such case, Tarantool restores the data from WAL " +"files by reading them and redoing the requests. This is called the " +"\"recovery process\". You can change the timing of the WAL writer or turn it" +" off by setting the :ref:`wal_mode `." msgstr "" -"В Tarantool обновления базы данных записываются в так называемые :ref:`файлы" -" журнала упреждающей записи (WAL-файлы) `. Это обеспечивает " -"персистентность данных. При отключении электроэнергии или случайном " -"завершении работы экземпляра Tarantool данные в оперативной памяти теряются." -" В такой ситуации WAL-файлы используются для восстановления данных так: " -"Tarantool cчитывает WAL-файлы и повторно выполняет запросы (это называется " -"\"процессом восстановления\"). Можно изменить интервалы записи WAL-файлов " -"или отключить запись с помощью :ref:`wal_mode `." +"Чтобы обеспечить персистентность данных, Tarantool записывает обновления " +"базы данных в так называемые :ref:`файлы журнала упреждающей записи (write-" +"ahead log, WAL) `. При отключении электроэнергии или " +"случайном завершении работы экземпляра Tarantool данные в оперативной памяти" +" теряются. В таком случае Tarantool восстанавливает данные из WAL-файлов, " +"повторно выполняя запросы, записанные в них. Это называется \"процесс " +"восстановления\". Можно настроить, как часто данные записываются в WAL-" +"файлы, или отключить запись совсем с помощью :ref:`wal_mode " +"`." msgid "" "Tarantool also maintains a set of :ref:`snapshot files `. These files contain an on-disk copy of the entire data set for a" " given moment. Instead of reading every WAL file since the databases were " "created, the recovery process can load the latest snapshot file and then " -"read only those WAL files that were produced after the snapshot file was " -"made. After checkpointing, old WAL files can be removed to free up space." -msgstr "" -"Tarantool также сохраняет ряд файлов со статическими снимками данных " -"(:ref:`snapshots `). Файл со снимком -- это дисковая " -"копия всех данных в базе на какой-то момент. Вместо того, чтобы зачитывать " -"все WAL-файлы, появившиеся с момента создания базы, Tarantool в процессе " -"восстановления может загрузить самый свежий снимок и затем зачитать только " -"те WAL-файлы, которые были сделаны с момента сохранения снимка. После " -"создания новых файлов, старые WAL-файлы могут быть удалены в целях экономии " -"места на диске." - -msgid "" -"To force immediate creation of a snapshot file, you can use Tarantool's " -":doc:`box.snapshot() ` request. To " -"enable automatic creation of snapshot files, you can use Tarantool's " -":ref:`checkpoint daemon `. The checkpoint daemon" -" sets intervals for forced checkpoints. It makes sure that the states of " -"both memtx and vinyl storage engines are synchronized and saved to disk, and" -" automatically removes old WAL files." -msgstr "" -"Чтобы принудительно создать файл со снимком, можно использовать запрос " -":doc:`box.snapshot() ` в Tarantool. " -"Чтобы включить автоматическое создание файлов со снимком, можно использовать" -" :ref:`демон создания контрольных точек ` " -"Tarantool. Демон создания контрольных точек определяет интервалы для " -"принудительного создания контрольных точек. Он обеспечивает синхронизацию и " -"сохранение на диск образов движков базы данных (как memtx, так и vinyl), а " -"также автоматически удаляет старые WAL-файлы." +"read the WAL files, produced after the snapshot file was made. After " +"creating a new snapshot, the earlier WAL files can be removed to free up " +"space." +msgstr "" +"Tarantool также сохраняет набор файлов со статическими снимками данных " +"(:ref:`snapshots `). Файл со снимком — это дисковая " +"копия всех данных в базе на какой-то момент. Вместо того, чтобы перечитывать" +" все WAL-файлы с момента создания базы, Tarantool в процессе восстановления " +"может загрузить самый свежий снимок и затем прочитать только те WAL-файлы, " +"которые были созданы начиная с момента сохранения снимка. После создания " +"новых снимков более ранние WAL-файлы могут быть удалены, чтобы освободить " +"место на диске." + +msgid "" +"To force immediate creation of a snapshot file, use the :doc:`box.snapshot()" +" ` function. To enable the automatic " +"creation of snapshot files, use Tarantool's :ref:`checkpoint daemon " +"`. The checkpoint daemon sets intervals for " +"forced checkpoints. It makes sure that the states of both memtx and vinyl " +"storage engines are synchronized and saved to disk, and automatically " +"removes earlier WAL files." +msgstr "" +"Чтобы принудительно создать файл снимка, используйте в Tarantool функцию " +":doc:`box.snapshot() `. Чтобы " +"включить автоматическое создание файлов снимков, используйте :ref:`демон " +"создания контрольных точек (checkpoint daemon) `" +" Tarantool. Этот демон определяет интервалы для принудительного создания " +"контрольных точек. Он обеспечивает синхронизацию и сохранение на диск " +"образов движков базы данных (как memtx, так и vinyl), а также автоматически " +"удаляет более ранние WAL-файлы." msgid "Snapshot files can be created even if there is no WAL file." msgstr "Файлы со снимками можно создавать, даже если WAL-файлы отсутствуют." @@ -1551,15 +1593,15 @@ msgstr "Размер индекса" msgid "" "The number of index keys is the same as the number of tuples in the data " "set. For a TREE index, if there are more keys, then the lookup time will be " -"greater, although of course the effect is not linear. For a HASH index, if " -"there are more keys, then there is more RAM used, but the number of low-" +"greater, although, of course, the effect is not linear. For a HASH index, if" +" there are more keys, then there is more RAM used, but the number of low-" "level steps tends to remain constant." msgstr "" -"Количество ключей в индексе равно количеству кортежей в наборе данных. В " -"случае с TREE-индексом: с ростом количества ключей увеличивается время " -"поиска, хотя зависимость здесь, конечно же, не линейная. В случае с HASH-" -"индексом: с ростом количества ключей увеличивается объем оперативной памяти," -" но количество низкоуровневых шагов остается примерно тем же." +"Количество ключей в индексе равно количеству кортежей в наборе данных. Для " +"TREE-индекса: чем больше ключей, тем больше время поиска, хотя зависимость " +"здесь, конечно же, нелинейная. Для HASH-индекса: чем больше ключей, тем " +"больше нужно оперативной памяти, но количество низкоуровневых шагов остается" +" примерно тем же." msgid "" "Typically, a HASH index is faster than a TREE index if the number of tuples " @@ -1580,24 +1622,25 @@ msgstr "" "индексов." msgid "" -"Note re storage engine: Vinyl optimizes away such accesses if secondary " -"index fields are unchanged by the update. So, this complexity factor applies" -" only to memtx, since it always makes a full-tuple copy on every update." +"Note regarding storage engine: Vinyl optimizes away such accesses if " +"secondary index fields are unchanged by the update. So, this complexity " +"factor applies only to memtx, since it always makes a full-tuple copy on " +"every update." msgstr "" -"Примечание по движку базы данных: Vinyl отклоняет такой доступ, если " -"обновление не затрагивает поля вторичного индекса. Таким образом, этот " -"фактор сложности влияет только на memtx, поскольку он всегда создает копию " -"всего кортежа при каждом обновлении." +"Примечание по движку базы данных: если обновление не затрагивает поля " +"вторичного индекса, vinyl не производит эти обращения. Таким образом, этот " +"фактор сложности влияет только на memtx, который создает копию всего кортежа" +" при каждом обновлении." msgid "Number of tuples accessed" msgstr "Количество обращений к кортежам" msgid "" -"A few requests, for example SELECT, can retrieve multiple tuples. This " +"A few requests, for example, SELECT, can retrieve multiple tuples. This " "factor is usually less important than the others." msgstr "" -"Некоторые запросы, например SELECT, могут возвращать несколько кортежей. Как" -" правило, это наименее важный фактор из всех." +"Некоторые запросы, например SELECT, могут возвращать несколько кортежей. " +"Обычно этот фактор менее важен, чем другие." msgid "WAL settings" msgstr "Настройки WAL" @@ -1697,21 +1740,22 @@ msgid "tarantool init.lua" msgstr "tarantool init.lua" msgid "" -"However, if you do not plan to dive deep into the Lua language and its " -"syntax, it may seem complicated." +"However, it may seem complicated if you do not plan to dive deep into the " +"Lua language and its syntax." msgstr "" -"Однако, если вы не планировали углубляться в знакомство с языком Lua и его " -"синтаксисом, это может показаться сложным." +"Но это может показаться слишком сложным, если вы не собираетесь глубоко " +"разбираться с языком Lua и его синтаксисом." msgid "" -"Possible difficulty: The snippet above has a function call with a colon: " -"``users:format``. It is used to pass the ``format`` variable as the first " +"Possible difficulty: the snippet above has a function call with a colon: " +"``users:format``. It is used to pass the ``users`` variable as the first " "argument of the ``format`` function. This is similar to ``self`` in object-" "based languages." msgstr "" -"Пример сложности: В сниппете выше есть вызов функций через двоеточие: " -"``users:format``. Он используется, чтобы передать первым аргументом функции " -"``format`` переменную ``users``. Это аналог ``self`` в языках ООП." +"Пример возможной сложности: в фрагменте выше есть вызов функций с " +"двоеточием: ``users:format``. Он используется, чтобы передать переменную " +"``users`` в качестве первого аргумента функции ``format``. Это аналог " +"``self`` в объектно-ориентированных языках." msgid "" "So it might be more convenient for you to describe the data schema with " @@ -1900,10 +1944,10 @@ msgid "Other types of migrations" msgstr "Остальные виды миграций" msgid "" -"Other types of migrations are also allowed but it would be more difficult to" -" maintain data consistency." +"Other types of migrations are also allowed, but it would be more difficult " +"to maintain data consistency." msgstr "" -"Остальные виды миграций также возможны, однако сохранить консистентность " +"Остальные виды миграций также возможны, однако поддерживать консистентность " "данных при этом сложнее." msgid "Migrations are possible in two cases:" @@ -1939,11 +1983,11 @@ msgid "" msgstr "Нужно уметь отдавать данные как по новой схеме, так и по старой." msgid "" -"When data is being transferred to a new space, data access should take into " -"account that the data might be in one space or another." +"When data is being transferred to a new space, data access should consider " +"that the data might be in one space or another." msgstr "" -"При перекладывании данных в новый спейс доступ к данным должен учитывать, " -"что данные могут быть или в одном или в другом спейсе." +"Когда данные перемещают в новый спейс, доступ к данным должен учитывать, что" +" данные могут быть как в одном спейсе, так и в другом." msgid "" "Write requests must not interfere with the migration. A common approach is " @@ -1994,13 +2038,13 @@ msgstr "**Способ 1**: написать миграции в коде осн msgid "" "This is quite simple: when you reload the code, the data is migrated at the " "right moment, and the database schema is updated. However, this method may " -"not work for everyone. You may not be able to restart Tarantool or to update" -" the code using the hot-reload mechanism." +"not work for everyone. You may not be able to restart Tarantool or update " +"the code using the hot-reload mechanism." msgstr "" -"Тут все просто: при перезагрузке кода произойдет миграция данных в нужный " -"момент и схема данных БД обновится. Однако такой способ может подойти не " -"всем. У вас может не быть возможности перезапустить Tarantool или обновить " -"код через механизм горячей перезагрузки (hot reload)." +"Это довольно просто: когда вы перезагружаете код, в нужный момент происходит" +" миграция данных и схема базы данных обновляется. Однако такой способ может " +"подойти не всем. У вас может не быть возможности перезапустить Tarantool или" +" обновить код через механизм горячей перезагрузки (hot reload)." msgid "" "**Method 2**: tarantool/migrations (only for a Tarantool Cartridge cluster)" @@ -2016,11 +2060,11 @@ msgstr "" "`tarantool/migrations `_." msgid "" -"There are also two methods that we **do not recommend** but you may find " -"them useful for one reason or another." +"There are also two other methods that we **do not recommend**, but you may " +"find them useful for one reason or another." msgstr "" -"Есть также способы, которые мы **не рекомендуем использовать**, но они могут" -" вам пригодиться по тем или иным причинам." +"Есть также два способа, которые мы **не рекомендуем использовать**, но вы " +"можете найти их полезными по тем или иным причинам." msgid "**Method 3**: the ``tarantoolctl`` utility" msgstr "**Cпособ 3**: утилита ``tarantoolctl``" @@ -2063,13 +2107,13 @@ msgid "**Method 4**: applying migration with Ansible" msgstr "**Способ 4**: применение миграции с помощью Ansible" msgid "" -"If you use an `Ansible role to deploy a Tarantool cluster " -"`_, you can use ``eval``. " -"You can find more information about ``eval`` `here " +"If you use the `Ansible role `_ to deploy a Tarantool cluster, you can use ``eval``. You can " +"find more information about it `in the Ansible role documentation " "`_." msgstr "" -"Если вы используете `Ansible роль для деплоя кластера Tarantool " -"`_, то вы можете " -"воспользоваться инструментом ``eval``. Прочитать подробнее про ``eval`` " -"можно `тут `_, то вы можете применить " +"``eval``. Прочитать подробнее про ``eval`` можно `в документации по Ansible-" +"роли `_." diff --git a/locale/ru/LC_MESSAGES/book/replication/repl_leader_elect.po b/locale/ru/LC_MESSAGES/book/replication/repl_leader_elect.po index 593c5a114f..58b1de41bc 100644 --- a/locale/ru/LC_MESSAGES/book/replication/repl_leader_elect.po +++ b/locale/ru/LC_MESSAGES/book/replication/repl_leader_elect.po @@ -48,7 +48,7 @@ msgstr "" "реализованы как две независимые подсистемы. Это означает, что можно " "настроить синхронную репликацию, а для выборов лидера использовать " "альтернативный алгоритм. Встроенный механизм выборов лидера, в свою очередь," -" не требует использования синхронных спейсов. Синхронной репликации посвящён" +" не требует использования синхронных спейсов. Синхронной репликации посвящен" " :ref:`этот раздел документации `. Процесс выборов лидера описан " "ниже." @@ -74,7 +74,7 @@ msgid "" "term and starts a new leader election round." msgstr "" "Когда :ref:`функция выборов включена `, жизненный " -"цикл набора реплик разделён на так называемые *термы* (term). Каждый терм " +"цикл набора реплик разделен на так называемые *термы* (term). Каждый терм " "описывается монотонно растущим числом. После первой загрузки узла значение " "его терма равно 1. Когда узел обнаруживает, что не является лидером и при " "этом лидера в наборе реплик уже какое-то время нет, он увеличивает значение " @@ -88,7 +88,7 @@ msgid "" msgstr "" "Выборы лидера происходят посредством голосования. Узел, начинающий выборы, " "голосует сам за себя и отправляет другим запросы на голос. Каждый экземпляр " -"голосует за первый узел, от которого пришёл такой запрос, и далее в течение " +"голосует за первый узел, от которого пришел такой запрос, и далее в течение " "всего терма ожидает избрания лидера, не выполняя никаких действий." msgid "" @@ -140,7 +140,7 @@ msgid "" " This is needed because election messages for voting and other internal " "things need direct connection between the nodes." msgstr "" -"Необходимо, чтобы все узлы, :ref:`включённые в процесс выборов " +"Необходимо, чтобы все узлы, :ref:`включенные в процесс выборов " "`, были соединены попарно и образовывали полную " "ячеистую топологию (full mesh). Для передачи запросов, связанных с " "голосованием, и других внутренних сообщений требуется прямая связь между " @@ -154,7 +154,7 @@ msgid "" msgstr "" "Любой узел, участвующий в процессе выборов, реплицирует данные только с " "последнего избранного лидера. Это позволяет избежать ситуации, в которой " -"прежний лидер после выборов нового всё ещё пытается отправлять изменения на " +"прежний лидер после выборов нового все еще пытается отправлять изменения на " "реплики." msgid "" @@ -201,7 +201,7 @@ msgid "" ":ref:`option description ` in the " "configuration reference." msgstr "" -"``election_timeout`` — задаёт промежуток времени между турами в случае " +"``election_timeout`` — задает промежуток времени между турами в случае " "разделения голосов и последующих перевыборов. Подробное :ref:`описание " "параметра ` приводится в справочнике по " "настройке." @@ -256,7 +256,7 @@ msgstr "" "условие, заданное параметром :ref:`replication_connect_quorum " "` " "(``box.cfg{replication_connect_quorum = }``), или же этот параметр " -"должен быть отключён (``box.cfg{replication_connect_quorum = 0}``)." +"должен быть отключен (``box.cfg{replication_connect_quorum = 0}``)." msgid "" "Nothing prevents from setting the ``read_only`` option to ``true``, but the " diff --git a/locale/ru/LC_MESSAGES/book/replication/repl_sync.po b/locale/ru/LC_MESSAGES/book/replication/repl_sync.po index 273b385c12..cf15ba3975 100644 --- a/locale/ru/LC_MESSAGES/book/replication/repl_sync.po +++ b/locale/ru/LC_MESSAGES/book/replication/repl_sync.po @@ -1,6 +1,6 @@ msgid "Synchronous replication" -msgstr "" +msgstr "Синхронная репликация" msgid "Overview" msgstr "Общие сведения" @@ -12,12 +12,20 @@ msgid "" "after failover to a replica, from the client's point of view the transaction" " will disappear." msgstr "" +"По умолчанию репликация в Tarantool **асинхронная**: локальный коммит " +"транзакции на мастере не означает, что эта транзакция будет сразу же " +"выполнена на репликах. Если мастер сообщит клиенту об успешном выполнении " +"операции, а потом прекратит работу и после отказа восстановится на реплике, " +"то с точки зрения клиента транзакция пропадет." msgid "" "**Synchronous** replication exists to solve this problem. Synchronous " "transactions are not considered committed and are not responded to a client " "until they are replicated onto some number of replicas." msgstr "" +"Эту проблему решает **синхронная** репликация. Каждая синхронная транзакция " +"проходит коммит лишь после репликации на некотором количестве экземпляров, и" +" только тогда клиенту приходит ответ о завершении транзакции." msgid "Usage" msgstr "Использование" @@ -26,29 +34,40 @@ msgid "" "Since version :doc:`2.5.1 `, synchronous replication can be " "enabled per-space by using the ``is_sync`` option:" msgstr "" +"Начиная с версии Tarantool :doc:`2.5.1 `, синхронную " +"репликацию можно включать для отдельных спейсов, используя параметр " +"``is_sync``:" msgid "box.schema.create_space('test1', {is_sync = true})" -msgstr "" +msgstr "box.schema.create_space('test1', {is_sync = true})" msgid "" "Any transaction doing a DML request on this space becomes synchronous. " "Notice that DDL on this space (including truncation) is **not** synchronous." msgstr "" +"Все транзакции, где выполняются DML-запросы к такому спейсу, становятся " +"синхронными. Обратите внимание, что транзакции, где содержатся DDL-операции," +" в том числе запросы на очистку (truncate), синхронными **не будут**." msgid "" "To control the behavior of synchronous transactions, there exist global " "``box.cfg`` :ref:`options `:" msgstr "" +"Управлять поведением синхронных транзакций можно с помощью глобальных " +":ref:`параметров ` ``box.cfg``:" msgid "box.cfg{replication_synchro_quorum = }" -msgstr "" +msgstr "box.cfg{replication_synchro_quorum = <количество экземпляров>}" msgid "" "This option tells how many replicas should confirm the receipt of a " -"synchronous transaction before it can finish its commit. So far this option " -"accounts all replicas, including anonymous. As a usage example, consider " +"synchronous transaction before it is committed. So far, this option accounts" +" for all replicas including anonymous ones. As a usage example, consider " "this:" msgstr "" +"Параметр указывает, сколько реплик должно подтвердить получение синхронной " +"транзакции, прежде чем она пройдет коммит. Учитываются все реплики, включая " +"анонимные. Пример:" msgid "" "-- Instance 1\n" @@ -60,6 +79,14 @@ msgid "" "_ = box.schema.space.create('sync', {is_sync=true})\n" "_ = _:create_index('pk')" msgstr "" +"-- Экземпляр 1\n" +"box.cfg{\n" +" listen = 3313,\n" +" replication_synchro_quorum = 2,\n" +"}\n" +"box.schema.user.grant('guest', 'super')\n" +"_ = box.schema.space.create('sync', {is_sync=true})\n" +"_ = _:create_index('pk')" msgid "" "-- Instance 2\n" @@ -68,11 +95,18 @@ msgid "" " replication = 'localhost:3313'\n" "}" msgstr "" +"-- Экземпляр 2\n" +"box.cfg{\n" +" listen = 3314,\n" +" replication = 'localhost:3313'\n" +"}" msgid "" "-- Instance 1\n" "box.space.sync:replace{1}" msgstr "" +"-- Экземпляр 1\n" +"box.space.sync:replace{1}" msgid "" "When the first instance makes ``replace()``, it won't finish until the " @@ -81,16 +115,25 @@ msgid "" "there is only one replica. This is because the master instance itself also " "participates in the quorum." msgstr "" +"Операция ``replace()``, вызванная на первом экземпляре, не будет " +"завершена, пока второй экземпляр не подтвердит получение и успешное " +"применение транзакции. Обратите внимание, что кворум равен 2, а реплика " +"одна, но транзакция все же успешно проходит коммит. Это происходит " +"потому, что мастер также участвует в кворуме." msgid "" -"Now if the second instance is down, the first one won't be able to commit " +"Now, if the second instance is down, the first one won't be able to commit " "any synchronous change." msgstr "" +"Если второй экземпляр прекратит работу, первый не сможет выполнять коммиты " +"для синхронных изменений." msgid "" "-- Instance 2\n" "Ctrl+D" msgstr "" +"-- Экземпляр 2\n" +"Ctrl+D" msgid "" "-- Instance 1\n" @@ -99,103 +142,156 @@ msgid "" "- error: Quorum collection for a synchronous transaction is timed out\n" "..." msgstr "" +"-- Экземпляр 1\n" +"tarantool> box.space.sync:replace{2}\n" +"---\n" +"- error: Quorum collection for a synchronous transaction is timed out\n" +"..." msgid "" "The transaction wasn't committed because it failed to achieve the quorum in " "the given time. The time is a second configuration option:" msgstr "" +"Транзакция не прошла коммит, поскольку за определенное время не был набран " +"кворум. Время — ещё один параметр конфигурации:" msgid "" "box.cfg{replication_synchro_timeout = }" msgstr "" +"box.cfg{replication_synchro_timeout = <время в секундах; может иметь тип " +"float>}" msgid "" "It tells how many seconds to wait for a synchronous transaction quorum " "replication until it is declared failed and is rolled back." msgstr "" +"Параметр указывает, сколько секунд синхронная транзакция будет ожидать " +"репликации на кворуме. По истечении этого времени транзакция будет отменена." msgid "" "A successful synchronous transaction commit is persisted in the WAL as a " "special CONFIRM record. The rollbacks are similarly persisted with a " "ROLLBACK record." msgstr "" +"Успешные коммиты синхронных транзакций персистентно сохраняются в журнал " +"упреждающей записи (WAL) в виде особых записей CONFIRM. Сообщения об отмене " +"транзакций сохраняются аналогичным образом в виде записей ROLLBACK." msgid "" "The ``timeout`` and ``quorum`` options are not used on replicas. It means if" " the master dies, the pending synchronous transactions will be kept waiting " "on the replicas until a new master is elected." msgstr "" +"Параметры ``timeout`` и ``quorum`` на репликах не используются. Если мастер " +"прекратит работу, синхронные транзакции, которые находятся в обработке на " +"репликах, будут ожидать выборов нового мастера." msgid "Synchronous and asynchronous transactions" -msgstr "" +msgstr "Синхронные и асинхронные транзакции" msgid "" "A killer feature of Tarantool's synchronous replication is its being *per-" "space*. So, if you need it only rarely for some critical data changes, you " "won't pay for it in performance terms." msgstr "" +"В Tarantool синхронную репликацию можно настроить для отдельных спейсов. Эта" +" удобная функция позволит вам не потерять в производительности, если " +"синхронная репликация нужна вам лишь изредка для изменения критически важных" +" данных." msgid "" "When there is more than one synchronous transaction, they all wait for being" " replicated. Moreover, if an asynchronous transaction appears, it will also " "be blocked by the existing synchronous transactions. This behavior is very " "similar to a regular queue of asynchronous transactions because all the " -"transactions finish their commits in the same order as they start them. So, " -"here comes **the commit rule**: transactions always finish their commits in " -"the same order as they start them -- regardless of being synchronous or " -"asynchronous." -msgstr "" +"transactions are committed in the same order as they make the " +"``box.commit()`` call. So, here comes **the commit rule**: transactions are " +"committed in the same order as they make the ``box.commit()`` " +"call—regardless of being synchronous or asynchronous." +msgstr "" +"Если наряду с несколькими синхронными транзакциями, ожидающими репликации, " +"совершается асинхронная транзакция, она блокируется синхронными. Коммиты при" +" этом выполняются в той последовательности, в которой для каждой из " +"транзакций вызывается метод ``box.commit()``. Похожим образом работает " +"обычная очередь асинхронных транзакций. Можно сформулировать **правило " +"коммитов**: порядок коммитов соответствует порядку вызова ``box.commit()`` " +"для каждой из транзакций, независимо от того, синхронные транзакции или " +"асинхронные." msgid "" "If one of the waiting synchronous transactions times out and is rolled back," " it will first roll back all the newer pending transactions. Again, just " "like how asynchronous transactions are rolled back when WAL write fails. So," " here comes **the rollback rule:** transactions are always rolled back in " -"the order reversed from the commit start order -- regardless of being " -"synchronous or asynchronous." +"the order reversed from the one they make the ``box.commit()`` " +"call—regardless of being synchronous or asynchronous." msgstr "" +"Если для одной из синхронных транзакций истечет время ожидания, эта " +"транзакция будет отменена, а вместе с ней и все последующие транзакции в " +"очереди на репликацию. Похожим образом отменяются и асинхронные транзакции " +"при ошибке записи в WAL. Действует **правило отмены**: транзакции отменяются" +" в порядке, обратном порядку вызова ``box.commit()`` для каждой из них, " +"независимо от того, синхронные транзакции или асинхронные." msgid "" "One more important thing is that if an asynchronous transaction is blocked " -"on a synchronous transaction, it does not become synchronous as well. This " +"by a synchronous transaction, it does not become synchronous as well. This " "just means it will wait for the synchronous transaction to be committed. But" -" once it is done, the asynchronous transaction will finish its commit " -"immediately -- it won't wait for being replicated itself." +" once it is done, the asynchronous transaction will be committed " +"immediately—it won't wait for being replicated itself." msgstr "" +"Асинхронная транзакция, заблокированная синхронной, не становится сама " +"синхронной, а просто ожидает коммита синхронной транзакции. Как только это " +"произойдет, асинхронная транзакция сразу сможет пройти коммит, не ожидая " +"репликации." msgid "Limitations and known problems" -msgstr "" +msgstr "Ограничения и известные проблемы" msgid "" "Until version :doc:`2.5.2 `, there was no way to enable " "synchronous replication for existing spaces, but since 2.5.2 it can be " "enabled by :ref:`space_object:alter({is_sync = true}) `." msgstr "" +"До версии :doc:`2.5.2 ` способа настроить синхронную " +"репликацию для существующих спейсов не было. Однако, начиная с версии 2.5.2," +" ее можно включить, вызвав метод :ref:`space_object:alter({is_sync = true}) " +"`." msgid "" "Synchronous transactions work only for master-slave topology. You can have " "multiple replicas, anonymous replicas, but only one node can make " "synchronous transactions." msgstr "" +"Синхронные транзакции работают исключительно в топологии \"мастер-реплика\"." +" В кластере может быть несколько реплик, в том числе анонимных, однако " +"синхронные транзакции должен совершать только один узел." msgid "" -"Anonymous replicas participate in the quorum. This will change: it won't be " -"possible for a synchronous transaction to gather quorum using anonymous " -"replicas in future." +"Anonymous replicas participate in the quorum. However, this will change: it " +"won't be possible for a synchronous transaction to gather quorum using " +"anonymous replicas in the future." msgstr "" +"Анонимные реплики принимают участие в кворуме. Однако в будущих версиях это " +"изменится: для синхронной транзакции кворум с участием анонимных реплик " +"собрать будет нельзя." msgid "Leader election" -msgstr "" +msgstr "Выборы лидера" msgid "" -"Starting from the version :doc:`2.6.1 `, Tarantool has the " +"Starting from version :doc:`2.6.1 `, Tarantool has the " "built-in functionality managing automated leader election in a replica set. " "For more information, refer to the :ref:`corresponding chapter " "`." msgstr "" +"В Tarantool, начиная с версии :doc:`2.6.1 `, есть встроенная" +" функциональность для управления автоматическими выборами лидера (automated " +"leader election) в наборе реплик. Подробности можно найти в " +":ref:`соответствующей главе `." msgid "Tips and tricks" -msgstr "" +msgstr "Полезные советы" msgid "" "If a transaction is rolled back, it does not mean the ROLLBACK message " @@ -203,9 +299,16 @@ msgid "" "dies, so the transaction will be committed by the new master. Your " "application logic should be ready for that." msgstr "" +"Если транзакция была отменена, это не обязательно значит, что реплики " +"получили сообщение ROLLBACK. Может возникнуть ситуация, когда мастер " +"внезапно прекратит работу, а после этого коммит транзакции будет выполнен " +"новым мастером. Учитывайте это в логике вашего приложения." msgid "" "Synchronous transactions are better to use with full mesh. Then the replicas" -" can talk to each other in case of the master node's death, and still " -"confirm some pending transactions." +" can talk to each other in case of the master node's death and still confirm" +" some pending transactions." msgstr "" +"Синхронные транзакции лучше всего использовать в кластерах с полноячеистой " +"топологией (full mesh). В этом случае реплики смогут общаться друг с другом " +"и подтверждать некоторые транзакции, даже если откажет мастер." diff --git a/locale/ru/LC_MESSAGES/contributing/docs.po b/locale/ru/LC_MESSAGES/contributing/docs.po index 6b3f4ce9b2..5c3a6f95e3 100644 --- a/locale/ru/LC_MESSAGES/contributing/docs.po +++ b/locale/ru/LC_MESSAGES/contributing/docs.po @@ -1,10 +1,10 @@ -msgid "Documentation guidelines" -msgstr "Рекомендации по написанию документации" +msgid "Documentation & Localization guidelines" +msgstr "" msgid "" "These guidelines aim to help the team and external contributors write, " -"publish, and collaborate on the Tarantool documentation." +"translate, publish, and collaborate on the Tarantool documentation." msgstr "" msgid "" diff --git a/locale/ru/LC_MESSAGES/contributing/docs/sphinx-warnings.po b/locale/ru/LC_MESSAGES/contributing/docs/sphinx-warnings.po index e1315bb16a..571a81b042 100644 --- a/locale/ru/LC_MESSAGES/contributing/docs/sphinx-warnings.po +++ b/locale/ru/LC_MESSAGES/contributing/docs/sphinx-warnings.po @@ -7,9 +7,6 @@ msgid "" "engine while building the docs." msgstr "" -msgid "Warnings and solutions list" -msgstr "" - msgid "" "Below we cite a list with the most frequent warnings and the ways of " "solutions." diff --git a/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po b/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po index b49fe31e7b..ceef7965ea 100644 --- a/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po +++ b/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po @@ -289,11 +289,12 @@ msgid "" "IPROTO_EXPR=0x27\n" "IPROTO_OPS=0x28\n" "IPROTO_BALLOT=0x29\n" -"IPROTO_BALLOT_IS_RO=0x01\n" +"IPROTO_BALLOT_IS_RO_CFG=0x01\n" "IPROTO_BALLOT_VCLOCK=0x02\n" "IPROTO_BALLOT_GC_VCLOCK=0x03\n" -"IPROTO_BALLOT_IS_LOADING=0x04\n" +"IPROTO_BALLOT_IS_RO=0x04\n" "IPROTO_BALLOT_IS_ANON=0x05\n" +"IPROTO_BALLOT_IS_BOOTED=0x06\n" "IPROTO_TUPLE_META=0x2a\n" "IPROTO_OPTIONS=0x2b\n" "IPROTO_DATA=0x30\n" @@ -337,11 +338,12 @@ msgstr "" "IPROTO_EXPR=0x27\n" "IPROTO_OPS=0x28\n" "IPROTO_BALLOT=0x29\n" -"IPROTO_BALLOT_IS_RO=0x01\n" +"IPROTO_BALLOT_IS_RO_CFG=0x01\n" "IPROTO_BALLOT_VCLOCK=0x02\n" "IPROTO_BALLOT_GC_VCLOCK=0x03\n" -"IPROTO_BALLOT_IS_LOADING=0x04\n" +"IPROTO_BALLOT_IS_RO=0x04\n" "IPROTO_BALLOT_IS_ANON=0x05\n" +"IPROTO_BALLOT_IS_BOOTED=0x06\n" "IPROTO_TUPLE_META=0x2a\n" "IPROTO_OPTIONS=0x2b\n" "IPROTO_DATA=0x30\n" @@ -2291,33 +2293,78 @@ msgstr "" "в IPROTO_BALLOT — это элементы ассоциативного массива:" msgid "" -"IPROTO_BALLOT_IS_RO (0x01) + MP_BOOL\n" +"IPROTO_BALLOT_IS_RO_CFG (0x01) + MP_BOOL\n" "IPROTO_BALLOT_VCLOCK (0x02) + vclock\n" "IPROTO_BALLOT_GC_VCLOCK (0x03) + vclock\n" -"IPROTO_BALLOT_IS_LOADING (0x04) + MP_BOOL\n" -"IPROTO_BALLOT_IS_ANON = 0x05 + MP_BOOL" +"IPROTO_BALLOT_IS_RO (0x04) + MP_BOOL\n" +"IPROTO_BALLOT_IS_ANON = 0x05 + MP_BOOL\n" +"IPROTO_BALLOT_IS_BOOTED = 0x06 + MP_BOOL" msgstr "" -"IPROTO_BALLOT_IS_RO (0x01) + MP_BOOL\n" +"IPROTO_BALLOT_IS_RO_CFG (0x01) + MP_BOOL\n" "IPROTO_BALLOT_VCLOCK (0x02) + vclock\n" "IPROTO_BALLOT_GC_VCLOCK (0x03) + vclock\n" -"IPROTO_BALLOT_IS_LOADING (0x04) + MP_BOOL\n" -"IPROTO_BALLOT_IS_ANON = 0x05 + MP_BOOL" +"IPROTO_BALLOT_IS_RO (0x04) + MP_BOOL\n" +"IPROTO_BALLOT_IS_ANON = 0x05 + MP_BOOL\n" +"IPROTO_BALLOT_IS_BOOTED = 0x06 + MP_BOOL" msgid "" -"IPROTO_BALLOt-IS_ANON corresponds to :ref:`box.cfg.replication_anon " -"`." +"IPROTO_BALLOT_IS_RO_CFG and IPRO_BALLOT_VCLOCK and IPROTO_BALLOT_GC_VCLOCK " +"and IPROTO_BALLOT_IS_RO were added in version :doc:`2.6.1 `." +" IPROTO_BALLOT_IS_ANON was added in version :doc:`2.7.1 `. " +"IPROTO_BALLOT_IS_BOOTED was added in version 2.7.3 and 2.8.2 and 2.9.1. " +"There have been some name changes starting with version 2.7.3 and 2.8.2 and " +"2.9.1: IPROTO_BALLOT_IS_RO_CFG was formerly called IPROTO_BALLOT_IS_RO, and " +"IPROTO_BALLOT_IS_RO was formerly called IPROTO_BALLOT_IS_LOADING." +msgstr "" +"IPROTO_BALLOT_IS_RO_CFG, IPRO_BALLOT_VCLOCK, IPROTO_BALLOT_GC_VCLOCK и " +"IPROTO_BALLOT_IS_RO добавлены в версии :doc:`2.6.1 `. " +"Константа IPROTO_BALLOT_IS_ANON добавлена в версии :doc:`2.7.1 " +"`. Константа IPROTO_BALLOT_IS_BOOTED добавлена в версиях " +"2.7.3, 2.8.2 и 2.9.1. В версиях 2.7.3, 2.8.2, 2.9.1 и более поздних " +"константа IPROTO_BALLOT_IS_RO переименована в IPROTO_BALLOT_IS_RO_CFG, а " +"IPROTO_BALLOT_IS_LOADING — в IPROTO_BALLOT_IS_RO." + +msgid "" +"IPROTO_BALLOT_IS_RO_CFG corresponds to :ref:`box.cfg.read_only `." +msgstr "" +"Значение IPROTO_BALLOT_IS_RO_CFG соответствует значению " +":ref:`box.cfg.read_only `." + +msgid "" +"IPROTO_BALLOT_GC_VCLOCK can be the vclock value of the instance's oldest WAL" +" entry, which corresponds to :ref:`box.info.gc().vclock `." msgstr "" -"IPROTO_BALLOT_IS_ANON соответствует :ref:`box.cfg.replication_anon " +"IPROTO_BALLOT_GC_VCLOCK может принимать значение vclock самой старой записи " +"журнала WAL на экземпляре. Это соответствует значению " +":ref:`box.info.gc().vclock `." + +msgid "" +"IPROTO_BALLOT_IS_RO is true if the instance is not writable, which may " +"happen for a variety of reasons, such as: it was configured as " +":ref:`read_only `, or it has :ref:`orphan status " +"`, or it is a :ref:`Raft ` " +"follower." +msgstr "" +"IPROTO_BALLOT_IS_RO принимает значение ``true``, если экземпляр недоступен " +"для записи. Причины у этого могут быть разные: например, указано значение " +":ref:`read_only `, :ref:`имеет статус orphan " +"` или является последователем (follower) при " +":ref:`выполнении алгоритма Raft `." + +msgid "" +"IPROTO_BALLOT_IS_ANON corresponds to :ref:`box.cfg.replication_anon " "`." +msgstr "" +"Значение IPROTO_BALLOT_IS_ANON соответствует значению " +":ref:`box.cfg.replication_anon `." msgid "" -"The items other than IPROTO_BALLOT_IS_ANON were added in version :doc:`2.6.1" -" `. PROTO_BALLOT_IS_ANON was added in version :doc:`2.7.1 " -"`." +"IPROTO_BALLOT_IS_BOOTED is true if the instance has finished its bootstrap " +"or recovery process." msgstr "" -"Элементы, отличные от IPROTO_BALLOT_IS_ANON, были добавлены в версии " -":doc:`2.6.1 `. PROTO_BALLOT_IS_ANON был добавлен в версии " -":doc:`2.7.1 `." +"IPROTO_BALLOT_IS_BOOTED принимает значение ``true``, если экземпляр завершил" +" инициализацию или восстановление." msgid "**FLAGS**" msgstr "**ФЛАГИ**" @@ -2377,8 +2424,8 @@ msgid "" "To follow the examples in this section, get a single Linux computer and " "start three command-line shells (\"terminals\")." msgstr "" -"Чтобы выполнить примеры, приведенные в этом разделе, возьмите компьютер с " -"Linux и запустите три командных оболочки (\"терминалы\")." +"Чтобы выполнить примеры, приведенные в этом разделе, запустите на компьютере" +" с Linux три командных оболочки (терминала)." msgid "" "-- On terminal #1, Start monitoring port 3302 with `tcpdump " From 294b56b3d7c45708ce3bcdab80812ef89a70025b Mon Sep 17 00:00:00 2001 From: alexandra-mara Date: Tue, 27 Jul 2021 10:12:56 +0000 Subject: [PATCH 6/6] Update translations --- .../dev_guide/internals/box_protocol.po | 4 +- .../reference/reference_lua/popen.po | 573 +++++++++++++++--- 2 files changed, 476 insertions(+), 101 deletions(-) diff --git a/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po b/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po index ceef7965ea..6ff5f08430 100644 --- a/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po +++ b/locale/ru/LC_MESSAGES/dev_guide/internals/box_protocol.po @@ -2347,8 +2347,8 @@ msgid "" "follower." msgstr "" "IPROTO_BALLOT_IS_RO принимает значение ``true``, если экземпляр недоступен " -"для записи. Причины у этого могут быть разные: например, указано значение " -":ref:`read_only `, :ref:`имеет статус orphan " +"для записи. Причины у этого могут быть разные: например, экземпляр настроен " +"как :ref:`read_only `, :ref:`имеет статус orphan " "` или является последователем (follower) при " ":ref:`выполнении алгоритма Raft `." diff --git a/locale/ru/LC_MESSAGES/reference/reference_lua/popen.po b/locale/ru/LC_MESSAGES/reference/reference_lua/popen.po index b454f86c2f..58323da9bb 100644 --- a/locale/ru/LC_MESSAGES/reference/reference_lua/popen.po +++ b/locale/ru/LC_MESSAGES/reference/reference_lua/popen.po @@ -1,6 +1,6 @@ msgid "Module `popen`" -msgstr "" +msgstr "Модуль `popen`" msgid "Overview" msgstr "Общие сведения" @@ -17,32 +17,51 @@ msgid "" "system call to create an object, so the caller thread is blocked until " "execution of a child process begins." msgstr "" +"Начиная с версии :doc:`2.4.1 ` в Tarantool есть встроенный " +"модуль ``popen``, предназначенный для выполнения внешних программ. Он " +"работает аналогично модулю `subprocess() " +"`_ в Python или `Open3 " +"`_ в Ruby. Однако в " +"``popen`` нет вспомогательных средств, которые предоставляют эти языки; он " +"предоставляет только базовые функции. Для создания объекта ``popen`` " +"использует системный вызов `vfork() " +"`_, " +"поэтому вызывающий поток блокируется до тех пор, пока не начинается " +"выполнение дочернего процесса." msgid "" "The ``popen`` module provides two functions to create the popen object:" -msgstr "" +msgstr "В модуле ``popen`` есть две функции для создания объекта popen:" msgid "" ":ref:`popen.shell ` which is similar to the libc `popen " "`_ syscall" msgstr "" +":ref:`popen.shell `, аналогичная системному вызову `popen " +"`_ из libc;" msgid "" ":ref:`popen.new ` to create a popen object with more specific " "options" msgstr "" +":ref:`popen.new ` для создания объекта popen с более " +"специфическими параметрами." msgid "" "Either function returns a handle which we will call ``popen_handle`` or " "``ph``. With the handle one can execute methods." msgstr "" +"Обе функции возвращают дескриптор, который мы будем называть " +"``popen_handle`` или ``ph``. Через дескриптор вы можете выполнять методы." msgid "Index" msgstr "Указатель" msgid "Below is a list of all ``popen`` functions and handle methods." msgstr "" +"Ниже приведен перечень всех функций ``popen`` и методов дескриптора ``ph``." msgid "Name" msgstr "Имя" @@ -54,91 +73,91 @@ msgid ":ref:`popen.shell() `" msgstr ":ref:`popen.shell() `" msgid "Execute a shell command" -msgstr "" +msgstr "Выполнение shell-команды" msgid ":ref:`popen.new() `" msgstr ":ref:`popen.new() `" msgid "Execute a child program in a new process" -msgstr "" +msgstr "Выполнение дочерней программы в новом процессе" msgid ":ref:`popen_handle:read() `" -msgstr "" +msgstr ":ref:`popen_handle:read() `" msgid "Read data from a child peer" -msgstr "" +msgstr "Считывание данных из дочернего процесса" msgid ":ref:`popen_handle:write() `" -msgstr "" +msgstr ":ref:`popen_handle:write() `" msgid "Write a string to stdin stream of a child process" -msgstr "" +msgstr "Запись строки в поток stdin дочернего процесса" msgid ":ref:`popen_handle:shutdown() `" -msgstr "" +msgstr ":ref:`popen_handle:shutdown() `" msgid "Close parent's ends of std* fds" -msgstr "" +msgstr "Закрытие канала с std* со стороны родителя" msgid ":ref:`popen_handle:terminate() `" -msgstr "" +msgstr ":ref:`popen_handle:terminate() `" msgid "Send SIGTERM signal to a child process" -msgstr "" +msgstr "Отправка сигнала SIGTERM дочернему процессу" msgid ":ref:`popen_handle:kill() `" -msgstr "" +msgstr ":ref:`popen_handle:kill() `" msgid "Send SIGKILL signal to a child process" -msgstr "" +msgstr "Отправка сигнала SIGKILL дочернему процессу" msgid ":ref:`popen_handle:signal() `" -msgstr "" +msgstr ":ref:`popen_handle:signal() `" msgid "Send signal to a child process" -msgstr "" +msgstr "Отправка сигнала дочернему процессу" msgid ":ref:`popen_handle:info() `" -msgstr "" +msgstr ":ref:`popen_handle:info() `" msgid "Return information about the popen handle" -msgstr "" +msgstr "Получение информации о дескрипторе popen" msgid ":ref:`popen_handle:wait() `" -msgstr "" +msgstr ":ref:`popen_handle:wait() `" msgid "Wait until a child process gets exited or signaled" -msgstr "" +msgstr "Ожидание, пока дочерний процесс не завершится или не получит сигнал" msgid ":ref:`popen_handle:close() `" -msgstr "" +msgstr ":ref:`popen_handle:close() `" msgid "Close a popen handle" -msgstr "" +msgstr "Закрытие дескриптора popen" msgid ":ref:`Module constants `" -msgstr "" +msgstr ":ref:`Константы модуля `" msgid "Module constants" -msgstr "" +msgstr "Константы модуля" msgid ":ref:`Handle fields `" -msgstr "" +msgstr ":ref:`Поля дескриптора `" msgid "Handle fields" -msgstr "" +msgstr "Поля дескриптора" msgid "Execute a shell command." -msgstr "" +msgstr "Выполнение shell-команды." msgid "Parameters" msgstr "Параметры" msgid "a command to run, mandatory" -msgstr "" +msgstr "имя выполняемой команды, обязательно" msgid "communication mode, optional" -msgstr "" +msgstr "режим передачи данных, необязательно" msgid "return" msgstr "возвращает" @@ -146,18 +165,23 @@ msgstr "возвращает" msgid "" "(if success) a popen handle, which we will call ``popen_handle`` or ``ph``" msgstr "" +"(при успешном выполнении) дескриптор объекта popen, который мы будем " +"называть ``popen_handle`` или ``ph``" msgid "(if failure) ``nil, err``" -msgstr "" +msgstr "(при неудачном выполнении) ``nil, err``" msgid "" "Possible errors: if a parameter is incorrect, the result is IllegalParams: " "incorrect type or value of a parameter. For other possible errors, see " ":ref:`popen.new() `." msgstr "" +"Возможные ошибки: если один из параметров задан некорректно, функция " +"возвращает IllegalParams: неправильно задан тип или значение параметра. " +"Другие возможные ошибки смотрите в разделе :ref:`popen.new() `." msgid "The possible ``mode`` values are:" -msgstr "" +msgstr "Возможные значения режима передачи данных ``mode``:" msgid "'w' which enables :ref:`popen_handle:write() `" msgstr "" @@ -181,6 +205,10 @@ msgid "" "``opts.shell.group_signal`` both set to `true`, and with ``opts.stdin`` and " "``opts.stdout`` and ``opts.stderr`` all set based on the ``mode`` parameter." msgstr "" +"Функция ``shell`` --- это сокращение для :ref:`popen.new({command}, opts) " +"` с ``opts.shell.setsid`` и ``opts.shell.group_signal``, " +"установленными в `true`, и значениями ``opts.stdin``, ``opts.stdout`` и " +"``opts.stderr``, установленными на основе параметра ``mode``." msgid "" "All std* streams are inherited from the parent by default unless it is " @@ -206,6 +234,15 @@ msgid "" "ph:close()\n" "print(date)" msgstr "" +"local popen = require('popen')\n" +"-- Запуск программы и сохранение ее дескриптора.\n" +"local ph = popen.shell('date', 'r')\n" +"-- Считывание вывода программы и удаление следующей строки.\n" +"local date = ph:read():rstrip()\n" +"-- Освобождение ресурсов. Процесс принудительно завершается (но 'date'\n" +"-- все равно завершает работу).\n" +"ph:close()\n" +"print(date)" msgid "" "Unix defines a text file as a sequence of lines. Each line is terminated by " @@ -221,57 +258,70 @@ msgid "" "world (stdout, console or log). That is why the example above contains " "``rstrip()``." msgstr "" +"Однако внутри приложение обычно работает со строками, которые *не* " +"завершаются символом новой строки (например, строки сообщений об ошибках). " +"Символ новой строки обычно добавляется прямо перед записью строки в stdout, " +"консоль или лог. Поэтому в примере выше был использован метод ``rstrip()``." msgid "Execute a child program in a new process." -msgstr "" +msgstr "Выполнение дочерней программы в новом процессе." msgid "" "an array of a program to run with command line options, mandatory; absolute " "path to the program is required when ``opts.shell`` is false (default)" msgstr "" +"массив, состоящий из запускаемой программы и параметров командной строки, " +"обязательный аргумент; если поле ``opts.shell`` установлено в false (по " +"умолчанию), то необходимо задать абсолютный путь к программе" msgid "table of options, optional" -msgstr "" +msgstr "таблица параметров, необязательно" msgid "Possible raised errors are:" -msgstr "" +msgstr "Возможные ошибки:" msgid "IllegalParams: incorrect type or value of a parameter" -msgstr "" +msgstr "IllegalParams: некорректный тип или значение параметра" msgid "IllegalParams: group signal is set, while setsid is not" -msgstr "" +msgstr "IllegalParams: групповой сигнал задан, а setsid --- нет" msgid "Possible error reasons when ``nil, err`` is returned are:" -msgstr "" +msgstr "Возможные причины ошибок, когда возвращается ``nil, err``:" msgid "" "SystemError: dup(), fcntl(), pipe(), vfork() or close() fails in the parent " "process" msgstr "" +"SystemError: dup(), fcntl(), pipe(), vfork() или close() завершились с " +"ошибкой в родительском процессе" msgid "" "SystemError: (temporary restriction) the parent process has closed stdin, " "stdout or stderr" msgstr "" +"SystemError: (временное ограничение) родительский процесс закрыл stdin, " +"stdout или stderr" msgid "OutOfMemory: unable to allocate the handle or a temporary buffer" msgstr "" +"OutOfMemory: невозможно выделить память для дескриптора или временного " +"буфера" msgid "Possible ``opts`` items are:" -msgstr "" +msgstr "Возможные элементы ``opts``:" msgid "``opts.stdin`` (action on STDIN_FILENO)" -msgstr "" +msgstr "``opts.stdin`` (действие над STDIN_FILENO)" msgid "``opts.stdout`` (action on STDOUT_FILENO)" -msgstr "" +msgstr "``opts.stdout`` (действие над STDOUT_FILENO)" msgid "``opts.stderr`` (action on STDERR_FILENO)" -msgstr "" +msgstr "``opts.stderr`` (действие над STDERR_FILENO)" msgid "The ``opts`` table file descriptor actions may be:" -msgstr "" +msgstr "Возможные действия файлового дескриптора в таблице ``opts``:" msgid "" "``popen.opts.INHERIT`` (== 'inherit') [default] inherit the fd from the " @@ -294,27 +344,32 @@ msgid "" "be used inside a process. Each ``opts.env`` item may be a key-value pair " "(key is a variable name, value is a variable value)." msgstr "" +"Таблица ``opts`` может содержать таблицу ``env`` переменных среды для " +"использования внутри процесса. Каждый элемент ``opts.env`` может быть парой " +"ключ-значение (где ключ --- имя переменной, а значение --- значение " +"переменной)." msgid "If ``opts.env`` is not set then the current environment is inherited." -msgstr "" +msgstr "Если ``opts.env`` не установлено, то наследуется текущая среда." msgid "" "If ``opts.env`` is an empty table, then the environment will be dropped." -msgstr "" +msgstr "Если ``opts.env`` является пустой таблицей, то среда будет сброшена." msgid "" "If ``opts.env`` is set to a non-empty table, then the environment will be " "replaced." msgstr "" +"Если ``opts.env`` является непустой таблицей, то среда будет заменена." msgid "The ``opts`` table may contain these boolean items:" -msgstr "" +msgstr "Таблица ``opts`` может содержать следующие элементы типа boolean:" msgid "Default" msgstr "Значение по умолчанию" msgid "opts.shell" -msgstr "" +msgstr "opts.shell" msgid "false" msgstr "false" @@ -323,17 +378,22 @@ msgid "" "If true, then run a child process via ``sh -c \"${opts.argv}\"``. If false, " "then call the executable directly." msgstr "" +"При значении true выполняется запуск дочернего процесса через ``sh -c " +"\"${opts.argv}\"``. При значении false исполняемый процесс вызывается " +"напрямую." msgid "opts.setsid" -msgstr "" +msgstr "opts.setsid" msgid "" "If true, then run the program in a new session. If false, then run the " "program in the Tarantool instance's session and process group." msgstr "" +"При значении true программа запускается в новой сессии. При значении false " +"программа запускается в сессии и группе процессов экземпляра Tarantool." msgid "opts.close_fds" -msgstr "" +msgstr "opts.close_fds" msgid "true" msgstr "true" @@ -342,26 +402,35 @@ msgid "" "If true, then close all inherited fds from the parent. If false, then do not" " close all inherited fds from the parent." msgstr "" +"При значении true закрываются все унаследованные родительские файловые " +"дескрипторы. При значении false унаследованные родительские файловые " +"дескрипторы не закрываются." msgid "opts.restore_signals" -msgstr "" +msgstr "opts.restore_signals" msgid "" "If true, then reset all signal actions modified in the parent's process. If " "false, then inherit all signal actions modified in the parent's process." msgstr "" +"При значении true сбрасываются все действия сигналов, измененные в " +"родительском процессе. При значении false все действия сигналов, измененные " +"в родительском процессе, наследуются." msgid "opts.group_signal" -msgstr "" +msgstr "opts.group_signal" msgid "" "If true, then send signal to a child process group, if and only if " "``opts.setsid`` is enabled. If false, then send signal to a child process " "only." msgstr "" +"При значении true отправляется сигнал в группу дочерних процессов, но только" +" при условии, что установлено поле ``opts.setsid``. При значении false " +"сигнал отправляется только одному дочернему процессу." msgid "opts.keep_child" -msgstr "" +msgstr "opts.keep_child" msgid "" "If true, then do not send SIGKILL to a child process (or to a process group " @@ -370,6 +439,12 @@ msgid "" ":ref:`popen_handle:close() ` or when Lua GC collects the " "handle." msgstr "" +"При значении true дочернему процессу (или группе процессов, если поле " +"``opts.group_signal`` установлено в true) не отправляется сигнал SIGKILL. " +"При значении false дочернему процессу (или группе процессов, если поле " +"``opts.group_signal`` установлено в true) отправляется сигнал SIGKILL при " +"выполнении :ref:`popen_handle:close() ` или когда Lua GC " +"собирает дескрипторы." msgid "" "The returned ``ph`` handle provides a :ref:`popen_handle:close() ` для явного освобождения всех " +"занятых ресурсов, включая сам дочерний процесс, если не установлено поле " +"``opts.keep_child``. Однако, если метод ``close()`` не вызывается для " +"дескриптора в течение его жизни, Lua GC запустит то же самое действие по " +"освобождению ресурсов." msgid "" "Tarantool recommends using ``opts.setsid`` plus ``opts.group_signal`` if a " "child process may spawn its own children and if they should all be killed " "together." msgstr "" +"Tarantool рекомендует использовать ``opts.setsid`` вместе с " +"``opts.group_signal``, если дочерний процесс может создать собственные " +"дочерние процессы и их все нужно будет завершить одновременно." msgid "" "A signal will not be sent if the child process is already dead. Otherwise we" @@ -392,11 +476,19 @@ msgid "" "function will not send a signal to the process group even when " "``opts.setsid`` and ``opts.group_signal`` are set." msgstr "" +"Сигнал не будет отправлен, если дочерний процесс уже был завершен. В " +"противном случае мы можем случайно завершить другой процесс, который имеет " +"тот же идентификатор процесса после освобождения его предыдущим. Это " +"означает, что если дочерний процесс завершается до того, как завершаются его" +" дочерние процессы, то функция не будет отправлять сигнал группе процессов, " +"даже когда установлены ``opts.setsid`` и ``opts.group_signal``." msgid "" "Use :ref:`os.environ() ` to pass a copy of the current " "environment with several replacements (see example 2 below)." msgstr "" +"Используйте :ref:`os.environ() `, чтобы передать копию текущей " +"среды с несколькими заменами (см. Пример 2 ниже)." msgid "**Example 1**" msgstr "**Пример 1**" @@ -405,6 +497,9 @@ msgid "" "This is the equivalent of the ``sh -c date`` command. It starts a process, " "runs 'date', reads the output, and closes the popen object (``ph``)." msgstr "" +"В этом примере выполняется аналог команды ``sh -c date``. Происходит запуск " +"процесса, выполняется ``'date'``, считывается результат и объект popen " +"(``ph``) закрывается." msgid "" "local popen = require('popen')\n" @@ -416,6 +511,14 @@ msgid "" "ph:close()\n" "print(date) -- e.g. Thu 16 Apr 2020 01:40:56 AM MSK" msgstr "" +"local popen = require('popen')\n" +"\n" +"local ph = popen.new({'/bin/date'}, {\n" +" stdout = popen.opts.PIPE,\n" +"})\n" +"local date = ph:read():rstrip()\n" +"ph:close()\n" +"print(date) -- например, Thu 16 Apr 2020 01:40:56 AM MSK" msgid "**Example 2**" msgstr "**Пример 2**" @@ -438,12 +541,23 @@ msgid "" "ph:close()\n" "print(res) -- bar" msgstr "" +"local popen = require('popen')\n" +"local env = os.environ()\n" +"env['FOO'] = 'bar'\n" +"local ph = popen.new({'echo \"${FOO}\"'}, {\n" +" stdout = popen.opts.PIPE,\n" +" shell = true,\n" +" env = env,\n" +"})\n" +"local res = ph:read():rstrip()\n" +"ph:close()\n" +"print(res) -- bar" msgid "**Example 3**" msgstr "**Пример 3**" msgid "Example 3 demonstrates how to capture a child's stderr." -msgstr "" +msgstr "Пример 3 показывает, как перехватить дочерний поток stderr." msgid "" "local popen = require('popen')\n" @@ -455,6 +569,14 @@ msgid "" "ph:close()\n" "print(res) -- hello" msgstr "" +"local popen = require('popen')\n" +"local ph = popen.new({'echo hello >&2'}, { -- !!\n" +" stderr = popen.opts.PIPE, -- !!\n" +" shell = true,\n" +"})\n" +"local res = ph:read({stderr = true}):rstrip()\n" +"ph:close()\n" +"print(res) -- hello" msgid "**Example 4**" msgstr "**Пример 4**" @@ -463,11 +585,17 @@ msgid "" "Example 4 demonstrates how to run a stream program (like ``grep``, ``sed`` " "and so on), write to its stdin and read from its stdout." msgstr "" +"Пример 4 показывает, как запустить потоковую программу (например, ``grep``, " +"``sed`` и т.д.), записать данные в ее поток stdin и считать данные из " +"stdout." msgid "" "The example assumes that input data are small enough to fit in a pipe buffer" " (typically 64 KiB, but this depends on the platform and its configuration)." msgstr "" +"В этом примере предполагается, что входные данные достаточно малы, чтобы " +"поместиться в буфер канала (обычно его размер равен 64 КиБ, но это зависит " +"от конкретной платформы и ее конфигурации)." msgid "" "If a process writes lengthy data, it will get stuck in " @@ -475,12 +603,19 @@ msgid "" ":ref:`popen_handle:read() ` in a loop in another fiber (start it" " before the first ``:write()``)." msgstr "" +"Если процесс записывает большое количество данных, он приостановится при " +"выполнении :ref:`popen_handle:write() `. Для разрешения этой " +"проблемы вызывайте :ref:`popen_handle:read() ` в цикле в другом " +"файбере (запустите его перед первым вызовом ``:write()``)." msgid "" "If a process writes lengthy text to stderr, it may get stick in ``write()`` " "because the stderr pipe buffer becomes full. To handle this case: read " "stderr in a separate fiber." msgstr "" +"Если процесс записывает длинный текст в stderr, он может приостановиться при" +" выполнении ``write()``, потому что буфер канала stderr заполнился. Для " +"решения этой проблемы считывайте из stderr в отдельном файбере." msgid "" "local function call_jq(input, filter)\n" @@ -517,45 +652,85 @@ msgid "" " return table.concat(chunks):rstrip()\n" "end" msgstr "" +"local function call_jq(input, filter)\n" +" -- Запуск процесса jq, соединение с stdin, stdout и stderr.\n" +" local jq_argv = {'/usr/bin/jq', '-M', '--unbuffered', filter}\n" +" local ph, err = popen.new(jq_argv, {\n" +" stdin = popen.opts.PIPE,\n" +" stdout = popen.opts.PIPE,\n" +" stderr = popen.opts.PIPE,\n" +" })\n" +" if ph == nil then return nil, err end\n" +" -- Запись входных данных в дочерний stdin и отправка EOF.\n" +" local ok, err = ph:write(input)\n" +" if not ok then return nil, err end\n" +" ph:shutdown({stdin = true})\n" +" -- Считывание всех данных до EOF.\n" +" local chunks = {}\n" +" while true do\n" +" local chunk, err = ph:read()\n" +" if chunk == nil then\n" +" ph:close()\n" +" return nil, err\n" +" end\n" +" if chunk == '' then break end -- EOF\n" +" table.insert(chunks, chunk)\n" +" end\n" +" -- Считывание данных диагностики из stderr (при наличии).\n" +" local err = ph:read({stderr = true})\n" +" if err ~= '' then\n" +" ph:close()\n" +" return nil, err\n" +" end\n" +" -- Соединение всех частей вместе, обрезка символа конца строки.\n" +" return table.concat(chunks):rstrip()\n" +"end" msgid "popen handle methods" -msgstr "" +msgstr "методы дескриптора popen" msgid "Read data from a child peer." -msgstr "" +msgstr "Считывание данных из дочернего процесса." msgid "" "handle of a child process created with :ref:`popen.new() ` or " ":ref:`popen.shell() `" msgstr "" +"дескриптор дочернего процесса, созданный через :ref:`popen.new() ` или :ref:`popen.shell() `" msgid "options" -msgstr "опции" +msgstr "параметры" msgid "" "Possible errors, raised on incorrect parameters or when the fiber is " "cancelled:" msgstr "" +"Возможные ошибки при некорректно заданных параметрах или при отмене файбера:" msgid "IllegalParams: incorrect type or value of a parameter" -msgstr "" +msgstr "IllegalParams: некорректный тип или значение параметра" msgid "IllegalParams: called on a closed handle" -msgstr "" +msgstr "IllegalParams: вызов дескриптора, который уже был закрыт" msgid "IllegalParams: opts.stdout and opts.stderr are both set" -msgstr "" +msgstr "IllegalParams: одновременно установлены opts.stdout и opts.stderr" msgid "" "IllegalParams: a requested IO operation is not supported by the handle " "(stdout / stderr is not piped)" msgstr "" +"IllegalParams: запрашиваемая операция ввода-вывода не поддерживается " +"дескриптором (вывод stdout / stderr не перенаправлен)" msgid "IllegalParams: attempt to operate on a closed file descriptor" msgstr "" +"IllegalParams: попытка произвести операцию над закрытым файловым " +"дескриптором" msgid "FiberIsCancelled: cancelled by an outside code" -msgstr "" +msgstr "FiberIsCancelled: файбер отменен во внешней программе" msgid "true on success, false on error" msgstr "true (правда), если выполнено, false (ложь) в случае ошибки" @@ -565,6 +740,8 @@ msgstr "возвращаемое значение" msgid "(if success) string with read value, empty string if EOF" msgstr "" +"(при успешном выполнении) строка со считанным значением, пустая строка при " +"EOF" msgid "Possible opts items are:" msgstr "" @@ -573,41 +750,51 @@ msgid "" "``opts.stdout`` (boolean, default ``true``, if ``true`` then read from " "stdout)" msgstr "" +"``opts.stdout`` (boolean, значение по умолчанию --- ``true``, при значении " +"``true`` выполняется считывание из stdout)" msgid "" "``opts.stderr`` (boolean, default ``false``, if ``true`` then read from " "stderr)" msgstr "" +"``opts.stderr`` (boolean, значение по умолчанию --- ``false``, при значении " +"``true`` выполняется считывание из stderr)" msgid "``opts.timeout`` (number, default 100 years, time quota in seconds)" msgstr "" +"``opts.timeout`` (число, значение по умолчанию --- 100 лет, временная квота " +"в секундах)" msgid "" "In other words: by default ``read()`` reads from stdout, but reads from " "stderr if one sets ``opts.stderr`` to ``true`` (it is not legal to set both " "``opts.stdout`` and ``opts.stderr`` to ``true``)." msgstr "" +"Другими словами: по умолчанию ``read()`` выполняет считывание из stdout, но " +"если установить ``opts.stderr`` в ``true``, то считывание происходит из " +"stderr (нельзя одновременно установить ``opts.stdout`` и ``opts.stderr`` в " +"``true``)." msgid "SocketError: an IO error occurs at read()" -msgstr "" +msgstr "SocketError: ошибка ввода-вывода при выполнении read()" msgid "TimedOut: exceeded the opts.timeout quota" -msgstr "" +msgstr "TimedOut: превышение квоты opts.timeout" msgid "OutOfMemory: no memory space for a buffer to read into" -msgstr "" +msgstr "OutOfMemory: недостаточно памяти для считывания в буфер" msgid "LuajitError: (\"not enough memory\"): no memory space for the Lua string" -msgstr "" +msgstr "LuajitError: (\"not enough memory\"): недостаточно памяти для строки Lua" msgid "Write string ``str`` to stdin stream of a child process." -msgstr "" +msgstr "Запись строки ``str`` в поток stdin дочернего процесса." msgid "string to write" -msgstr "" +msgstr "строка для записи" msgid "(if success) boolean = true" -msgstr "" +msgstr "(при успешном выполнении) boolean = true" msgid "" "Possible opts items are: ``opts.timeout`` (number, default 100 years, time " @@ -615,66 +802,80 @@ msgid "" msgstr "" msgid "IllegalParams: string length is greater then SSIZE_MAX" -msgstr "" +msgstr "IllegalParams: длина строки превышает SSIZE_MAX" msgid "" "IllegalParams: a requested IO operation is not supported by the handle " "(stdin is not piped)" msgstr "" +"IllegalParams: запрашиваемая операция ввода-вывода не поддерживается " +"дескриптором (вывод stdin не перенаправлен)" msgid "SocketError: an IO error occurs at write()" -msgstr "" +msgstr "SocketError: ошибка ввода-вывода при выполнении write()" msgid "TimedOut: exceeded opts.timeout quota" -msgstr "" +msgstr "TimedOut: превышение квоты opts.timeout" msgid "" "``write()`` may yield forever if the child process does not read data from " "stdin and a pipe buffer becomes full. The size of this pipe buffer depends " "on the platform. Set ``opts.timeout`` when unsure." msgstr "" +"``write()`` может передать управление (yield) и заблокировать файбер, если " +"дочерний процесс не считывает данные из stdin и буфер канала заполнился. " +"Размер буфера зависит от платформы. Если сомневаетесь, обратите внимание на " +"опцию ``opts.timeout``." msgid "" "When ``opts.timeout`` is not set, the ``write()`` blocks (yields the fiber) " "until all data is written or an error happens." msgstr "" +"Когда опция ``opts.timeout`` не установлена, ``write()`` блокирует файбер до" +" момента полной записи данных или возникновения ошибки записи." msgid "Close parent's ends of std* fds." -msgstr "" +msgstr "Закрытие канала с std* со стороны родителя." msgid "Possible `opts` items are:" msgstr "" msgid "``opts.stdin`` (boolean) close parent's end of stdin" -msgstr "" +msgstr "``opts.stdin`` (boolean) закрыть stdin со стороны родителя" msgid "``opts.stdout`` (boolean) close parent's end of stdout" -msgstr "" +msgstr "``opts.stdout`` (boolean) закрыть stdout со стороны родителя" msgid "``opts.stderr`` (boolean) close parent's end of stderr" -msgstr "" +msgstr "``opts.stderr`` (boolean) закрыть stderr со стороны родителя" msgid "We may use the term std* to mean any one of these items." msgstr "" +"Мы можем использовать термин std* для указания на любой из этих элементов." msgid "IllegalParams: an incorrect handle parameter" -msgstr "" +msgstr "IllegalParams: некорректный параметр дескриптора" msgid "IllegalParams: called on a closed handle" -msgstr "" +msgstr "IllegalParams: вызов дескриптора, который уже был закрыт" msgid "IllegalParams: neither stdin, stdout nor stderr is chosen" -msgstr "" +msgstr "IllegalParams: не выбран ни один из потоков stdin, stdout или stderr" msgid "" "IllegalParams: a requested IO operation is not supported by the handle (one" " of std* is not piped)" msgstr "" +"IllegalParams: запрашиваемая операция ввода-вывода не поддерживается " +"дескриптором (один из потоков std* не перенаправлен)" msgid "" "The main reason to use ``shutdown()`` is to send EOF to a child's stdin. " "However the parent's end of stdout / stderr may be closed too." msgstr "" +"Основная цель использования ``shutdown()`` --- отправка EOF в дочерний поток" +" stdin. Однако stdout / stderr может быть уже закрыт со стороны " +"родительского процесса." msgid "" "``shutdown()`` does not fail on already closed fds (idempotence). However, " @@ -688,6 +889,9 @@ msgid "" "``shutdown()`` does not close any fds on a failure: either all requested fds" " are closed or none of them." msgstr "" +"``shutdown()`` не закрывает никакие файловые дескрипторы при завершении с " +"ошибкой: либо закрываются все запрашиваемые дескрипторы (при успешном " +"выполнении), либо ни один из них." msgid "" "local popen = require('popen')\n" @@ -698,53 +902,70 @@ msgid "" "ph:close()\n" "print(res) -- lorem bar ipsum" msgstr "" +"local popen = require('popen')\n" +"local ph = popen.shell('sed s/foo/bar/', 'rw')\n" +"ph:write('lorem foo ipsum')\n" +"ph:shutdown({stdin = true})\n" +"local res = ph:read()\n" +"ph:close()\n" +"print(res) -- lorem bar ipsum" msgid "Send SIGTERM signal to a child process." -msgstr "" +msgstr "Отправка сигнала SIGTERM дочернему процессу." msgid "" "see :ref:`popen_handle:signal() ` for errors and return values" msgstr "" +"для получения информации об ошибках и возвращаемых значениях смотрите " +":ref:`popen_handle:signal() `" msgid "" "``terminate()`` only sends a SIGTERM signal. It does *not* free any " "resources (such as popen handle memory and file descriptors)." msgstr "" +"``terminate()`` просто отправляет сигнал SIGTERM. Он *не* освобождает " +"никакие ресурсы (такие как память для дескрипторов popen и файловые " +"дескрипторы)." msgid "Send SIGKILL signal to a child process." -msgstr "" +msgstr "Отправка сигнала SIGKILL дочернему процессу." msgid "" "``kill()`` only sends a SIGKILL signal. It does *not* free any resources " "(such as popen handle memory and file descriptors)." msgstr "" +"``kill()`` просто отправляет сигнал SIGKILL. Он *не* освобождает никакие " +"ресурсы (такие как память для дескрипторов popen и файловые дескрипторы)." msgid "Send signal to a child process." -msgstr "" +msgstr "Отправка сигнала дочернему процессу." msgid "signal to send" -msgstr "" +msgstr "отправляемый сигнал" msgid "(if success) `true` (signal is sent)" -msgstr "" +msgstr "(при успешном выполнении) `true` (сигнал отправлен)" msgid "Possible raised errors:" -msgstr "" +msgstr "Возможные ошибки:" msgid "IllegalParams: an incorrect handle parameter" -msgstr "" +msgstr "IllegalParams: некорректный параметр дескриптора" msgid "Possible error values for ``nil, err``:" -msgstr "" +msgstr "Возможные значения ошибок при возвращении ``nil, err``:" msgid "" "SystemError: a process does not exists any more (this may also be returned " "for a zombie process or when all processes in a group are zombies (but see " "note re Mac OS below)" msgstr "" +"SystemError: процесс больше не существует (также может возвращаться для " +"зомби-процессов или когда все процессы в группе являются зомби-процессами " +"(но см. примечание для Mac OS ниже)" msgid "SystemError: invalid signal number" -msgstr "" +msgstr "SystemError: неправильный номер сигнала" msgid "" "SystemError: no permission to send a signal to a process or a process group " @@ -753,6 +974,11 @@ msgid "" " re uncertain) (this may also appear due to other reasons, details are " "uncertain)" msgstr "" +"SystemError: нет разрешения на отправку сигнала процессу или группе " +"процессов (возвращается на Mac OS, когда сигнал отправляется группе " +"процессов, где лидер группы является зомби-процессом (или все процессы " +"являются зомби-процессами, детали неясны) (эта ошибка также может возникнуть" +" по другим причинам, детали неясны)" msgid "" "If ``opts.setsid`` and ``opts.group_signal`` are set for the handle, the " @@ -762,29 +988,37 @@ msgid "" "signal, particularly if the process has just been forked (this may be due to" " a race condition)." msgstr "" +"Если для дескриптора установлены ``opts.setsid`` и ``opts.group_signal``, " +"сигнал отправляется группе процессов, а не отдельному процессу. Для " +"подробной информации по групповым сигналам смотрите :ref:`popen.new() " +"`. Внимание: на Mac OS процесс в группе может не получить сигнал," +" особенно если он только что был разветвлен (возможно это происходит из-за " +"состояния гонки)." msgid "" "Note: The module offers ``popen.signal.SIG*`` constants, because some " "signals have different numbers on different platforms." msgstr "" +"Примечание: Некоторые сигналы имеют разные номера на разных платформах. " +"Поэтому в этом модуле мы предлагаем константы ``popen.signal.SIG*``." msgid "Return information about the popen handle." -msgstr "" +msgstr "Получение информации о дескрипторе popen." msgid "(if success) formatted result" -msgstr "" +msgstr "(при успешном выполнении) отформатированный результат" msgid "res" -msgstr "" +msgstr "res" msgid "IllegalParams: an incorrect handle parameter" -msgstr "" +msgstr "IllegalParams: некорректный параметр дескриптора" msgid "IllegalParams: called on a closed handle" -msgstr "" +msgstr "IllegalParams: вызов дескриптора, который уже был закрыт" msgid "The result format is:" -msgstr "" +msgstr "Результат выводится в следующем формате:" msgid "" "{\n" @@ -809,28 +1043,59 @@ msgid "" " ),\n" "}" msgstr "" +"{\n" +" pid = or ,\n" +" command = ,\n" +" opts = ,\n" +" status =
,\n" +" stdin = one-of(\n" +" popen.stream.OPEN (== 'open'),\n" +" popen.stream.CLOSED (== 'closed'),\n" +" nil,\n" +" ),\n" +" stdout = one-of(\n" +" popen.stream.OPEN (== 'open'),\n" +" popen.stream.CLOSED (== 'closed'),\n" +" nil,\n" +" ),\n" +" stderr = one-of(\n" +" popen.stream.OPEN (== 'open'),\n" +" popen.stream.CLOSED (== 'closed'),\n" +" nil,\n" +" ),\n" +"}" msgid "" "``pid`` is a process id of the process when it is alive, otherwise ``pid`` " "is nil." msgstr "" +"``pid`` --- это идентификатор процесса, когда тот находится в рабочем " +"состоянии; для завершенного процесса ``pid`` имеет значение nil." msgid "" "``command`` is a concatenation of space-separated arguments that were passed" " to ``execve()``. Multiword arguments are quoted. Quotes inside arguments " "are not escaped." msgstr "" +"``command`` --- это конкатенация аргументов, разделенных пробелами, которые " +"были переданы в ``execve()``. Аргументы, состоящие из нескольких слов, " +"заключаются в кавычки. Кавычки внутри аргументов не экранируются." msgid "" "``opts`` is a table of handle options as in the :ref:`popen.new() ` ``opts`` parameter. ``opts.env`` is not shown here, because the " "environment variables map is not stored in a handle." msgstr "" +"``opts`` -- это таблица параметров дескриптора, описанная в разделе ``opts``" +" функции :ref:`popen.new() `. ``opts.env`` здесь не отображается," +" потому что карта переменных среды не хранится в дескрипторе." msgid "" "``status`` is a table that represents a process status in the following " "format:" msgstr "" +"``status`` --- это таблица, отображающая состояние процесса в следующем " +"формате:" msgid "" "{\n" @@ -846,6 +1111,18 @@ msgid "" " signame = ,\n" "}" msgstr "" +"{\n" +" state = one-of(\n" +" popen.state.ALIVE (== 'alive'),\n" +" popen.state.EXITED (== 'exited'),\n" +" popen.state.SIGNALED (== 'signaled'),\n" +" )\n" +" -- Отображается при состоянии процесса 'завершенный'.\n" +" exit_code = ,\n" +" -- Отображается при состоянии процесса 'принимающий сигнал'.\n" +" signo = ,\n" +" signame = ,\n" +"}" msgid "" "``stdin``, ``stdout``, and ``stderr`` reflect the status of the parent's end" @@ -857,7 +1134,7 @@ msgid "" msgstr "" msgid "(on Tarantool console)" -msgstr "" +msgstr "(в консоли Tarantool)" msgid "" "tarantool> require('popen').new({'/usr/bin/touch', '/tmp/foo'})\n" @@ -878,6 +1155,23 @@ msgid "" " pid: 9499\n" "..." msgstr "" +"tarantool> require('popen').new({'/usr/bin/touch', '/tmp/foo'})\n" +"---\n" +"- command: /usr/bin/touch /tmp/foo\n" +" status:\n" +" state: alive\n" +" opts:\n" +" stdout: inherit\n" +" stdin: inherit\n" +" group_signal: false\n" +" keep_child: false\n" +" close_fds: true\n" +" restore_signals: true\n" +" shell: false\n" +" setsid: false\n" +" stderr: inherit\n" +" pid: 9499\n" +"..." msgid "" "tarantool> require('popen').shell('grep foo', 'wrR')\n" @@ -901,25 +1195,50 @@ msgid "" " pid: 10497\n" "..." msgstr "" +"tarantool> require('popen').shell('grep foo', 'wrR')\n" +"---\n" +"- stdout: open\n" +" command: sh -c 'grep foo'\n" +" stderr: open\n" +" status:\n" +" state: alive\n" +" stdin: open\n" +" opts:\n" +" stdout: pipe\n" +" stdin: pipe\n" +" group_signal: true\n" +" keep_child: false\n" +" close_fds: true\n" +" restore_signals: true\n" +" shell: true\n" +" setsid: true\n" +" stderr: pipe\n" +" pid: 10497\n" +"..." msgid "Wait until a child process gets exited or signaled." -msgstr "" +msgstr "Ожидание, пока дочерний процесс не завершится или не получит сигнал." msgid "" "The formatted result is a process status table (the same as the ``status`` " "component of the table returned by :ref:`popen_handle:info() `)." msgstr "" +"Отформатированный результат представляет собой таблицу состояний процесса " +"(аналогично компоненту ``status`` таблицы, возвращаемой через " +":ref:`popen_handle:info() `)." msgid "Close a popen handle." -msgstr "" +msgstr "Закрытие дескриптора popen." msgid "(if success) true" -msgstr "" +msgstr "(при успешном выполнении) true" msgid "" "Possible diagnostics when ``nil, err`` is returned (do not consider them as " "errors):" msgstr "" +"Возможные результаты диагностики, когда возвращается ``nil, err`` (не " +"рассматривайте эти случаи как ошибки):" msgid "" "SystemError: no permission to send a signal to a process or a process group " @@ -927,45 +1246,69 @@ msgid "" "``opts.group_signal`` is set, see :ref:`popen_handle:signal() `. It may appear for other reasons, details are unclear.)" msgstr "" +"SystemError: нет разрешения на отправку сигнала процессу или группе " +"процессов (это сообщение диагностики может появиться из-за особенностей " +"обработки зомби-процессов в Mac OS, когда установлен ``opts.group_signal``, " +"см. :ref:`popen_handle:signal() `. Оно также может появиться " +"по другим причинам, детали неясны)." msgid "" "The return is always ``true`` when a process is known to be dead (for " "example, after :ref:`popen_handle:wait() ` no signal will be " "sent, so no 'failure' may appear)." msgstr "" +"Если известно, что процесс был завершен, то в результате всегда возвращается" +" ``true`` (например, после выполнения :ref:`popen_handle:wait() ` не будет отправлено никакого сигнала, так что никакой ошибки не может" +" возникнуть)." msgid "" "``close()`` kills a process using SIGKILL and releases all resources " "associated with the popen handle." msgstr "" +"``close()`` принудительно завершает процесс через SIGKILL и освобождает все " +"ресурсы, связанные с дескриптором popen." msgid "Details about signaling:" -msgstr "" +msgstr "Подробная информация об отправке сигналов:" msgid "The signal is sent only when opts.keep_child is not set." -msgstr "" +msgstr "Сигнал отправляется только когда поле opts.keep_child не установлено." msgid "" "The signal is sent only when a process is alive according to the information" " available on current event loop iteration. (There is a gap here: a zombie " "may be signaled; it is harmless.)" msgstr "" +"Сигнал отправляется только когда процесс находится в рабочем состоянии " +"согласно информации, доступной на текущей итерации цикла событий. (Здесь " +"есть слабое место: сигнал может быть отправлен зомби-процессу, но это не " +"представляет никакой угрозы)." msgid "" "The signal is sent to a process or a process group depending on " "``opts.group_signal``. (See :ref:`popen.new() ` for details of " "group signaling)." msgstr "" +"Сигнал отправляется процессу или группе процессов в зависимости от " +"``opts.group_signal``. (Для подробной информации о групповых сигналах " +"смотрите :ref:`popen.new() `)." msgid "" "Resources are released regardless whether or not a signal sending succeeds: " "fds are closed, memory is released, the handle is marked as closed." msgstr "" +"Ресурсы освобождаются вне зависимости от того, успешно ли отправился сигнал:" +" дескрипторы файлов закрываются, память освобождается, а дескриптор popen " +"помечается как закрытый." msgid "" "No operation is possible on a closed handle except ``close()``, which is " "always successful on a closed handle (idempotence)." msgstr "" +"Над закрытым дескриптором невозможно выполнять никакие операции кроме " +"``close()``, которая всегда выполняется успешно над закрытым дескриптором " +"(идемпотентность)." msgid "" "``close()`` may return ``true`` or ``nil, err``, but it always frees the " @@ -973,9 +1316,13 @@ msgid "" "The return values are purely informational: they are for logging or some " "kind of reporting." msgstr "" +"``close()`` может вернуть ``true`` или ``nil, err``, но она всегда " +"освобождает ресурсы дескриптора. Поэтому для того, кто отправил сигнал, " +"любое возвращаемое значение означает успешное выполнение. Возвращаемые " +"значения только дают информацию для логирования или составления отчетов." msgid "**Handle fields**" -msgstr "" +msgstr "**Поля дескриптора**" msgid "" "popen_handle.pid\n" @@ -986,12 +1333,21 @@ msgid "" "popen_handle.stdout\n" "popen_handle.stderr" msgstr "" +"popen_handle.pid\n" +"popen_handle.command\n" +"popen_handle.opts\n" +"popen_handle.status\n" +"popen_handle.stdin\n" +"popen_handle.stdout\n" +"popen_handle.stderr" msgid "See :ref:`popen_handle:info() ` for details." msgstr "" +"За более подробной информацией обратитесь к :ref:`popen_handle:info() " +"`." msgid "**Module constants**" -msgstr "" +msgstr "**Константы модуля**" msgid "" "- popen.opts\n" @@ -1014,3 +1370,22 @@ msgid "" " - OPEN (== 'open')\n" " - CLOSED (== 'closed')" msgstr "" +"- popen.opts\n" +" - INHERIT (== 'inherit')\n" +" - DEVNULL (== 'devnull')\n" +" - CLOSE (== 'close')\n" +" - PIPE (== 'pipe')\n" +"\n" +"- popen.signal\n" +" - SIGTERM (== 9)\n" +" - SIGKILL (== 15)\n" +" - ...\n" +"\n" +"- popen.state\n" +" - ALIVE (== 'alive')\n" +" - EXITED (== 'exited')\n" +" - SIGNALED (== 'signaled')\n" +"\n" +"- popen.stream\n" +" - OPEN (== 'open')\n" +" - CLOSED (== 'closed')"