Skip to content

Commit 4b076ee

Browse files
committed
Update tutorial files
1 parent f820361 commit 4b076ee

File tree

7 files changed

+262
-218
lines changed

7 files changed

+262
-218
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Improving MySQL with Tarantool
2+
3+
A sample application that is used in [Improving MySQL with Tarantool](https://www.tarantool.io/en/doc/latest/how-to/sql/improving_mysql/) tutorial.
4+
5+
## Running
6+
7+
To run applications placed in [instances.enabled](instances.enabled), go to the `mysql` directory in the terminal and execute the `tt start` command, for example:
8+
9+
```console
10+
$ tt start example
11+
```
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
app:
2+
file: 'example.lua'
3+
4+
groups:
5+
group001:
6+
replicasets:
7+
replicaset001:
8+
instances:
9+
instance001:
10+
iproto:
11+
listen: "3301"
12+
memtx:
13+
memory: 128 * 1024 * 1024
14+
min_tuple_size: 16
15+
max_tuple_size: 128 * 1024 * 1024
16+
wal:
17+
mode: "none"
18+
wal_max_size: 56 * 1024 * 1024
19+
snapshot:
20+
by_interval: 60 * 60
21+
count: 6
22+
log:
23+
level: 7
24+
fiber:
25+
too_long_threshold: 0.5
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
-- example.lua --
2+
3+
box.schema.user.grant('guest','read,write,execute','universe')
4+
5+
local function bootstrap()
6+
if not box.space.mysqldaemon then
7+
s = box.schema.space.create('mysqldaemon')
8+
s:create_index('primary',
9+
{type = 'tree', parts = {1, 'unsigned'}, if_not_exists = true})
10+
end
11+
if not box.space.mysqldata then
12+
t = box.schema.space.create('mysqldata')
13+
t:create_index('primary',
14+
{type = 'tree', parts = {1, 'unsigned'}, if_not_exists = true})
15+
end
16+
end
17+
bootstrap()
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
instance001:

doc/contributing/docs/markup/code.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,9 @@ For code snippets, we use the ``code-block:: language``
5656
You can enable syntax highlighting if you specify the language for the snippet.
5757
The most commonly used highlighting languages are:
5858

59-
* ``tarantoolsession``interactive Tarantool session,
59+
* ``tarantoolsession`` -- interactive Tarantool session,
6060
where command lines start with ``tarantool>`` prompt.
61-
* ``console``interactive console session, where command lines
61+
* ``console`` -- interactive console session, where command lines
6262
start with ``$`` or ``#``.
6363
* ``lua``, ``bash`` or ``c`` for programming languages.
6464
* ``text`` for cases when we want the code block to have no highlighting.

0 commit comments

Comments
 (0)