This project is mirrored from https://*****@github.com/tarantool/tarantool.git. Pull mirroring failed .
Repository mirroring has been paused due to too many failed attempts. It can be resumed by a project maintainer.
Last successful update .
  1. 29 May, 2021 1 commit
    • Artem Starshov's avatar
      test: fix flaky tests for -e and iteractive mode · d5bd5d87
      Artem Starshov authored
      Occasionally, test/app-tap/gh-5040-inter-mode-isatty-via-errinj.test.lua
      failed because it used output file with the same name as
      test/app-tap/gh-4983-tnt-e-assert-false-hangs.test.lua and the last one
      didn't remove file after usage.
      
      Added removal of output file to test for 4983 and also changed file names
      to distinguish outputs of these tests better in case of failure.
      
      Fixes tarantool/tarantool-qa#122
      d5bd5d87
  2. 28 May, 2021 1 commit
  3. 27 May, 2021 2 commits
    • Iskander Sagitov's avatar
      fiber: set fiber->csw = 0 for every creating fiber · c7c9d420
      Iskander Sagitov authored
      It is strange to create a new fiber and see that it has yielded 100
      times, when in fact it never actually did it.
      
      The patch makes fiber->csw = 0 for each created fiber.
      
      Follow-up #5799
      c7c9d420
    • Iskander Sagitov's avatar
      fiber: introduce fiber_o:info() and fiber_o:csw() · 9da7e03e
      Iskander Sagitov authored
      If you want to get information or get csw (Context SWitch) of some fiber
      you need to call fiber.info(), but it creates table with information about
      all the fibers. This patch introduces fiber_object:info() and
      fiber_object:csw() - functions to solve this problem.
      
      Closes #5799
      
      @TarantoolBot document
      Title: introduce fiber_object:info() and fiber_object:csw()
      ```
      -- fiber_object:info() is the same as fiber.info(), but show information only
      about one alive fiber.
      -- fiber_object:csw() show csw (Context SWitch) of alive fiber.
      ```
      9da7e03e
  4. 26 May, 2021 3 commits
    • Mergen's avatar
      sql: replace MEM-type flags by enum mem_type · 39370f34
      Mergen authored
      This patch moves MEM types from the 'u32 flags' field to the new
      'enum mem_type type' field. Now, we can be sure that only one type is
      set for MEM. In addition, it is now easier to distinguish MAP and ARRAY
      from VARBINARY, and this makes it easier to add extension types - UUID
      and DECIMAL.
      
      Closes #4906
      39370f34
    • Mergen's avatar
      sql: make mem_is_bin() to check only for VARBINARY · 1fb46b16
      Mergen authored
      After this patch, the mem_is_bin() function will return 'true' only if
      the value that the MEM contains is of type VARBINARY. This patch also
      adds the mem_is_bin_ext() function, which is used to check if a MEM
      contains value of type VARBINARY or value of types that are currently
      considered VARBINARY extensions - MAP and ARRAY.
      
      Part of #4906
      1fb46b16
    • Mergen's avatar
      sql: initialize MEM used in aggregate functions · cddb7d2c
      Mergen authored
      This patch adds proper initialization for the MEM, which is used in the
      aggregate functions min() and max().
      
      Part of #4906
      cddb7d2c
  5. 25 May, 2021 1 commit
    • Vladislav Shpilevoy's avatar
      json: use cord_ibuf for encoding and decoding · 3298f129
      Vladislav Shpilevoy authored
      Lua json module used to have a global buffer for all encodings. It
      was reused by each next encode().
      
      This was not correct, because during encode() might happen a GC
      step, which might call encode() again and spoil the global buffer.
      
      The same problem was already fixed for the global static buffer in
      scope of #5632. Similarly to that time, the patch makes Lua json
      module use cord_ibuf to prevent "concurrent" usage of the buffer
      data. The global buffer is deleted.
      
      According to a few microbenchmarks it didn't affect the perf
      anyhow.
      
      Core part of the patch is strbuf changes. Firstly, its destruction
      is now optional, cord_ibuf can free itself on a next yield.
      Secondly, its reallocation algorithm is kept intact - ibuf is used
      as an allocator, not as the buffer itself. This is done so as not
      to be too intrusive in the third party module which might need an
      upgrade to the upstream in the future.
      
      Closes #6050
      3298f129
  6. 24 May, 2021 3 commits
    • Sergey Bronnikov's avatar
      tools: fix script to run jepsen tests · 4fea6bf8
      Sergey Bronnikov authored
      Script used to run Jepsen tests uses Terraform to prepare test environment.
      When I made this script I had a wrong assumption about working directory
      used by Terraform. Due to this sometimes job with Jepsen tests
      failed on cleanup with message:
      
      ```
      Error: Could not load plugin
      
      Plugin reinitialization required. Please run "terraform init".
      
      Plugins are external binaries that Terraform uses to access and manipulate
      resources. The configuration provided requires plugins which can't be located,
      don't satisfy the version constraints, or are otherwise incompatible.
      
      Terraform automatically discovers provider requirements from your
      configuration, including providers used in child modules. To see the
      requirements and constraints, run "terraform providers".
      
      Failed to instantiate provider
      "registry.terraform.io/terraform-providers/openstack" to obtain schema:
      unknown provider "registry.terraform.io/terraform-providers/openstack"
      ```
      
      Terraform documentation describes how Terraform uses working directories [1]
      and there are at least to ways to resolve an issue. First one is using always
      one directory before running terraform subcommands. Second one is using option
      `-chdir` in all terraform commands [2].
      
      1. https://www.terraform.io/docs/cli/init/index.html
      2. https://www.terraform.io/docs/cli/commands/index.html#switching-working-directory-with-chdir
      
      Closes #6089
      4fea6bf8
    • Mergen's avatar
      box: make UUID part of SCALAR · 5ea50014
      Mergen authored
      Prior to this patch, UUID was not part of SCALAR. However, this should
      be changed to comply with the RFC "Consistent Lua/SQL types".
      
      Closes #6042
      
      @TarantoolBot document
      Title: UUID is now part of SCALAR
      
      The UUID field type is now part of the SCALAR field type. This means
      that now values of type UUID can be inserted into the SCALAR field, and
      these values can participate in the sorting of the SCALAR fields. The
      order is as follows: boolean < number < string < varbinary < uuid.
      5ea50014
    • Cyrill Gorcunov's avatar
      iproto: stringify IPROTO_RAFT, IPROTO_PROMOTE · 0d090b34
      Cyrill Gorcunov authored
      
      
      This allows `xlog` Lua module to decode appropriate
      types into symbolic form.
      
      For example with the patch we should see raft and
      promote types in output.
      
       | $ tarantoolctl cat 00000000000000000004.xlog
       | ---
       | HEADER:
       |   lsn: 2
       |   group_id: 1
       |   type: RAFT
       |   timestamp: 1621541912.4588
       | BODY:
       |   0: 3
       |   1: 4
       | ---
       | HEADER:
       |   lsn: 1
       |   replica_id: 4
       |   type: PROMOTE
       |   timestamp: 1621541912.4592
       | BODY:
       |   2: 0
       |   3: 0
       |   83: 3
      
      Fixes #6088
      Signed-off-by: Cyrill Gorcunov's avatarCyrill Gorcunov <gorcunov@gmail.com>
      0d090b34
  7. 23 May, 2021 1 commit
  8. 20 May, 2021 1 commit
  9. 19 May, 2021 3 commits
    • Igor Munkin's avatar
      build: add missing module for jit.dump on ARM64 · 93e2ce52
      Igor Munkin authored
      Since commit c9d88d5f ('Fix #984: add
      jit.* library to the binary') all required modules implemented in Lua
      are bundled (i.e. compiled into the executable as a C literal) into
      Tarantool binary. While making Tarantool work on ARM64 platforms, it
      turned out the arch-specific module (namely, jit/dis_arm64.lua) is not
      bundled. Within this patch the missing sources are added and jit.dump
      works fine on ARM64 hosts as a result.
      
      Part of #5983
      Relates to #5629
      Follows up #984
      
      Reviewed-by: default avatarSergey Kaplun <skaplun@tarantool.org>
      Reviewed-by: Sergey Ostanevich's avatarSergey Ostanevich <sergos@tarantool.org>
      Signed-off-by: default avatarIgor Munkin <imun@tarantool.org>
      93e2ce52
    • Igor Munkin's avatar
      luajit: bump new version · 3fa165e5
      Igor Munkin authored
      * FFI/ARM64/OSX: Fix vararg call handling.
      * OSX/iOS: Handle iOS simulator and ARM64 Macs.
      * build: pass sysroot to MacOS SDK
      
      Closes #6065
      Closes #6066
      Part of #5629
      Relates to #5983
      3fa165e5
    • Alexander V. Tikhonov's avatar
      github-ci: add result message from coveralls in PR · 660e3263
      Alexander V. Tikhonov authored
      Workflow 'debug_coverage' produces and uploads results to 'coveralls.io'
      web site. Message about it can be shown in PR within each run was done.
      This patch adds the ability to send message in available PR otherwise it
      is skipped. Also added 'coverage.info' file to artifacts list.
      
      Found that used 'coverallsapp/github-action' action checks if the
      trigger was 'pull_request' used to run the workflow [1]. And only in
      this way it writes results message to PR. Previously 'pull_request'
      trigger was blocked to avoid duplication with 'push' trigger. To make
      able to run workflow by any single trigger and to send message to PR
      if it exits, it was implemented the following logic:
      
        - run workflows on both triggers 'push' and 'pull_request';
        - for workflow with 'push' trigger check if PR exists then skip all
          jobs otherwise continue running;
        - for workflow with 'pull_request' trigger continue running;
      
      To avoid of issue coverallsapp/github-action#55 [2], sources checkout
      should be based on 2nd version and later.
      
      Closes #5644
      
      [1]: https://github.com/coverallsapp/github-action/blob/master/src/run.ts#L38
      [2]: https://github.com/coverallsapp/github-action/issues/55#issuecomment-644927165
      660e3263
  10. 18 May, 2021 1 commit
    • Alexander Turenko's avatar
      test: update test-run (fix release_disabled) · 7bee6153
      Alexander Turenko authored
      The problem that is fixed by this test-run update is the following. A
      test that is listed in the 'release_disabled' field in a suite.ini file
      of a 'core = app' or a 'core = unittest' test suite was disabled at all,
      not only for the release tarantool build. A 'core = tarantool' test
      suite was not affected by the problem.
      
      Disabled sql-tap/debug_mode_only.test.lua test, because it does not work
      anymore. We plan to revisit this test in the scope of #3694.
      
      See https://github.com/tarantool/test-run/issues/199
      7bee6153
  11. 17 May, 2021 3 commits
  12. 14 May, 2021 12 commits
  13. 13 May, 2021 1 commit
    • Serge Petrenko's avatar
      recovery: make it yield when positioning in a WAL · 17289440
      Serge Petrenko authored
      We had various places in box.cc and relay.cc which counted processed
      rows and yielded every now and then. These yields didn't cover cases,
      when recovery has to position inside a long WAL file:
      
      For example, when tarantool exits without leaving an empty WAL file
      which will be used to recover instance vclock on restart. In this case
      the instance freezes while processing the last available WAL in order
      to recover the vclock.
      
      Another issue is with replication. If a replica connects and needs data
      from the end of a really long WAL, recovery will read up to the needed
      position without yields, making relay disconnect by timeout.
      
      In order to fix the issue, make recovery decide when a yield should
      happen. Once recovery decides so, it calls a xstream callback,
      schedule_yield. Currently schedule_yield is fired once recovery
      processes (either skips or writes) WAL_ROWS_PER_YIELD rows.
      
      schedule_yield either yields right away, in case of relay, or saves the
      yield for later, in case of local recovery, because it might be in the
      middle of a transaction.
      
      Closes #5979
      17289440
  14. 04 May, 2021 2 commits
  15. 30 Apr, 2021 1 commit
  16. 28 Apr, 2021 1 commit
    • Vladislav Shpilevoy's avatar
      txn: destroy commit and rollback triggers · 7fd53b4c
      Vladislav Shpilevoy authored
      They were not deleted ever. Worked fine for DDL and replication,
      for which they were introduced in the first place, because these
      triggers are on the region memory.
      
      But didn't work when the triggers became available in the public
      API, because these are allocated on the heap. As a result, all the
      box.on_commit() and box.on_rollback() triggers leaked.
      
      The patch ensures all the on_commit/on_rollback triggers are
      destroyed.
      
      The statement triggers on_commit/on_rollback are left intact since
      they are private and never need deletion, but the patch adds
      assertions in case they ever would need to be destroyed.
      
      Another option was to force all the commit and rollback triggers
      clear themselves. For example, in case of commit all the on_commit
      triggers must clear themselves, and the rollback triggers are
      destroyed. Vice versa when a rollback happens. This would allow
      not to manually destroy on_commit triggers in case of commit. But
      it didn't work because the Lua triggers all work via a common
      runner lbox_trigger_run(), which can't destroy its argument in
      most of the cases (space:on_replace, :before_replace, ...). It
      could be patched but requires to add some work to the Lua triggers
      affecting all of them, which in total might be not better.
      
      Closes #6025
      7fd53b4c
  17. 27 Apr, 2021 3 commits
    • Барулев Александр Вадимович's avatar
      test: fix regex in box-py/args.test.py · f44663ed
      Regex for validating version was expecting a single
      character (digit) for version `patch`, but it's not correct.
      This patch fixes test behaviour for tarantool 1.10.10
      
      Close #6039
      f44663ed
    • Vladislav Shpilevoy's avatar
      fiber: use wakeup safely on self everywhere · 8d1ebd83
      Vladislav Shpilevoy authored
      The previous commit made fiber_wakeup() safe to use on the current
      fiber. Leverage the new behaviour everywhere in the source code to
      remove all checks f != fiber() before fiber_wakeup(f) calls.
      
      Follow-up #5292
      8d1ebd83
    • Vladislav Shpilevoy's avatar
      fiber: make wakeup in Lua and C nop on self · db0ded5d
      Vladislav Shpilevoy authored
      fiber.wakeup() in Lua and fiber_wakeup() in C could lead to a
      crash or undefined behaviour when called on the currently running
      fiber.
      
      In particular, if after wakeup was started a new fiber in a
      blocking way (fiber.create() and fiber_start()) it would crash in
      debug build, and lead to unknown results in release.
      
      If after wakeup was made a sleep with non-zero timeout or an
      infinite yield (fiber_yield()), the fiber woke up in the same
      event loop iteration regardless of any timeout or other wakeups.
      It was a spurious wakeup, which is not expected in most of the
      places internally.
      
      The patch makes the wakeup nop on the current fiber making it safe
      to use anywhere.
      
      Closes #5292
      Closes #6043
      
      @TarantoolBot document
      Title: fiber.wakeup() in Lua and fiber_wakeup() in C are nop on self
      In Lua `fiber.wakeup()` being called on the current fiber does not
      do anything, safe to use. The same for `fiber_wakeup()` in C.
      db0ded5d