[Tarantool-patches] [PATCH 1/2] box: make box.cfg idempotent function
Igor Munkin
imun at tarantool.org
Thu Mar 19 01:26:35 MSK 2020
Kostja,
On 12.03.20, Konstantin Osipov wrote:
> * Maria Khaydich <maria.khaydich at tarantool.org> [20/03/12 22:26]:
> > >> Calling box.cfg{} more than once does not normally cause any errors
> > >> (even though it might not have any effect). In contrast, assigning
> > >> it to some variable and then using it after the box was configured
> > >> caused an error since the method was overwritten by the initial call
> > >> of <load_cfg>.
> > >>
> > >> The patch fixes this issue making box.cfg behave consistently in both
> > >> scenarios and is a follow-up for box: make box.execute idempotent function.
> > >
> > >Did you benchmark it?
> >
> > Do you think we need to? There’s basically one extra condition
> > in the patch. I don’t see how it might degrade performance.
>
> It's not a one more condition, it's one more FFI C call.
I guess the problem have to be fixed anyway.
However you might suggest another fix for the issue? There are several
other ways to indicate whether box is configured, e.g. introduce the
specific value to the box table. What do you think?
I see for now box.cfg call as not the one performance critical, but I
might be missing something you see.
It would be great if you detailed a bit your proposal regarding the fix
and its benchmarks.
>
> --
> Konstantin Osipov, Moscow, Russia
--
Best regards,
IM
More information about the Tarantool-patches
mailing list