Skip to content

Conversation

Gumix
Copy link
Contributor

@Gumix Gumix commented Sep 4, 2024

The new request inserts into a given space the data that is encoded into Arrow IPC columnar format 1.
At the moment the request is not supported by memtx and vinyl spaces.

Closes #10508
Needed for https://github.com/tarantool/tarantool-ee/issues/820

Footnotes

  1. https://arrow.apache.org/docs/format/Columnar.html#serialization-and-interprocess-communication-ipc

@Gumix Gumix requested a review from a team as a code owner September 4, 2024 17:49
@Gumix Gumix force-pushed the iverbin/gh-10508-iproto_insert_arrow branch from 2478f54 to f68db29 Compare September 4, 2024 17:54
@coveralls
Copy link

coveralls commented Sep 4, 2024

Coverage Status

coverage: 87.266% (-0.03%) from 87.291%
when pulling 1189cc8 on Gumix:iverbin/gh-10508-iproto_insert_arrow
into 7cf41a1
on tarantool:master
.

Copy link
Contributor

@mkostoevr mkostoevr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just a single question.

@mkostoevr mkostoevr removed their assignment Sep 5, 2024
@Gumix Gumix force-pushed the iverbin/gh-10508-iproto_insert_arrow branch from f68db29 to 0be0526 Compare September 6, 2024 16:12
@locker locker removed their assignment Sep 9, 2024
@Gumix Gumix force-pushed the iverbin/gh-10508-iproto_insert_arrow branch from 0be0526 to 333dfd7 Compare September 11, 2024 00:20
@Gumix Gumix added the do not merge Not ready to be merged label Sep 11, 2024
@Gumix Gumix force-pushed the iverbin/gh-10508-iproto_insert_arrow branch from 333dfd7 to 6479154 Compare September 11, 2024 00:33
@Gumix Gumix requested a review from locker September 11, 2024 00:44
@Gumix Gumix assigned locker and unassigned Gumix Sep 11, 2024
@Gumix Gumix force-pushed the iverbin/gh-10508-iproto_insert_arrow branch from 6479154 to b3b2c7e Compare September 11, 2024 15:26
@Gumix Gumix requested a review from locker September 11, 2024 15:41
@Gumix Gumix removed their assignment Sep 11, 2024
@locker locker assigned Gumix and unassigned locker Sep 11, 2024
@Gumix Gumix added the full-ci Enables all tests for a pull request label Sep 11, 2024
@Gumix Gumix force-pushed the iverbin/gh-10508-iproto_insert_arrow branch from b3b2c7e to 899252d Compare September 11, 2024 16:57
@Gumix
Copy link
Contributor Author

Gumix commented Sep 11, 2024

Bumped nanoarrow to bring compilation fix.

The nanoarrow library is required to work with the serialized Arrow
IPC format [1].

1. https://arrow.apache.org/docs/format/Columnar.html#serialization-and-interprocess-communication-ipc

Needed for tarantool#10508
Needed for tarantool/tarantool-ee#820

NO_DOC=third_party
NO_TEST=third_party
NO_CHANGELOG=third_party
Also the NULL assignments are replaced by the assertions, as the
`iproto_thread` structure is allocated by `calloc()`.

NO_DOC=refactoring
NO_TEST=refactoring
NO_CHANGELOG=refactoring
The new method inserts into a given space the data, provided in Arrow
columnar format [1]. At the moment it is not supported by memtx and vinyl
spaces.

Also the IPROTO_INSERT_ARROW request is introduced. It inserts the data
that is serialized into Arrow IPC format [2].

1. https://arrow.apache.org/docs/format/Columnar.html
2. https://arrow.apache.org/docs/format/Columnar.html#serialization-and-interprocess-communication-ipc

Closes tarantool#10508
Needed for tarantool/tarantool-ee#820

NO_CHANGELOG=No sense in mentioning in CE release notes

@TarantoolBot document
Title: Document iproto request IPROTO_INSERT_ARROW
Product: Tarantool
Since: 3.3
Root documents: https://www.tarantool.io/en/doc/latest/reference/internals/iproto/requests/
https://www.tarantool.io/en/doc/latest/reference/internals/iproto/keys/#internals-iproto-keys-features

Available IPROTO_FEATURES are the following:
* IPROTO_FEATURE_INSERT_ARROW = 12 - Support of data insertion in Arrow
  format.
IPROTO version supporting the this feature is 10 or newer.

Client-server requests and responses:
* IPROTO_INSERT_ARROW = 0x11 - Insert Arrow data request.

The structure of the `IPROTO_INSERT_ARROW` request is similar to
`IPROTO_INSERT`, the only difference is `IPROTO_ARROW : MP_ARROW`
instead of `IPROTO_TUPLE : MP_ARRAY`.

The response to `IPROTO_INSERT_ARROW` contains an empty body.
@Gumix Gumix force-pushed the iverbin/gh-10508-iproto_insert_arrow branch from 72f1c28 to 1189cc8 Compare September 30, 2024 18:57
@Gumix
Copy link
Contributor Author

Gumix commented Oct 1, 2024

Rewrote cmake/BuildNanoarrow.cmake from add_subdirectory() to ExternalProject_Add(), because in case of add_subdirectory() all build static libs and headers are considered as public, that cause errors during RPM packaging:

error: Installed (but unpackaged) file(s) found:
   /usr/include/nanoarrow/common/inline_array.h
   ...

@Gumix Gumix removed the do not merge Not ready to be merged label Oct 1, 2024
@Gumix Gumix assigned locker and unassigned Gumix Oct 1, 2024
@locker locker merged commit be34a84 into tarantool:master Oct 1, 2024
60 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
full-ci Enables all tests for a pull request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Iproto request for batch insertions in Arrow format
6 participants