Commit Briefs

51569221d2 Sergey Bronnikov

luajit: bump new version (ligurio/gh-xxxx-fix-missing-uclo)

* Fix BC_UCLO insertion for returns. Part of #8825 NO_DOC=LuaJIT submodule bump NO_TEST=LuaJIT submodule bump NO_CHANGELOG=LuaJIT submodule bump


0c53d22b58 Igor Munkin

exports: clean up LuaJIT public interfaces

There was a little mess in exports file regarding LuaJIT symbols to be visible from Tarantool binary, so some functions (e.g. <lua_tonumberx> and <lua_tointegerx>) were hidden unintentionally. As a result of the patch almost all public LuaJIT symbols are exported from Tarantool binary; there are still several functions reasonably hidden (you can find the rationale around the corresponding cases in the test file). Closes #3680 @TarantoolBot document Title: clean up LuaJIT exported functions The list of the LuaJIT-related functions being exported (i.e. public) from Tarantool should be updated. The actual list of the exported symbols can be found within changeset (either extra/exports file or related Lua test chunk).


5f6d367c51 Igor Munkin

compat: add is_new and is_old to options

It used to be somewhat complicated to check the effective value of a compat option, because `<option_name>.current` could contain 'default' state. This patch introduces helper functions that take care of that. The following alternatives were considered: * `compat.<option_name>.effective` - it is excessive in the presence if `current` and `default`, and is visible in serialization * `compat.<option_name>.get()` - while it is a function, it does only half of the work required, user still has to compare result to 'new' Closes #8807 @TarantoolBot document Title: Add `:is_new/old()` helpers to tarantool.compat options `compat.<option_name>.current` can be 'new', 'old' or 'default', thus when it is default there must be an additional check if `compat.<option_name>.default` is 'new'. It is handier to have a helper to deal with that instead of complicated `if`: * check if effective value is 'new' before the patch: ```lua if compat.<option_name>.current == 'new' or (compat.<option_name>.current == 'default' and compat.<option_name>.default == 'new') then ... end ``` * after the patch: ```lua if compat.<option_name>:is_new() then ... end ``` Please update [tutorial on using compat], maybe add an example to [Listing options details]. [tutorial on using compat]: https://www.tarantool.io/en/doc/latest/reference/reference_lua/compat/compat_tutorial/ [Listing options details]: https://www.tarantool.io/en/doc/latest/reference/reference_lua/compat/compat_tutorial/#listing-options-details


294f2d616c Alexander Turenko

config: introduce remaining vinyl options

This patch introduces all remaining vinyl options that have not been introduced before. Part of #8861 NO_DOC=Was already described before.


10ff3a31bf Alexander Turenko

config: fix error message during reload

Prior to this patch, if a cluster configuration was not present or an instance was not found in the configuration during a reload, the error would begin with 'Startup failure'. Now it starts with 'Reload failure' in these cases. Part of #8862 NO_DOC=fix of error message


443c29ca7f Alexander Turenko

test: run tests in config test suite in parallel

All the tests are independent and nothing prevents running them in parallel. The option to enable the parallel running was just forgotten. Part of #8862 NO_DOC=testing change NO_CHANGELOG=see NO_DOC


8868622721 Igor Munkin

test: fix tarantool process teardown

Test uses a popen module that starts tarantool process in background mode. Tarantool process started in background mode forks a new process and closes a parent, after that popen loses a PID of the started process and `ph:kill()` and `ph:terminate()` doesn't work anymore. It leads to non-terminated tarantool processes after running the test. Patch fixes that by running `kill` using os.execute with a PID of tarantool process written to a pid file. Follows up #6128 NO_CHANGELOG=fix test NO_DOC=fix test


e4fda4b7d1 Igor Munkin

box: fix shared lang between connected clients

Fixed the implementation of the box console. Before this fix, result of `\set language` is shared between clients via `console.connect`, despite the fact that clients have different `box.session.id`. Now the parameter of the selected language is stored by each client in his own `box.session.storage`. Fixes #8817 NO_DOC=bugfix


