-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/7781/
-----------------------------------------------------------

Review request for mesos, Benjamin Hindman and Vinod Kone.


Description
-------

This is part 1, where I'd like to make sure this is the right way function to 
have.

This way, we have a nice helper for aborting, like CHECK() or LOG(FATAL), 
however these two:
  1. Print out a stack trace, which we may not want sometimes.
  2. Perform locking, and can't be used within a fork.

Part 2, will refactor usage of:
    std::cerr << "Cgroups can't be enabled." << std::endl;
    abort();
to become:
    ABORT("Cgroups can't be enabled.");

Part 3, will kill the old files:
    stout/fatal.hpp
    libprocess/src/fatal.hpp
    libprocess/src/fatal.cpp


P.S. I looked at how glog implements it's style of CHECK() << "Foo" << "bar";
It appears to call an abort immediately, but they have signal handlers that 
then catch the abort and appear to wait if someone else is logging, and flush 
the logs to ensure the remaining stuff sent to the check stream are flushed. 
Needless to say, that's way more complexity than I'd like to have if we want 
this to be standalone in stout.


Diffs
-----

  third_party/libprocess/Makefile.am f32c184ca8cc8852b6c90f3c85a8f99e10ed781b 
  third_party/libprocess/include/stout/abort.hpp PRE-CREATION 

Diff: https://reviews.apache.org/r/7781/diff/


Testing
-------

CentOS: make check


Thanks,

Ben Mahler

Reply via email to