It seems unfortunate to establish an ordering between different component's
verbosity levels, how is libprocess to know which level to start at? I
suppose you can tell it, but it's not clear that the first level of
verbosity in libprocess should come after the max level of verbosity in
mesos.

This seems to surface a need for per-module logging verbosity control. Have
you looked into the '--vmodule' flag?

On Wed, Oct 4, 2017 at 12:59 PM, Armand Grillet <agril...@mesosphere.io>
wrote:

> Hi all,
>
> We currently use three levels of verbose logging via the VLOG macro. I
> propose to add two levels and change how we use the current ones to make
> debugging easier for Mesos developers.
>
> The current situation is:
>
>    - VLOG(1) is used for Mesos and libprocess events such as the
>    admission of an agent by a master. It is also used for a few Mesos
> common
>    events, e.g. the allocation of resources on an agent.
>    - VLOG(2) is used for Mesos and libprocess common events, e.g. the
>    reception of an offer by a Mesos scheduler.
>    - VLOG(3) is used when a Mesos scheduler process saves the PID
>    associated with each slave and for libprocess events related to timers,
>    clocks, and waiter processes.
>
> As an example, running GLOG_v=<level> ./mesos-tests --gtest_filter="
> OversubscriptionTest.UpdateAllocatorOnSchedulerFailover" --verbose
> returns:
>
>    - 212 lines of logs with level = 1.
>    - 695 lines of logs with level = 2.
>    - 782 lines of logs with level = 3.
>
> The logs at level 2 are quite noisy. This is mainly due to the number of
> messages regarding libprocess recurring events such as process resumptions:
> https://github.com/apache/mesos/blob/d863620e5cb82b7f22cade0da0a0d1
> 8afbdf9136/3rdparty/libprocess/src/process.cpp#L3245
>
> To improve the situation, I suggest having five levels:
>
>    - VLOG(1), used for Mesos events.
>    - VLOG(2), used for Mesos common/recurring events.
>    - VLOG(3), used for libprocess events.
>    - VLOG(4), used for libprocess common/recurring events.
>    - VLOG(5), used for libprocess events related to timers, clocks, and
>    waiter processes.
>
> This change would allow us to read the Mesos verbose logs without having to
> see the ones concerning libprocess, a use case that seems reasonable for
> Mesos developers. The new log levels would make it possible to have the
> same logs as before when necessary.
>
> What do you think about this? Please feel free to share your thoughts and
> comments.
>
> --
> Armand Grillet
> Software Engineer, Mesosphere
>

Reply via email to