Skip to content

Commit 3d9d74d

Browse files
committed
Update lua_call config description
1 parent 39e7d27 commit 3d9d74d

File tree

4 files changed

+3
-42
lines changed

4 files changed

+3
-42
lines changed

doc/code_snippets/snippets/replication/instances.enabled/supervised_failover/source.yaml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ credentials:
55
roles: [ replication ]
66
privileges:
77
- permissions: [ execute ]
8-
functions: [ 'failover.execute' ]
8+
lua_call: [ 'failover.execute' ]
99

1010
iproto:
1111
advertise:
@@ -23,8 +23,6 @@ failover:
2323
keepalive_interval: 5
2424
renew_interval: 1
2525

26-
roles: [ 'supervised_instance' ]
27-
2826
groups:
2927
group001:
3028
replicasets:

doc/code_snippets/snippets/replication/instances.enabled/supervised_failover/supervised_instance.lua

Lines changed: 0 additions & 23 deletions
This file was deleted.

doc/platform/replication/supervised_failover.rst

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -124,21 +124,6 @@ To configure a cluster to work with an external failover coordinator, follow the
124124
:end-at: failover.execute
125125
:dedent:
126126

127-
4. Create the ``failover.execute`` function in the application code.
128-
For example, you can create a :ref:`custom role <application_roles>` for this purpose:
129-
130-
.. literalinclude:: /code_snippets/snippets/replication/instances.enabled/supervised_failover/supervised_instance.lua
131-
:language: lua
132-
:dedent:
133-
134-
Then, you need to enable this role for all storage instances:
135-
136-
.. literalinclude:: /code_snippets/snippets/replication/instances.enabled/supervised_failover/source.yaml
137-
:language: yaml
138-
:start-at: supervised_instance
139-
:end-before: groups:
140-
:dedent:
141-
142127
5. (Optional) Configure options that control how a failover coordinator operates in the :ref:`failover <configuration_reference_failover>` section:
143128

144129
.. literalinclude:: /code_snippets/snippets/replication/instances.enabled/supervised_failover/source.yaml

doc/reference/configuration/configuration_reference.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1445,7 +1445,8 @@ credentials.users.*
14451445

14461446
.. confval:: <user_or_role_name>.privileges.lua_call
14471447

1448-
Whether this user or a user with this role can call any global user-defined Lua function.
1448+
A list of global user-defined Lua functions that this user or a user with this role can call.
1449+
To allow calling all such functions, specify the ``all`` value.
14491450

14501451
.. _configuration_reference_credentials_privileges_sql:
14511452

0 commit comments

Comments
 (0)