@@ -11,6 +11,100 @@ This topic describes all :ref:`configuration parameters <configuration>` provide
11
11
Most of the configuration options described in this reference can be applied to a specific instance, replica set, group, or to all instances globally.
12
12
To do so, you need to define the required option at the :ref: `specified level <configuration_scopes >`.
13
13
14
+
15
+
16
+ .. _configuration_reference_app :
17
+
18
+ app
19
+ ---
20
+
21
+ Using Tarantool as an application server, you can run your own Lua applications.
22
+ In the ``app `` section, you can load the application and provide an application configuration in the ``app.cfg `` section.
23
+
24
+ .. NOTE ::
25
+
26
+ ``app `` can be defined in any :ref: `scope <configuration_scopes >`.
27
+
28
+ - :ref: `app.cfg <configuration_reference_app_cfg >`
29
+ - :ref: `app.file <configuration_reference_app_file >`
30
+ - :ref: `app.module <configuration_reference_app_module >`
31
+
32
+
33
+ .. _configuration_reference_app_cfg :
34
+
35
+ .. confval :: app.cfg
36
+
37
+ **Since: ** :doc: `3.0.0 </release/3.0.0 >`.
38
+
39
+ A configuration of the application loaded using ``app.file `` or ``app.module ``.
40
+
41
+ **Example **
42
+
43
+ In the example below, the application is loaded from the ``myapp.lua `` file placed next to the YAML configuration file:
44
+
45
+ .. literalinclude :: /code_snippets/snippets/config/instances.enabled/application/config.yaml
46
+ :language: yaml
47
+ :end-at: greeting
48
+ :dedent:
49
+
50
+ Example on GitHub: `application <https://github.com/tarantool/doc/tree/latest/doc/code_snippets/snippets/config/instances.enabled/application >`_
51
+
52
+ |
53
+ | Type: map
54
+ | Default: nil
55
+ | Environment variable: TT_APP_CFG
56
+
57
+
58
+ .. _configuration_reference_app_file :
59
+
60
+ .. confval :: app.file
61
+
62
+ **Since: ** :doc: `3.0.0 </release/3.0.0 >`.
63
+
64
+ A path to a Lua file to load an application from.
65
+
66
+ |
67
+ | Type: string
68
+ | Default: nil
69
+ | Environment variable: TT_APP_FILE
70
+
71
+
72
+ .. _configuration_reference_app_module :
73
+
74
+ .. confval :: app.module
75
+
76
+ **Since: ** :doc: `3.0.0 </release/3.0.0 >`.
77
+
78
+ A Lua module to load an application from.
79
+
80
+ **Example **
81
+
82
+ The ``app `` section can be placed in any :ref: `configuration scope <configuration_scopes >`.
83
+ As an example use case, you can provide different applications for storages and routers in a sharded cluster:
84
+
85
+ .. code-block :: yaml
86
+
87
+ groups :
88
+ storages :
89
+ app :
90
+ module : storage
91
+ # ...
92
+ routers :
93
+ app :
94
+ module : router
95
+ # ...
96
+
97
+ |
98
+ | Type: string
99
+ | Default: nil
100
+ | Environment variable: TT_APP_MODULE
101
+
102
+
103
+
104
+
105
+
106
+
107
+
14
108
.. _configuration_reference_audit :
15
109
16
110
audit_log
@@ -2586,8 +2680,8 @@ The ``process`` section defines configuration parameters of the Tarantool proces
2586
2680
If not specified, defaults to the current working directory.
2587
2681
2588
2682
Other directory and file parameters, if set as relative paths,
2589
- are interpreted as relative to ``process.work_dir ``. For example,
2590
- :ref: `directories for storing snapshots and write-ahead logs <configuration_options_directories >`
2683
+ are interpreted as relative to ``process.work_dir ``, for example, directories for storing
2684
+ :ref: `snapshots and write-ahead logs <configuration_persistence >`.
2591
2685
2592
2686
|
2593
2687
| Type: string
@@ -2974,7 +3068,7 @@ The ``replication`` section defines configuration parameters related to :ref:`re
2974
3068
roles
2975
3069
-----
2976
3070
2977
- This section describes configuration parameters related to roles.
3071
+ This section describes configuration parameters related to :ref: ` application roles < application_roles >` .
2978
3072
2979
3073
.. NOTE ::
2980
3074
@@ -2990,6 +3084,11 @@ This section describes configuration parameters related to roles.
2990
3084
2991
3085
**Since: ** :doc: `3.0.0 </release/3.0.0 >`.
2992
3086
3087
+ Specify the roles of an instance.
3088
+ To specify a role's configuration, use the :ref: `roles_cfg <configuration_reference_roles_cfg >` option.
3089
+
3090
+ See also: :ref: `configuration_application_roles `
3091
+
2993
3092
|
2994
3093
| Type: array
2995
3094
| Default: nil
@@ -3002,6 +3101,12 @@ This section describes configuration parameters related to roles.
3002
3101
3003
3102
**Since: ** :doc: `3.0.0 </release/3.0.0 >`.
3004
3103
3104
+ Specify a role's configuration.
3105
+ This option accepts a role name as the key and a role's configuration as the value.
3106
+ To specify the roles of an instance, use the :ref: `roles <configuration_reference_roles >` option.
3107
+
3108
+ See also: :ref: `configuration_application_roles `
3109
+
3005
3110
|
3006
3111
| Type: map
3007
3112
| Default: nil
0 commit comments