tarantool / tarantool/doc

roles and scripts metadata

Open
#5,072 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

3.4 config reference
Dominant language
CSS
Stars
15
Forks
49
Avg merge
1d 13h
Merged PRs (30d)
3

Description

After this ticket, document https://github.com/tarantool/doc/issues/5179

Related dev. issue(s): https://github.com/tarantool/tarantool/issues/10182
Product: Tarantool
Since: 3.4
Root document: https://www.tarantool.io/en/doc/latest/reference/configuration/configuration_reference/#app
SME: @ grafin

Details

Metadata can be specified for roles and scripts (module or file in app
config section) in lua files. To add metadata to a source file, a
comment must be added to the beginning of the file (or after a shebang).
The metadata comment must contain a YAML-formatted section begging with
'--- #tarantool.metadata.v1' line and ending with '...' line. Example:

-- This script will be loaded before the first box.cfg() call.
-- --- #tarantool.metadata.v1
-- early_load: true
-- ...
-- More comments can be added here.

Currently only 'early_load' tag is supported. Setting 'early_load' tag
makes it so that the tagged file will be loaded (required) before the
execution of box.cfg by the config module. During the preload phase
config:get() will not work, both for modules and app scripts.

Requested by @ grafin in https://github.com/tarantool/tarantool/commit/4f592623a8b82e88b701d4f289019727e330d117.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open the configuration reference's app section linked as the root document and review the metadata details in this issue. Document the YAML metadata block syntax, the early_load tag, its preload behavior, and the config:get() limitation for modules and app scripts. Done means the app configuration documentation covers these roles and scripts metadata rules.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.