You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* ``myapp.lua`` contains ``net.box`` requests used to interact with a :ref:`sample database <getting_started_net_box_sample_db>`. These requests are explained below in the :ref:`getting_started_net_box_developing_app` section.
65
65
66
66
67
+
.. _getting_started_net_box_interactive:
67
68
68
-
.. _getting_started_net_box_developing_app:
69
+
Making net.box requests interactively
70
+
-------------------------------------
69
71
70
-
Developing the application
71
-
--------------------------
72
+
To try out ``net.box`` requests in the interactive console, you need to start sample applications:
73
+
74
+
1. Start the :ref:`sample_db <getting_started_net_box_sample_db>` application using ``tt start``:
75
+
76
+
.. code-block:: console
77
+
78
+
$ tt start sample_db
79
+
80
+
2. Start the :ref:`net_box <getting_started_net_box_creating-app>` application:
81
+
82
+
.. code-block:: console
83
+
84
+
$ tt start net_box
85
+
86
+
3. Connect to ``net_box:instance001`` using ``tt connect``:
87
+
88
+
.. code-block:: console
89
+
90
+
$ tt connect net_box:instance001
91
+
• Connecting to the instance...
92
+
• Connected to net_box:instance001
93
+
94
+
net_box:instance001>
95
+
96
+
In the instance's console, you can create a ``net.box`` connection and try out data operations.
97
+
98
+
99
+
100
+
.. _getting_started_net_box_creating_connection:
72
101
73
102
Creating a net.box connection
74
103
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -225,45 +254,6 @@ The ``connection:close()`` method can be used to close the connection when it is
225
254
:end-before: end
226
255
:dedent:
227
256
257
+
.. NOTE::
228
258
229
-
230
-
.. _getting_started_net_box_interactive:
231
-
232
-
Making net.box requests interactively
233
-
-------------------------------------
234
-
235
-
To try out ``net.box`` requests in the interactive console, you need to start sample applications:
236
-
237
-
1. Start the :ref:`sample_db <getting_started_net_box_sample_db>` application using ``tt start``:
238
-
239
-
.. code-block:: console
240
-
241
-
$ tt start sample_db
242
-
243
-
2. Start the :ref:`net_box <getting_started_net_box_creating-app>` application:
244
-
245
-
.. code-block:: console
246
-
247
-
$ tt start net_box
248
-
249
-
3. Connect to ``net_box:instance001`` using ``tt connect``:
250
-
251
-
.. code-block:: console
252
-
253
-
$ tt connect net_box:instance001
254
-
• Connecting to the instance...
255
-
• Connected to net_box:instance001
256
-
257
-
net_box:instance001>
258
-
259
-
In the instance's console, you can create a ``net.box`` connection and try out data operations described in :ref:`getting_started_net_box_developing_app`:
You can find the example with all the requests above on GitHub: `net_box <https://github.com/tarantool/doc/tree/latest/doc/code_snippets/snippets/connectors/instances.enabled/net_box>`_.
0 commit comments