From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: From: Vladimir Davydov Subject: [PATCH 0/5] alter: fix WAL error handling Date: Tue, 3 Apr 2018 20:37:38 +0300 Message-Id: To: kostja@tarantool.org Cc: tarantool-patches@freelists.org List-ID: This patch set fixes the use-after-free error that may occur if DDL fails due to WAL error, see [1]. The code is available by the link [2]. It is based on top of [3, 4]. Note, the first three patches are trivial cleanups. They are not directly connected to the issue in question, but they are all related to the problem of vinyl space alter [5], which I'm currently working on. The real work is done by patches 4 and 5. [1] https://github.com/tarantool/tarantool/issues/3289 [2] https://github.com/tarantool/tarantool/commits/gh-3289-alter-fix-wal-error-handling [3] https://github.com/tarantool/tarantool/commits/vy-allow-to-extend-key-def [4] https://www.freelists.org/post/tarantool-patches/PATCH-0012-vinyl-allow-to-extend-key-def-of-nonempty-index [5] https://github.com/tarantool/tarantool/issues/1653 Vladimir Davydov (5): memtx: rtree: remove pointless index_vtab::begin_build implementation memtx: don't call begin_buid and end_build for new pk after recovery vinyl: use disk_format in vy_run_rebuild_index vinyl: do not use space_vtab::commit_alter for preparing new indexes alter: call space_vtab::commit_alter after WAL write src/box/alter.cc | 23 +++----------- src/box/memtx_rtree.c | 9 +----- src/box/memtx_space.c | 38 ++++++++--------------- src/box/memtx_space.h | 6 ++++ src/box/vinyl.c | 79 +++++++++++++++++++++--------------------------- src/box/vy_lsm.c | 2 +- src/box/vy_lsm.h | 17 +++++++++++ src/box/vy_run.c | 4 +-- src/box/vy_run.h | 14 +++++---- test/box/errinj.result | 66 ++++++++++++++++++++++++++++++++++++++++ test/box/errinj.test.lua | 18 +++++++++++ 11 files changed, 170 insertions(+), 106 deletions(-) -- 2.11.0