1ba84fe3b7 Vladimir Davydov

sql: use xregion_*() functions

This patch replaces region_*() functions with xregion_*() functions. NO_DOC=refactoring NO_TEST=refactoring NO_CHANGELOG=refactoring


51af059c10 Aleksandr Lyapunov

box: compare and hash msgpack value of double key field as double

1. Make double-formatted fields accept integer and float values. 2. Make indexes compare the values as double if the field key type is FIELD_TYPE_DOUBLE. 3. Make hashers cast double key field to double before hashing, so we are able to insert and select any int, uint, float or double if their value casted to double is equal (for double keys). Notes about tuple_compare.cc: Since now `mp_compare_double` casts any value placed in field to double it was renamed to `mp_compare_as_double` to not semantically conflict with existing `mp_compare_double_*` functions. Notes about tuple_hash.cc: The hashee cast result is encoded in MP_DOUBLE and hashed for backward compatibility reasons. Since now the field hashing function (tuple_hash_field) requires field type to hash the field correctly, a new parameter has been introduced. By the way added assertions to the generic `field_hash` to prevent invalid hashing for new precompiled hashers and made `key_hash_slowpath` static cause it's only used in this file. Closes #7483 Closes #5933 Unblocks tarantool/crud#298 @TarantoolBot document Title: It's not required to ffi-cast integral floating point to double anymore. The page describing tarantool data model states that: > In Lua, fields of the double type can only contain non-integer > numeric values... If the patch is merged this isn't the case anymore, so this statement and the code snippet below it should be updated. Link to the document: [Data storage](https://www.tarantool.io/en/doc/latest/concepts/data_model/value_store/#field-type-details). Affected segments: > double. The double field type exists mainly to be equivalent > to Tarantool/SQL’s DOUBLE data type. In msgpuck.h (Tarantool’s > interface to MsgPack), the storage type is MP_DOUBLE and the > size of the encoded value is always 9 bytes. In Lua, fields of > the double type can only contain non-integer numeric values and > cdata values with double floating-point numbers. Examples: 1.234, > -44, 1.447e+44. > > To avoid using the wrong kind of values inadvertently, use > ffi.cast() when searching or changing double fields. For example, > instead of space_object:insert{value} use ffi = require('ffi') > ... space_object:insert({ffi.cast('double',value)}). Example: > > ``` > s = box.schema.space.create('s', {format = {{'d', 'double'}}}) > s:create_index('ii') > s:insert({1.1}) > ffi = require('ffi') > s:insert({ffi.cast('double', 1)}) > s:insert({ffi.cast('double', tonumber('123'))}) > s:select(1.1) > s:select({ffi.cast('double', 1)}) > ```


Branches



























































































Tags

Tree

.editorconfigcommits | blame
.gdbinitcommits | blame
.gitattributescommits | blame
.github/
.gitignorecommits | blame
.gitmodulescommits | blame
.luacheckrccommits | blame
.pack.mkcommits | blame
.test.mkcommits | blame
AUTHORScommits | blame
CMakeLists.txtcommits | blame
CONTRIBUTING.mdcommits | blame
Doxyfilecommits | blame
Doxyfile.API.incommits | blame
FreeBSD/
LICENSEcommits | blame
README.FreeBSDcommits | blame
README.MacOSXcommits | blame
README.OpenBSDcommits | blame
README.mdcommits | blame
TODOcommits | blame
apk/
asan/
changelogs/
cmake/
debian/
doc/
extra/
perf/
rpm/
rump/
src/
static-build/
test/
test-run$commits | blame
third_party/
tools/

README.md

# Tarantool

[![Actions Status][actions-badge]][actions-url]
[![Code Coverage][coverage-badge]][coverage-url]
[![OSS Fuzz][oss-fuzz-badge]][oss-fuzz-url]
[![Telegram][telegram-badge]][telegram-url]
[![GitHub Discussions][discussions-badge]][discussions-url]
[![Stack Overflow][stackoverflow-badge]][stackoverflow-url]

[Tarantool][tarantool-url] is an in-memory computing platform consisting of a
database and an application server.

It is distributed under [BSD 2-Clause][license] terms.

Key features of the application server:

* Heavily optimized Lua interpreter with incredibly fast tracing JIT compiler,
  based on LuaJIT 2.1.
* Cooperative multitasking, non-blocking IO.
* [Persistent queues][queue].
* [Sharding][vshard].
* [Cluster and application management framework][cartridge].
* Access to external databases such as [MySQL][mysql] and [PostgreSQL][pg].
* A rich set of built-in and standalone [modules][modules].

Key features of the database:

* MessagePack data format and MessagePack based client-server protocol.
* Two data engines: 100% in-memory with complete WAL-based persistence and an
  own implementation of LSM-tree, to use with large data sets.
* Multiple index types: HASH, TREE, RTREE, BITSET.
* Document oriented JSON path indexes.
* Asynchronous master-master replication.
* Synchronous quorum-based replication.
* RAFT-based automatic leader election for the single-leader configuration.
* Authentication and access control.
* ANSI SQL, including views, joins, referential and check constraints.
* [Connectors][connectors] for many programming languages.
* The database is a C extension of the application server and can be turned
  off.

Supported platforms are Linux (x86_64, aarch64), Mac OS X (x86_64, M1), FreeBSD
(x86_64).

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 or using
Docker, please see the [download instructions][download].

To build Tarantool from source, see detailed [instructions][building] in the
Tarantool documentation.

To find modules, connectors and tools for Tarantool, check out our [Awesome
Tarantool][awesome-list] list.

Please report bugs to our [issue tracker][issue-tracker]. We also warmly
welcome your feedback on the [discussions][discussions-url] page and questions
on [Stack Overflow][stackoverflow-url].

We accept contributions via pull requests. Check out our [contributing
guide][contributing].

Thank you for your interest in Tarantool!

[actions-badge]: https://github.com/tarantool/tarantool/workflows/release/badge.svg
[actions-url]: https://github.com/tarantool/tarantool/actions
[coverage-badge]: https://coveralls.io/repos/github/tarantool/tarantool/badge.svg?branch=master
[coverage-url]: https://coveralls.io/github/tarantool/tarantool?branch=master
[telegram-badge]: https://img.shields.io/badge/Telegram-join%20chat-blue.svg
[telegram-url]: http://telegram.me/tarantool
[discussions-badge]: https://img.shields.io/github/discussions/tarantool/tarantool
[discussions-url]: https://github.com/tarantool/tarantool/discussions
[stackoverflow-badge]: https://img.shields.io/badge/stackoverflow-tarantool-orange.svg
[stackoverflow-url]: https://stackoverflow.com/questions/tagged/tarantool
[oss-fuzz-badge]: https://oss-fuzz-build-logs.storage.googleapis.com/badges/tarantool.svg
[oss-fuzz-url]: https://oss-fuzz.com/coverage-report/job/libfuzzer_asan_tarantool/latest
[tarantool-url]: https://www.tarantool.io/en/
[license]: LICENSE
[modules]: https://www.tarantool.io/en/download/rocks
[queue]: https://github.com/tarantool/queue
[vshard]: https://github.com/tarantool/vshard
[cartridge]: https://github.com/tarantool/cartridge
[mysql]: https://github.com/tarantool/mysql
[pg]: https://github.com/tarantool/pg
[connectors]: https://www.tarantool.io/en/download/connectors
[download]: https://www.tarantool.io/en/download/
[building]: https://www.tarantool.io/en/doc/latest/dev_guide/building_from_source/
[issue-tracker]: https://github.com/tarantool/tarantool/issues
[contributing]: CONTRIBUTING.md
[awesome-list]: https://github.com/tarantool/awesome-tarantool/