Re: Choice between LOG(FATAL) and EXIT(EXIT_FAILURE)

2017-05-08 Thread James Peach

> On May 8, 2017, at 2:02 PM, Zhitao Li  wrote:
> 
> Hi Vinod,
> 
> I'm reviving this old conversation from last year.
> 
> We are feeling some operational pain again, mostly due to journald
> truncates the stderr of Mesos agent so we cannot see a full exit message
> even in journald, and the error is not in GLOG output at all.
> 
> I filed https://issues.apache.org/jira/browse/MESOS-7472 to track this. We
> can submit the patch as long as some committer can shepherd this.


https://reviews.apache.org/r/56681/


> 
> Thanks!
> 
> On Fri, Sep 16, 2016 at 2:17 PM, Vinod Kone  wrote:
> 
>> We typically used LOG(FATAL) when we were interested in the stack trace. If
>> not, we preferred to use EXIT(EXIT_FAILURE). While that was the original
>> intention, not sure if we have been following that distinction diligently.
>> 
>> Separately, we should fix EXIT to log at ERROR level instead of just
>> printing to to stderr.
>> 
>> On Tue, Aug 30, 2016 at 10:42 AM, Zhitao Li  wrote:
>> 
>>> Hi,
>>> 
>>> Can someone explain better about when we should use LOG(FATAL) and when
>>> EXIT(EXIT_FAILURE) in Mesos codebase?
>>> 
>>> One thing is that EXIT(EXIT_FAILURE) does not seem to leave anything in
>> the
>>> level separated GLOG files so it could be mysterious to people who relies
>>> on that for debugging issues.
>>> 
>>> I see we have about 100 call sites to LOG(FATAL) and 200 call sites
>>> to EXIT(EXIT_FAILURE) at the moment.
>>> 
>>> Many thanks!
>>> 
>>> --
>>> Cheers,
>>> 
>>> Zhitao Li
>>> 
>> 
> 
> 
> 
> -- 
> Cheers,
> 
> Zhitao Li



Re: Choice between LOG(FATAL) and EXIT(EXIT_FAILURE)

2017-05-08 Thread Zhitao Li
Hi Vinod,

I'm reviving this old conversation from last year.

We are feeling some operational pain again, mostly due to journald
truncates the stderr of Mesos agent so we cannot see a full exit message
even in journald, and the error is not in GLOG output at all.

I filed https://issues.apache.org/jira/browse/MESOS-7472 to track this. We
can submit the patch as long as some committer can shepherd this.

Thanks!

On Fri, Sep 16, 2016 at 2:17 PM, Vinod Kone  wrote:

> We typically used LOG(FATAL) when we were interested in the stack trace. If
> not, we preferred to use EXIT(EXIT_FAILURE). While that was the original
> intention, not sure if we have been following that distinction diligently.
>
> Separately, we should fix EXIT to log at ERROR level instead of just
> printing to to stderr.
>
> On Tue, Aug 30, 2016 at 10:42 AM, Zhitao Li  wrote:
>
> > Hi,
> >
> > Can someone explain better about when we should use LOG(FATAL) and when
> > EXIT(EXIT_FAILURE) in Mesos codebase?
> >
> > One thing is that EXIT(EXIT_FAILURE) does not seem to leave anything in
> the
> > level separated GLOG files so it could be mysterious to people who relies
> > on that for debugging issues.
> >
> > I see we have about 100 call sites to LOG(FATAL) and 200 call sites
> > to EXIT(EXIT_FAILURE) at the moment.
> >
> > Many thanks!
> >
> > --
> > Cheers,
> >
> > Zhitao Li
> >
>



-- 
Cheers,

Zhitao Li


Re: Choice between LOG(FATAL) and EXIT(EXIT_FAILURE)

2016-09-16 Thread Vinod Kone
We typically used LOG(FATAL) when we were interested in the stack trace. If
not, we preferred to use EXIT(EXIT_FAILURE). While that was the original
intention, not sure if we have been following that distinction diligently.

Separately, we should fix EXIT to log at ERROR level instead of just
printing to to stderr.

On Tue, Aug 30, 2016 at 10:42 AM, Zhitao Li  wrote:

> Hi,
>
> Can someone explain better about when we should use LOG(FATAL) and when
> EXIT(EXIT_FAILURE) in Mesos codebase?
>
> One thing is that EXIT(EXIT_FAILURE) does not seem to leave anything in the
> level separated GLOG files so it could be mysterious to people who relies
> on that for debugging issues.
>
> I see we have about 100 call sites to LOG(FATAL) and 200 call sites
> to EXIT(EXIT_FAILURE) at the moment.
>
> Many thanks!
>
> --
> Cheers,
>
> Zhitao Li
>


Choice between LOG(FATAL) and EXIT(EXIT_FAILURE)

2016-08-30 Thread Zhitao Li
Hi,

Can someone explain better about when we should use LOG(FATAL) and when
EXIT(EXIT_FAILURE) in Mesos codebase?

One thing is that EXIT(EXIT_FAILURE) does not seem to leave anything in the
level separated GLOG files so it could be mysterious to people who relies
on that for debugging issues.

I see we have about 100 call sites to LOG(FATAL) and 200 call sites
to EXIT(EXIT_FAILURE) at the moment.

Many thanks!

-- 
Cheers,

Zhitao Li