{"push_id":1432447780,"size":4,"distinct_size":4,"ref":"refs/heads/branch-1.5","head":"abe7358767737c0f69d61ccd9580b0705ab2d9aa","before":"261fcc1e12590fb774e3398f957a8e1ad24bb34d","commits":[{"sha":"2aa73ac1762ea900ff7f6cfa436b0b8334945ae0","author":{"name":"Tomasz Grabiec","email":"446e493e070085ecb71b57eae6e495a8b9200e9e@scylladb.com"},"message":"Update seastar submodule\n\n* seastar 6fd4534...386ccd9 (1):\n  > queue: allow queue to change its maximum size","distinct":true,"url":"https://api.github.com/repos/scylladb/scylla/commits/2aa73ac1762ea900ff7f6cfa436b0b8334945ae0"},{"sha":"ae3b1667e331fe2e11af72b120e9d3ea67196724","author":{"name":"Tomasz Grabiec","email":"446e493e070085ecb71b57eae6e495a8b9200e9e@scylladb.com"},"message":"tests: Fix use-after-free on commitlog\n\nOnly shutdown() ensures all internal processes are complete. Call it before calling clear().\n\nMessage-Id: <1480495534-2253-1-git-send-email-tgrabiec@scylladb.com>\n(cherry picked from commit c35e18ba1237c3ded5092aab2aa1d988e3b2a118)","distinct":true,"url":"https://api.github.com/repos/scylladb/scylla/commits/ae3b1667e331fe2e11af72b120e9d3ea67196724"},{"sha":"0bce019781f0c65e98c45fce6e660f0228626707","author":{"name":"Glauber Costa","email":"eabc0bdfd487c7fe07caa00a26bd9beb424420a0@scylladb.com"},"message":"commitlog: sync segments before acquiring semaphore on shutdown.\n\nSync all segments before acquiring the semaphore, otherwise waiting may\nhave to wait for the timer to kick in and push them down.\nNote that we can't guarantee that no other requests were executed in the\nmean time, so we have to sync again.\n\nSigned-off-by: Glauber Costa <glauber@scylladb.com>\nMessage-Id: <aea019fe49820acce5d2b55dd5ec31e975b3436c.1480388674.git.glauber@scylladb.com>\n(cherry picked from commit 353a4cd2d4ddd3a6e2cc3845168c0db8492ff989)","distinct":true,"url":"https://api.github.com/repos/scylladb/scylla/commits/0bce019781f0c65e98c45fce6e660f0228626707"},{"sha":"abe7358767737c0f69d61ccd9580b0705ab2d9aa","author":{"name":"Glauber Costa","email":"eabc0bdfd487c7fe07caa00a26bd9beb424420a0@scylladb.com"},"message":"prevent commitlog replay position reordering during reserve refill\n\nWhen requests hit the commitlog, each of them will be assigned a replay\nposition, which we expect to be ordered. If reorders happen, the request\nwill be discarded and re-applied. Although this is supposed to be rare,\nit does increase our latencies, specially when big requests are\ninvolved. Processing big requests is expensive and if we have to do it\ntwice that adds to the cost.\n\nThe commitlog is supposed to issue replay positions in order, and it\ncoudl be that the code that adds them to the memtables will reorder\nthem. However, there is one instance in which the commitlog will not\nkeep its side of the bargain.\n\nThat happens when the reserve is exhausted, and we are allocating a\nsegment directly at the same time the reserve is being replenished.  The\nfollowing sequence of events with its deferring points will ilustrate\nit:\n\non_timer:\n\n    return this->allocate_segment(false). // defer here // then([this](sseg_ptr s) {\n\nAt this point, the segment id is already allocated.\n\nnew_segment():\n\n    if (_reserve_segments.empty()) {\n\t[ ... ]\n        return allocate_segment(true).then ...\n\nAt this point, we have a new segment that has an id that is higher than\nthe previous id allocated.\n\nThen we resume the execution from the deferring point in on_timer():\n\n    i = _reserve_segments.emplace(i, std::move(s));\n\nThe next time we need to allocate a segment, we'll pick it from the\nreserve. But the segment in the reserve has an id that is lower than the\nid that we have already used.\n\nReorders are bad, but this one is particularly bad: because the reorder\nhappens with the segment id side of the replay position, that means that\nevery request that falls into that segment will have to be reinserted.\n\nThis bug can be a bit tricky to reproduce. To make it more common, we\ncan artificially add a sleep() fiber after the allocate_segment(false)\nin on_timer(). If we do that, we'll see a sea of reinsertions going on\nin the logs (if dblog is set to debug).\n\nApplying this patch (keeping the sleep) will make them all disappear.\nWe do this by rewriting the reserve logic, so that the segments always\ncome from the reserve. If we draw from a single pool all the time, there\nis no chance of reordering happening. To make that more amenable, we'll\nhave the reserve filler always running in the background and take it out\nof the timer code.\n\nSigned-off-by: Glauber Costa <glauber@scylladb.com>\nMessage-Id: <49eb7edfcafaef7f1fdceb270639a9a8b50cfce7.1480531446.git.glauber@scylladb.com>\n(cherry picked from commit 99a5a7723433e8a43b259ed09d45f0a77410ae1c)","distinct":true,"url":"https://api.github.com/repos/scylladb/scylla/commits/abe7358767737c0f69d61ccd9580b0705ab2d9aa"}]}
{"actor":{"display_login":"tgrabiec"}}