Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
T
tarantool
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
core
tarantool
Commits
76bbd9c4
Commit
76bbd9c4
authored
9 years ago
by
ocelot-inc
Browse files
Options
Downloads
Patches
Plain Diff
conn:eval
parent
ef66b75e
Loading
Loading
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
doc/sphinx/book/box/authentication.rst
+2
-0
2 additions, 0 deletions
doc/sphinx/book/box/authentication.rst
doc/sphinx/reference/net_box.rst
+13
-3
13 additions, 3 deletions
doc/sphinx/reference/net_box.rst
with
15 additions
and
3 deletions
doc/sphinx/book/box/authentication.rst
+
2
−
0
View file @
76bbd9c4
...
...
@@ -165,6 +165,8 @@ tuple in the _user space, and then drops the user.
The maximum number of users is 32.
.. _privileges:
===========================================================
Privileges and the _priv space
===========================================================
...
...
This diff is collapsed.
Click to expand it.
doc/sphinx/reference/net_box.rst
+
13
−
3
View file @
76bbd9c4
...
...
@@ -5,9 +5,9 @@
--------------------------------------------------------------------------------
The ``net.box`` package contains connectors to remote database systems. One
variant,
``box.net.sql``
, is for connecting to MySQL or MariaDB or PostgreSQL —
variant,
to be discussed later
, is for connecting to MySQL or MariaDB or PostgreSQL —
that variant is the subject of the :ref:`SQL DBMS plugins <dbms-plugins>` appendix.
In this section the subject is the built-in variant, ``
box.net
``. This is for
In this section the subject is the built-in variant, ``
net.box
``. This is for
connecting to tarantool servers via a network.
Call ``require('net.box')`` to get a ``net.box`` object, which will be called
...
...
@@ -58,7 +58,7 @@ necessary to prioritize requests or to use different authentication ids.
conn = net_box.new('localhost', 3301)
conn = net_box.new('127.0.0.1', box.cfg.listen, {
wait_connect = false,
user = '
guest
',
user = '
boxer
',
password = ''
})
...
...
@@ -153,6 +153,16 @@ necessary to prioritize requests or to use different authentication ids.
Example: ``conn:call('function5')``
.. method:: eval(Lua-string)
:samp:`conn:eval({Lua-string})` evaluates and executes the expression
in Lua-string, which may be any statement or series of statements.
An :ref:`execute privilege <privileges>` is required; if the user does not have it,
an administrator may grant it with
:codenormal:`box.schema.user.grant(`:codeitalic:`username`:codenormal:`,'execute','universe')`.
Example: ``conn:eval('return 5+5')``
.. method:: timeout(timeout)
``timeout(...)`` is a wrapper which sets a timeout for the request that
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment