Tarantool development patches archive
 help / color / mirror / Atom feed
* [PATCH 0/8] Follow-up on async memtx index cleanup
@ 2018-05-22 11:46 Vladimir Davydov
  2018-05-22 11:46 ` [PATCH 1/8] memtx: init index extent allocator in engine constructor Vladimir Davydov
                   ` (7 more replies)
  0 siblings, 8 replies; 21+ messages in thread
From: Vladimir Davydov @ 2018-05-22 11:46 UTC (permalink / raw)
  To: kostja; +Cc: tarantool-patches

Turned out that after commit 2a1482f33fa0 ("memtx: free tuples
asynchronously when primary index is dropped"), we can't merge
1.10 to 2.0 without breaking tests, because one of the tests
(namely sql-tap/gh-3083-ephemeral-unref-tuples) executes a lot
of SQL SELECT statements without yielding. Those statements
in turn create a lot of ephemeral spaces that consume all
available memory since memtx garbage collection doesn't have
a chance to clean up. To fix that, this patch set improves
the garbage collection procedure: now it is invoked not only
by a background fiber, but also on demand, i.e. when any of
memtx functions fails to allocate memory.

https://github.com/tarantool/tarantool/issues/3408
https://github.com/tarantool/tarantool/commits/memtx-run-gc-on-demand

Vladimir Davydov (8):
  memtx: init index extent allocator in engine constructor
  memtx: fold memtx_tuple.cc into memtx_engine.c
  memtx: pass engine to memory allocation functions
  memtx: move all global variables to engine
  memtx: destroy slab arena on engine shutdown
  memtx: embed light hash into memtx_hash_index
  memtx: rework background garbage collection procedure
  memtx: run garbage collection on demand

 src/box/CMakeLists.txt |   1 -
 src/box/alter.cc       |   1 -
 src/box/index.cc       |   7 +-
 src/box/lua/slab.c     |  35 ++++---
 src/box/lua/tuple.c    |   1 -
 src/box/lua/xlog.c     |   1 -
 src/box/memtx_bitset.c |   4 +-
 src/box/memtx_engine.c | 257 ++++++++++++++++++++++++++++++++++---------------
 src/box/memtx_engine.h |  67 ++++++++++---
 src/box/memtx_hash.c   |  93 ++++++------------
 src/box/memtx_hash.h   |  35 ++++++-
 src/box/memtx_rtree.c  |   4 +-
 src/box/memtx_space.c  |   7 +-
 src/box/memtx_tree.c   |  33 +++----
 src/box/memtx_tree.h   |   1 +
 src/box/memtx_tuple.cc | 193 -------------------------------------
 src/box/memtx_tuple.h  | 100 -------------------
 src/box/tuple_format.c |   1 +
 src/box/tuple_format.h |   2 +
 19 files changed, 349 insertions(+), 494 deletions(-)
 delete mode 100644 src/box/memtx_tuple.cc
 delete mode 100644 src/box/memtx_tuple.h

-- 
2.11.0

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2018-05-22 16:42 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-22 11:46 [PATCH 0/8] Follow-up on async memtx index cleanup Vladimir Davydov
2018-05-22 11:46 ` [PATCH 1/8] memtx: init index extent allocator in engine constructor Vladimir Davydov
2018-05-22 13:43   ` Konstantin Osipov
2018-05-22 11:46 ` [PATCH 2/8] memtx: fold memtx_tuple.cc into memtx_engine.c Vladimir Davydov
2018-05-22 13:45   ` Konstantin Osipov
2018-05-22 11:46 ` [PATCH 3/8] memtx: pass engine to memory allocation functions Vladimir Davydov
2018-05-22 13:47   ` Konstantin Osipov
2018-05-22 14:39     ` Vladimir Davydov
2018-05-22 11:46 ` [PATCH 4/8] memtx: move all global variables to engine Vladimir Davydov
2018-05-22 13:48   ` Konstantin Osipov
2018-05-22 11:46 ` [PATCH 5/8] memtx: destroy slab arena on engine shutdown Vladimir Davydov
2018-05-22 13:50   ` Konstantin Osipov
2018-05-22 16:26     ` Vladimir Davydov
2018-05-22 11:46 ` [PATCH 6/8] memtx: embed light hash into memtx_hash_index Vladimir Davydov
2018-05-22 13:51   ` Konstantin Osipov
2018-05-22 11:46 ` [PATCH 7/8] memtx: rework background garbage collection procedure Vladimir Davydov
2018-05-22 13:56   ` Konstantin Osipov
2018-05-22 14:49     ` Vladimir Davydov
2018-05-22 16:42       ` Konstantin Osipov
2018-05-22 11:46 ` [PATCH 8/8] memtx: run garbage collection on demand Vladimir Davydov
2018-05-22 14:00   ` Konstantin Osipov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox