Tarantool development patches archive
 help / color / mirror / Atom feed
From: Vladislav Shpilevoy <v.shpilevoy@tarantool.org>
To: tarantool-patches@freelists.org,
	Serge Petrenko <sergepetrenko@tarantool.org>,
	georgy@tarantool.org, tarantool-patches@dev.tarantool.org
Subject: Re: [Tarantool-patches] [tarantool-patches] [PATCH v2 1/2] test: modify swim_run_test to break event loop
Date: Tue, 22 Oct 2019 23:20:23 +0200	[thread overview]
Message-ID: <559a4e59-1a36-7b74-e3b8-81d1e5876915@tarantool.org> (raw)
In-Reply-To: <52e7822bbcd802528d448c15ce9e9fbe4479c73a.1570546695.git.sergepetrenko@tarantool.org>

Hi! Thanks for the patch!

On 08/10/2019 17:03, Serge Petrenko wrote:
> Add a wrapper function around swim test passed to swim_run_test which
> breaks from default cord event loop. Otherwise we will hang indefinitely
> in ev_run in case there is a started watcher.

But why? The loop runs only until there are fibers to run.
By design of these tests, after they are done, there should
be not a single fiber nor a watcher, and the loop is finished
without a break.

This is why the tests pass without this patch. So what is
a purpose of this commit? It does not change anything except
that it may mask some errors. Because if the SWIM unit tests
would hang without a break, then something is wrong. I caught
several bugs in SWIM via this.

If fiber.top() somehow interferes, then probably you could
turn it off for this test? I just don't want to miss possible
SWIM bugs.

> 
> Found during work on #2694
> ---
>  test/unit/swim_test_utils.c | 14 +++++++++++++-
>  1 file changed, 13 insertions(+), 1 deletion(-)
> 

  parent reply	other threads:[~2019-10-22 21:15 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1570546695.git.sergepetrenko@tarantool.org>
     [not found] ` <eb924da60bc66cbd93d7920f53d6c332d15ffab8.1570546695.git.sergepetrenko@tarantool.org>
2019-10-22 21:18   ` [Tarantool-patches] [tarantool-patches] [PATCH v2 2/2] lua: add fiber.top() listing fiber cpu consumption Vladislav Shpilevoy
2019-10-25 15:13     ` Serge Petrenko
2019-10-25 16:19       ` Serge Petrenko
2019-10-26 18:00       ` Vladislav Shpilevoy
2019-10-28 16:16         ` Serge Petrenko
2019-10-28 23:00           ` Vladislav Shpilevoy
2019-11-01 14:09             ` Serge Petrenko
     [not found] ` <52e7822bbcd802528d448c15ce9e9fbe4479c73a.1570546695.git.sergepetrenko@tarantool.org>
2019-10-22 21:20   ` Vladislav Shpilevoy [this message]
2019-10-25 15:15     ` [Tarantool-patches] [tarantool-patches] [PATCH v2 1/2] test: modify swim_run_test to break event loop Serge Petrenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=559a4e59-1a36-7b74-e3b8-81d1e5876915@tarantool.org \
    --to=v.shpilevoy@tarantool.org \
    --cc=georgy@tarantool.org \
    --cc=sergepetrenko@tarantool.org \
    --cc=tarantool-patches@dev.tarantool.org \
    --cc=tarantool-patches@freelists.org \
    --subject='Re: [Tarantool-patches] [tarantool-patches] [PATCH v2 1/2] test: modify swim_run_test to break event loop' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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