You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/reference/reference_lua/compat.rst
+20-3Lines changed: 20 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -3,9 +3,6 @@
3
3
Module compat
4
4
=============
5
5
6
-
Module ``compat`` is introduced since version 2.11.0-rc.
7
-
8
-
9
6
The usual way to handle compatibility problems is to introduce an option for a new behavior and leave the old one by default.
10
7
It is not always the perfect way.
11
8
@@ -44,6 +41,26 @@ If you want to explicitly secure every behavior in ``compat``, you can do it man
44
41
You should place this commands at the beginning of code in your ``init.lua`` file. In this way, you are guaranteed to get the same behavior on any other Tarantool version.
45
42
See a :doc:`tutorial on using compat <./compat/compat_tutorial>` for more examples.
46
43
44
+
Configuration options
45
+
---------------------
46
+
47
+
Another way to handle compatibility issues is setting the ``compat.*`` :ref:`configuration options <configuration_reference_compat>`.
48
+
Similarly to the ``compat`` Lua module options, the configuration options can have
49
+
values ``new`` and ``old``. The set of configuration options matches the set of
50
+
options available in the ``compat`` module.
51
+
52
+
Below is an example fragment of a YAML configuration file:
Copy file name to clipboardExpand all lines: doc/reference/reference_lua/compat/box_cfg_replication_sync_timeout.rst
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -3,6 +3,8 @@
3
3
Default value for replication_sync_timeout
4
4
==========================================
5
5
6
+
Option: ``box_cfg_replication_sync_timeout``
7
+
6
8
Having a non-zero :ref:`replication_sync_timeout <cfg_replication-replication_sync_timeout>` gives a user the false assumption that the ``box.cfg{replication = ...}`` call returns only when the configured node is synced with all the other nodes.
7
9
This is mostly true for the big ``replication_sync_timeout`` values, but it is not 100% guaranteed.
8
10
In other words, a user still has to check if the node is synced, or the sync just timed out.
Copy file name to clipboardExpand all lines: doc/reference/reference_lua/compat/fiber_channel_close_mode.rst
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -3,6 +3,8 @@
3
3
Fiber channel close mode
4
4
========================
5
5
6
+
Option: ``fiber_channel_close_mode``
7
+
6
8
Before the change, there was an unexpected behavior when using ``channel:close()`` because it closed the channel entirely and discarded all unread events.
0 commit comments