Does logging_query have this problem too? Its code says:
// a single write has a kernel thread lock, thus no need mutex guard this
wrv= write(fd, msgbuf.c_str(), msgbuf.length());
assert(wrv == msgbuf.length());
Whereas query_log does,
_fh << "# start_ts=" << event->ts
...
which isn't thread-safe (and yes, that's my fault :-). If write() is indeed thread-safe, then it will be easy to make query_log use it like logginq_query.
Henrik,
Does logging_query have this problem too? Its code says:
// a single write has a kernel thread lock, thus no need mutex guard this
wrv= write(fd, msgbuf.c_str(), msgbuf.length());
assert(wrv == msgbuf.length());
Whereas query_log does,
_fh << "# start_ts=" << event->ts
...
which isn't thread-safe (and yes, that's my fault :-). If write() is indeed thread-safe, then it will be easy to make query_log use it like logginq_query.