boost-log Questions

4

Solved

I need a logger for debug purpose and I'm using Boost.Log (1.54.0 with a patch in the boost.org homepage). It's all fine I've created some macro like this: #define LOG_MESSAGE( lvl ) BOOST_LOG_TR...
Uttasta asked 11/7, 2013 at 15:58

3

I was considering using boost_log for one project and right at the beginning I faced following problem. Boost Log Example I found at: http://www.boost.org/doc/libs/1_54_0/libs/log/example/doc/tuto...
Decal asked 10/8, 2014 at 17:36

3

Solved

I am trying to use the new Boost.Log library in a project I am working on. The project is built with CMake. I am receiving link errors claiming that the linker has come across undefined references ...
Vorlage asked 24/7, 2013 at 20:20

4

Solved

I'm using Boost(1.55.0) Logging in my C++ application. I have been able to generate log of this format [2014-Jul-15 10:47:26.137959]: <debug> A regular message I want to be able to add s...
Incorporating asked 15/7, 2014 at 5:9

1

Solved

I need a global logger that I can use across multiple classes in my project. I want to have logger settings in an ini file. I start following example here and combined it with some suggestions at ...
Moro asked 4/9, 2018 at 18:56

1

Solved

I am using the example at the following link. https://www.boost.org/doc/libs/1_57_0/libs/log/doc/html/log/detailed/utilities.html#log.detailed.utilities.setup.settings_file My code is as follows....
Velarde asked 31/8, 2018 at 21:55

4

I want to get year-month-day hour:minute:second.fraction(2 digits), if I use "%Y-%m-%d %H:%M:%S.%f", I got almost what I want exception for the fraction( last part ) of seconds, it's showing 6 digi...
Deguzman asked 10/5, 2011 at 8:6

3

Solved

I am trying to integrate Boost.Log in a fairly large application that is composed of a main application that dynamically loads plugins from DLLs. The initial idea was to pass a logging source to pl...
Afield asked 19/6, 2014 at 8:32

3

Solved

I have some trivial logging: BOOST_LOG_TRIVIAL(trace) << make_trace_record(); Now make_trace_record is a somewhat expensive function to call (don't ask why, it's complicated). I want to ca...
Buckley asked 15/5, 2018 at 6:58

1

Solved

[Follows up Check boost::log filter explicitly? ] The following example uses the trivial logger from Boost Log. It outputs 1, showing that expensive() is only called once. How does it work? Why is...
Lenticular asked 15/5, 2018 at 15:44

2

Solved

I have a sinks::text_file_backend sink. Say I already have a few rotated log files: myLog001.log, myLog002.log and so on I want the sink to keep writing to the last rotated file - myLog002.log, a...
Jezabella asked 7/12, 2011 at 16:35

1

Solved

I'm using boost::log to simultaneously log to a file as well as the console. It's initialized like so: void Init() { logging::core::get()->set_filter ( // set logging level to one of trace, d...
Ribonuclease asked 1/1, 2017 at 23:32

6

Solved

Can I use LineID attribute for this? I hope I could use sink::set_formatter to do this instead of using __LINE__ and __FILE__ in each log statement.
Epilate asked 28/2, 2014 at 12:47

2

Solved

I'm trying to add colored log output for boost::log under linux. I read the following and I tried this: #define MY_LOG_ERROR() BOOST_LOG_TRIVIAL(error) << "\033[1;31" MY_LOG_ERROR() <&lt...
Bremble asked 11/7, 2016 at 14:27

1

I am running into an issue where the use of Boost.Log in an app causes a crash or a hang when the app loads a shared library that uses Boost.ASIO! Any insights would be appreciated; a full cmake-bu...
Prosthodontist asked 9/10, 2016 at 22:4

1

Solved

I use the add_file_log() function to initialize a logging sink that stores log records into a text file. When I define several sinks, I have observed: a file is created for each sink. the output ...
Vilma asked 31/8, 2016 at 10:59

1

Solved

I'm using custom boost::log formatter for color coding the output log message, but I'm failing to find the proper way to add TimeStamp and ThreadID attributes to the log. When I'm using file loggin...
Belch asked 27/7, 2016 at 16:4

5

I'm using Boost-Log 2.0, which has some differences from version 1, and I have a hard time outputting the "Severity" attribute. I'm using the "Boost.Format-style" formatters "%TimeStamp% [%Uptim...
Steeplejack asked 6/4, 2013 at 17:33

1

Solved

On upgrading to boost 1.60.0 some applications are failing to link with boost log when built with MinGw 4.9.2 on Windows 7. I get the following linker errors: undefined reference to `_imp___ZN5bo...
Jedlicka asked 21/12, 2015 at 11:43

1

Solved

I have been studying Boost.Log for a while and I believe now is the time for me to transition my code base from log4cxx to Boost.Log. I believe the design and implementation of Boost.Log will signi...
Aoudad asked 18/12, 2015 at 19:46

2

Solved

In the Boost.Log documentation, it is said that Note The library uses basic_formatting_ostream stream type for record formatting, so when customizing attribute value formatting rules the ope...
Niemeyer asked 2/10, 2015 at 8:2

1

Boost.Log does not support fork(). This is kind of unbelievable, but a ticket comment describes a workaround: [..] so for now it's up to users to reinitialize the library at fork. You can use pt...
Shaikh asked 31/8, 2013 at 16:4

1

Solved

The following code works as expected with boost 1.57: #include <iostream> #include <boost/log/trivial.hpp> struct Foo { int d=1; }; std::ostream& operator<<(std::ostream&a...
Gradient asked 24/8, 2015 at 15:16

2

I am using Boost-Log and the global severity logger for my application's logging platform. Profiling shows that the boost::log::v2s_mt_posix::core::open_record can take up to 25% of the total execu...
Knownothing asked 17/6, 2014 at 9:17

2

Solved

I am trying to make my team go away from log4cxx and try to use Boost.Log v2 instead. Our current log4cxx pattern is rather simple: log4cxx::helpers::Properties prop; prop.setProperty("log4j.rootL...
Recognition asked 1/7, 2015 at 6:53

© 2022 - 2024 — McMap. All rights reserved.