Tarantool development patches archive
 help / color / mirror / Atom feed
From: Vladislav Shpilevoy <v.shpilevoy@tarantool.org>
To: Alexander Turenko <alexander.turenko@tarantool.org>
Cc: tarantool-patches@dev.tarantool.org
Subject: Re: [Tarantool-patches] [PATCH] net.box: fix fetching of schema of an old version
Date: Thu, 9 Apr 2020 23:30:40 +0200	[thread overview]
Message-ID: <26e71870-33fa-9ec2-2493-d565dbc9d0e7@tarantool.org> (raw)
In-Reply-To: <20200406113935.fu3zli6s5x4dusgb@tkn_work_nb>

>>> Ouch, okay, fill.lua is called on the old tarantool version (on which
>>> you generate a snapshot). It is okay for my case to disable autoupgrade
>>> and insert the data using the new tarantool version. I guess it is okay
>>> too for most of cases. Your case with upgrade of a sequence can be
>>> tested this way too.
>>
>> No, it can't. Unless you tried and actually managed to reproduce this.
>> Because I just tried your way. I made checkout to 2.1, took an empty
>> snapshot (00000000000000000000.snap). Took 2.2 before the sequence fix
>> (that commit: 13de917a0e3b8affb693d041663c174d9ec7fcc9). Then I started
>> Tarantool in read-only mode:
>>
>> <...snipped steps to reproduce...>
>>
>> So even though in your particular case it is ok, it is very
>> artificial, and can't be applied to all tests.
> 
> You're right. I missed that we'll unable to reproduce the problem if
> we'll call fixed upgrade script (from a new tarantool version).
> 
>> Okey, you can omit fill.lua, but I want upgrade-related tests in
>> one place. Or organized in one way in maximum two places, if you are
>> so desperate to use tap.
> 
> I'll rework the patch to keep snapshots together. Don't sure about
> feeding initial data in my case (from fill.lua or from a test): I'll
> took a time to think around.

I am ok with feeding data however you want, suitable for a particular
ticket. But what I consider important is having such tests organized in
one way. With the same folder structure, file naming, isolation.

Although your snapshot is 'pure'. Zero snapshot with no data. Probably
such snapshot could be shared by multiple tests via a symbolic link, if
needed.

> It seems logical to move snapshots out from test suites, since they will
> be used across the test suites. What do you think?

It is not always the case. A snapshot is ok to use across tests only if
it is not related to any particular test more than to others. Only empty
snapshots satisfy that criteria. The reason is that we are obligated to
keep tests isolated from each other. And if you use one non-empty snapshot
for multiple tests, the policy will be violated.

I don't like doing file-per-bug tests, but for snapshots it is fair. Because
otherwise such a snapshot quickly becomes a pile of unmaintainable garbage,
like xlog/upgrade snapshots were beforehand.

  reply	other threads:[~2020-04-09 21:30 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-01 20:45 Alexander Turenko
2020-04-02 21:20 ` Alexander Turenko
2020-04-03 22:53 ` Vladislav Shpilevoy
2020-04-03 23:38   ` Alexander Turenko
2020-04-04 17:40     ` Vladislav Shpilevoy
2020-04-05 12:05       ` Alexander Turenko
2020-04-05 16:41         ` Vladislav Shpilevoy
2020-04-06 11:39           ` Alexander Turenko
2020-04-09 21:30             ` Vladislav Shpilevoy [this message]
2020-04-19 16:23               ` Alexander Turenko
2020-04-19 17:02                 ` Vladislav Shpilevoy
2020-04-19 16:22             ` Alexander Turenko
2020-04-19 17:02               ` Vladislav Shpilevoy
2020-04-20  6:58 ` Alexander Turenko

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=26e71870-33fa-9ec2-2493-d565dbc9d0e7@tarantool.org \
    --to=v.shpilevoy@tarantool.org \
    --cc=alexander.turenko@tarantool.org \
    --cc=tarantool-patches@dev.tarantool.org \
    --subject='Re: [Tarantool-patches] [PATCH] net.box: fix fetching of schema of an old version' \
    /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