|
Boost : |
Subject: Re: [boost] [log] Review-ready version in the Vault
From: vicente.botet (vicente.botet_at_[hidden])
Date: 2009-02-11 10:46:48
----- Original Message -----
From: "vicente.botet" <vicente.botet_at_[hidden]>
To: <boost_at_[hidden]>
Sent: Wednesday, February 11, 2009 11:28 AM
Subject: Re: [boost] [log] Review-ready version in the Vault
> I have some innocent questions:
> * Is logging thread-safe?
> * If yes, are the lines interleaved as it is the case for output streams?
> * If not could you point out how and where in the implementation this is handled?
Hi again,
well i have found some anwers to my questions on the document. I'll come back later on.
How a log record is recognized, i.e. I don't see std::endl neither std::flush are used in the examples. How many lines result in the following example if condifiton is true (2 or 3)
src::logger_mt& lg = my_logger::get();
if (lg.open_record()) {
lg.strm() << "Hello ";
lg.strm() << "world!";
}
// do something
if (condition) {
if (lg.open_record()) lg.strm() << "Bye!";
}
Can other logs be interleaved between "Hello " , "world!" and Bye in a multi threaded program?
Thanks,
Vicente
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk