Commit Briefs

df49871cda Olga Arkhangelskaia

box: fix box.info:memory() (OKriw/gh-4688-box-info-memory)

Fix the return value of box.info:memory(). It used to return the same table as the box.info(). If one removes metatable of the box.info:memory(): tarantool> setmetatable(box.info:memory(), nil) --- - cache: 0 lua: 1855568 data: 37976 index: 1196032 net: 589824 tx: 0 version: 2.5.0-158-g667145aff package: Tarantool When box.info:memory is called, it has box.info table as the first argument (see https://www.lua.org/manual/5.1/manual.html#2.8). While printing the table, lbox_info_memory_call adds box.info.memory's fields to the box.info table. To avoid this effect and return just box.info.memory we put an empty table on the Lua stack at the beginning of the lbox_info_memory_call function. Instead adding fields to box.info table lbox_info_memory_call fills that empty table. Closes #4688


a609505153 Nikita Pettik

txm: introduce dirty tuples (hotfix)

Add forgotten part of the original commit. Part of #4897


30c57bb3eb Nikita Pettik

sql: change implicit cast for assignment

This patch changes implicit cast for assignment. Closes #3809 Needed for #4159 Part of #4230 @TarantoolBot document Title: change implicit cast for comparison After this patch, these rules will apply during the implicit cast: | | STRING | BINARY | BOOLEAN | INTEGER | UNSIGNED | DOUBLE | | :--- | :---: | :---: | :---: | :---: | :---: | :---: | | STRING | A | N | N | N | N | N | | BINARY | N | A | N | N | N | N | | BOOLEAN | N | N | A | N | N | N | | INTEGER | N | N | N | A | S | Aa | | UNSIGNED | N | N | N | A | A | Aa | | DOUBLE | N | N | N | Sa | Sa | A | In this table, the types of the assigned value are on the left, and the types that should be after the assignment are at the top. 'A' - the assignment will be completed. 'N' - the assignment won't be completed. 'S' - the appointment may be unsuccessful. 'a' - after assignment, the resulting value may be approximated. Rules for numeric values are these: 1) Loss of significant digits (overflow) is an error. 2) Loss of insignificant digits is not an error. Example: ``` tarantool> box.execute([[CREATE TABLE t1(i INT PRIMARY KEY);]]) tarantool> box.execute([[INSERT INTO t1 VALUES ('1');]]) --- - null - 'Type mismatch: can not convert 1 to integer' ... tarantool> box.execute('INSERT INTO t1 VALUES (1.2345);') tarantool> box.execute('SELECT * FROM t1;') --- - metadata: - name: I type: integer rows: - [1] ... tarantool> box.execute([[CREATE TABLE t2(t text PRIMARY KEY);]]) tarantool> box.execute([[INSERT INTO t2 VALUES (1);]]) --- - null - 'Type mismatch: can not convert 1 to string' ... ```


c8c8638765 Nikita Pettik

txm: save txn in txn_stmt

There is a lot of places in transaction engine (see futher commits) where it's convenient to store just a pointer to tx statement while having a way to get the transaction itself by this pointer. Let's store a pointer to TX in TX statement for that purpose. Part of #4897


39c13db14b Nikita Pettik

txm: introduce dirty tuples

If the tuple is marked as dirty that usually means that it was somehow affected by a transaction. If a tuple found in index is dirty - we cannot immediately return to user, instead we must clarify it in transaction manager. Part of #4897


8078509f88 Nikita Pettik

Update license file (2020)


c81d9a4115 Nikita Pettik

Check data_offset overflow in struct tuple

data_offset member of tuple is uint16_t now. At the same time this field is calculated from field_map_size which is uint32_t. That could lead to overflows and crashes. Fixes #5084


bf047ad442 Nikita Pettik

sql: set field_type in mem_set_*() functions

After this patch, the mem_set _*() functions will set the mem field type along with its MEM type flag. This will allow us to be sure that the MEM type and field type are set correctly, which is important when converting values from one type to another. Needed for #3809


0ab21ac9ee Kirill Yukhin

Fix luacheck warnings in src/box/lua/

Part of #4681 Reviewed-by: Vladislav Shpilevoy <v.shpilevoy@tarantool.org> Co-authored-by: Vladislav Shpilevoy <v.shpilevoy@tarantool.org>


3af79e70b5 Kirill Yukhin

Fix luacheck warnings in src/lua/

Part of #4681 Reviewed-by: Vladislav Shpilevoy <v.shpilevoy@tarantool.org> Reviewed-by: Igor Munkin <imun@tarantool.org> Co-authored-by: Vladislav Shpilevoy <v.shpilevoy@tarantool.org> Co-authored-by: Igor Munkin <imun@tarantool.org>


Branches



























































































Tags

Tree

.appveyor.ymlcommits | blame
.editorconfigcommits | blame
.gdbinitcommits | blame
.github/
.gitignorecommits | blame
.gitlab-ci.ymlcommits | blame
.gitlab.mkcommits | blame
.gitmodulescommits | blame
.luacheckrccommits | blame
.travis.mkcommits | blame
.travis.ymlcommits | blame
AUTHORScommits | blame
CMakeLists.txtcommits | blame
Dockerfile.staticbuildcommits | blame
Doxyfilecommits | blame
Doxyfile.API.incommits | blame
FreeBSD/
Jenkinsfilecommits | blame
LICENSEcommits | blame
README.FreeBSDcommits | blame
README.MacOSXcommits | blame
README.OpenBSDcommits | blame
README.mdcommits | blame
TODOcommits | blame
apk/
asan/
cmake/
debian/
doc/
extra/
rpm/
rump/
snapcraft.yamlcommits | blame
src/
test/
test-run$commits | blame
third_party/
tools/

README.md

# Tarantool

[![Build Status][travis-badge]][travis-url]
[![Build Status][gitlab-ci-badge]][gitlab-ci-url]
[![Code Coverage][coverage-badge]][coverage-url]
[![Telegram][telegram-badge]][telegram-url]
[![Slack][slack-badge]][slack-url]
[![Gitter][gitter-badge]][gitter-url]
[![Google Groups][groups-badge]][groups-url]

https://tarantool.io/en/

Patch submissions and discussion of particular patches https://lists.tarantool.org/mailman/listinfo/tarantool-patches/

General development discussions https://lists.tarantool.org/mailman/listinfo/tarantool-discussions/

Tarantool is an in-memory database and application server.

Key features of the application server:
 * 100% compatible drop-in replacement for Lua 5.1,
   based on LuaJIT 2.1.
   Simply use `#!/usr/bin/tarantool` instead of
   `#!/usr/bin/lua` in your script.
 * full support for Lua modules and a rich set of
   own modules, including cooperative multitasking,
   non-blocking I/O, access to external databases, etc

Key features of the database:
 * ANSI SQL, including views, joins, referential
   and check constraints
 * MsgPack data format and MsgPack based
   client-server protocol
 * two data engines: 100% in-memory with
   optional persistence and an own implementation of LSM-tree, 
   to use with large data sets
 * multiple index types: HASH, TREE, RTREE, BITSET
 * asynchronous master-master replication
 * authentication and access control
 * the database is just a C extension to the
   application server and can be turned off

Supported platforms are Linux/x86, FreeBSD/x86 and OpenBSD/x86, Mac OS X.

Tarantool is ideal for data-enriched components of
scalable Web architecture: queue servers, caches,
stateful Web applications.

To download and install Tarantool as a binary package for your OS, please visit
https://tarantool.io/en/download/.

To build Tarantool from source, see detailed instructions in the Tarantool
documentation at https://tarantool.io/en/doc/2.1/dev_guide/building_from_source/.

Please report bugs at https://github.com/tarantool/tarantool/issues
We also warmly welcome your feedback in the discussion mailing
list, tarantool@googlegroups.com.

Thank you for your interest in Tarantool!

[travis-badge]: https://api.travis-ci.org/tarantool/tarantool.svg?branch=master
[travis-url]: https://travis-ci.org/tarantool/tarantool
[gitlab-ci-badge]: https://gitlab.com/tarantool/tarantool/badges/master/pipeline.svg
[gitlab-ci-url]: https://gitlab.com/tarantool/tarantool/commits/master
[coverage-badge]: https://coveralls.io/repos/github/tarantool/tarantool/badge.svg?branch=master
[coverage-url]: https://coveralls.io/github/tarantool/tarantool?branch=master
[groups-badge]: https://img.shields.io/badge/Google-Groups-orange.svg
[groups-url]: https://groups.google.com/forum/#!forum/tarantool
[telegram-badge]: https://img.shields.io/badge/Telegram-join%20chat-blue.svg
[telegram-url]: http://telegram.me/tarantool
[slack-badge]: https://img.shields.io/badge/Slack-join%20chat-lightgrey.svg
[slack-url]: http://slack.tarantool.org/
[gitter-badge]: https://badges.gitter.im/Join%20Chat.svg
[gitter-url]: https://gitter.im/tarantool/tarantool