Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3.0 config: replication reference #3834

Merged
merged 12 commits into from
Nov 23, 2023
Merged

3.0 config: replication reference #3834

merged 12 commits into from
Nov 23, 2023

Conversation

andreyaksenov
Copy link
Contributor

@andreyaksenov andreyaksenov commented Nov 3, 2023

This PR adds reference for configuration options related to replication. Here are a summary of all changes:

  • The code_snippets/snippets folder contains runnable tt applications referenced in docs. In addition to exiting examples, this PR adds the bootstrap_leader, peers, and sharding samples. These samples are included in a reference page in various places to demonstrate various features. Moreover, all these samples will be reused in other places in docs (tutorials, how-tos, etc.) for keeping consistency and making sure all the examples work fine.
  • In addition to config and config.etcd, the following sections are added to Configuration reference:
  • Added/updated READMEs.
  • Updated tt configs to the 2.0 version.

Note that replication.anon and database.hot_standby are not documented yet. Will create separate tickets for documenting these options (#3857 and #3858).

Links to new configuration options in main docs are not updated yet. Most likely, this will be done in separate PRs when updating corresponding topics.

Additional changes in the base topic (not directly related to this PR):
- https://docs.d.tarantool.io/en/doc/3.0-config-replication/concepts/configuration/#configuration-scopes-replica-set-example
- https://docs.d.tarantool.io/en/doc/3.0-config-replication/concepts/configuration/#access-control

@andreyaksenov andreyaksenov force-pushed the 3.0-config-replication branch 2 times, most recently from d7605c0 to 7dbe024 Compare November 3, 2023 13:34
@andreyaksenov andreyaksenov force-pushed the 3.0-config-etcd branch 19 times, most recently from 82bc916 to c3e8597 Compare November 8, 2023 12:16
@andreyaksenov andreyaksenov linked an issue Nov 8, 2023 that may be closed by this pull request
@andreyaksenov andreyaksenov force-pushed the 3.0-config-etcd branch 2 times, most recently from fdf8244 to 0c5d37c Compare November 10, 2023 10:48
@andreyaksenov andreyaksenov force-pushed the 3.0-config-etcd branch 2 times, most recently from c24f5b0 to bb1784e Compare November 13, 2023 07:20
Base automatically changed from 3.0-config-etcd to 3.0 November 13, 2023 10:17

# The maximum number of old log files to retain.
log_maxbackups: 10
# Tarantoolctl artifacts layout compatibility: if set to true tt will not create application
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Tarantoolctl artifacts layout compatibility: if set to true tt will not create application
# Tarantoolctl artifacts layout compatibility: if set to true, tt will not create application

same for

  • doc/code_snippets/snippets/replication/tt.yaml
  • doc/code_snippets/snippets/sharding/tt.yaml

Copy link
Contributor Author

@andreyaksenov andreyaksenov Nov 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, cannot fix this as tt.yaml is generated automatically using tt init. So, this is a reminder that we need to cteate a process for reviewing user-facing texts written by the tt development team.

restart_on_failure: false
app:
# Directory that stores various instance runtime
# artifacts like console socket, PID file, etc.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# artifacts like console socket, PID file, etc.
# artifacts such as console socket, PID file, etc.

same for

  • doc/code_snippets/snippets/replication/tt.yaml
  • doc/code_snippets/snippets/sharding/tt.yaml

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The same as above

database
--------

The ``database`` section defines database-specific configuration parameters, such as an instance's read-write mode, transaction isolation level, and so on.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The ``database`` section defines database-specific configuration parameters, such as an instance's read-write mode, transaction isolation level, and so on.
The ``database`` section defines database-specific configuration parameters, such as an instance's read-write mode or transaction isolation level.

- ``rw``: an instance is in read-write mode.
- ``ro``: an instance is in read-only mode.

If this option is not specified explicitly, its default value depends on the number of instances in a replica set. For a single instance, the ``rw`` mode is used, while for multiple instances, the ``ro`` mode is used.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: If not specified explicitly, the default value depends on the number of instances in a replica set.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Much better, thanks


.. confval:: database.txn_timeout

A timeout (in seconds) after which the transaction is rolled back.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
A timeout (in seconds) after which the transaction is rolled back.
A timeout in seconds after which the transaction is rolled back.

Copy link
Contributor Author

@andreyaksenov andreyaksenov Nov 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you don't mind, I'd keep units in round brackets to emphasise this information a bit.


.. confval:: iproto.net_msg_max

To handle messages, Tarantool allocates fibers.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link to fiber definition?

Tarantool restricts how many messages the fibers handle,
so that some pending requests are blocked.

- On powerful systems, increase ``net_msg_max`` and the scheduler
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- On powerful systems, increase ``net_msg_max`` and the scheduler
- On powerful systems, increase ``net_msg_max``, and the scheduler

- On powerful systems, increase ``net_msg_max`` and the scheduler
starts processing pending requests immediately.

- On weaker systems, decrease ``net_msg_max`` and the overhead
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- On weaker systems, decrease ``net_msg_max`` and the overhead
- On weaker systems, decrease ``net_msg_max``, and the overhead

Comment on lines 674 to 675
may decrease although this may take some time because the
scheduler must wait until already-running requests finish.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider splitting this long sentence in two separate sentences

Comment on lines 974 to 976
* ``off``

A node doesn't participate in the election activities.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* ``off``
A node doesn't participate in the election activities.
* ``off``: a node doesn't participate in the election activities.

Same for other possible values below

@andreyaksenov andreyaksenov merged commit 431ab13 into 3.0 Nov 23, 2023
1 check passed
@andreyaksenov andreyaksenov deleted the 3.0-config-replication branch November 23, 2023 09:49
andreyaksenov added a commit that referenced this pull request Dec 6, 2023
Updated configuration reference with options related to replication.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants