Tarantool development patches archive
 help / color / mirror / Atom feed
From: Vladimir Davydov <vdavydov.dev@gmail.com>
To: Olga Arkhangelskaia <arkholga@tarantool.org>
Cc: tarantool-patches@freelists.org
Subject: Re: [tarantool-patches] [PATCH 0/1] Fixed non-informative error messages for log conf
Date: Tue, 31 Jul 2018 15:06:05 +0300	[thread overview]
Message-ID: <20180731120605.mcckzqagp5g6k7d7@esperanza> (raw)
In-Reply-To: <20180730135801.91226-1-arkholga@tarantool.org>

There's no point in a cover-letter if you're submitting a single patch.

You can include the text below either in the commit message or just put
it in the patch email after '---' if you don't want it in the git log.

On Mon, Jul 30, 2018 at 04:58:00PM +0300, Olga Arkhangelskaia wrote:
> Tarantool log used to have more serious problems than non-informative messages:
> No check on parameters like log_nonblock, log_format in case of unconfigured log.
> This means that there was a possibility to set any value in case when the
> first log conf. commands were: 
> box.cfg{log_format = ‘any’}
> box.cfg{log_nonblock=true} - (together with stderr)
> In case of log_format  with such scenario additional problem took place.
> When setting log format we change format_func
> (function that actually logs to log) to NULL, and wrong log_format
> lead to crash - because we could not log error with log format because of 
> format_func was not set yet, but already had been changed to null.
> In case of undefined log type  (“log=’:test:’:) we used to have empty
> exception - so,tarantool just silently crashed.
> I think the main problem that initial initialization is mixed up with
> configuring parameters.  So if we decide to refactor log we need to separate
> them. For example, have set of checking functions and set of configuring.
> One parameter - one check.
> End initial initialization should use the same way prior setting any parameter.
> 
> Patch fixes this problems using the easiest way, however if in future we need
> some more parameters - we should consider the idea of refactor.
>  
> Olga Arkhangelskaia (1):
>   Fixed non-informative error messages for log conf.
> 
>  src/box/box.cc            | 25 ++++++++++++++++++-------
>  src/say.c                 | 22 +++++++++++++++-------
>  src/say.h                 |  4 +++-
>  test/box-tap/cfg.test.lua |  2 +-
>  4 files changed, 37 insertions(+), 16 deletions(-)

      parent reply	other threads:[~2018-07-31 12:06 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20180730135801.91226-1-arkholga@tarantool.org>
2018-07-30 13:58 ` [tarantool-patches] [PATCH 1/1] " Olga Arkhangelskaia
2018-07-31 12:03   ` Vladimir Davydov
2018-07-31 12:34     ` [tarantool-patches] " Olga Arkhangelskaia
2018-07-31 13:09       ` Vladimir Davydov
2018-07-31 12:06 ` Vladimir Davydov [this message]

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=20180731120605.mcckzqagp5g6k7d7@esperanza \
    --to=vdavydov.dev@gmail.com \
    --cc=arkholga@tarantool.org \
    --cc=tarantool-patches@freelists.org \
    --subject='Re: [tarantool-patches] [PATCH 0/1] Fixed non-informative error messages for log conf' \
    /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