Arun kumar Kalaiarasan
Arun kumar Kalaiarasan

Reputation: 386

Is it possible to create many instances of boost logger?

    Since Boost log having many characteristics like thread- safe and etc., I want to know that can we able to create many instances of the logger.

    Because I read in document that Boost log creates only one instance. Is it true?

   Is there any other logging library which supports from Windows XP or it may be platform independent.

   Please Suggest your ideas and information that you may know.

    Thanks,

    AK.

Upvotes: 1

Views: 1146

Answers (2)

Thiyaga
Thiyaga

Reputation: 79

Yes, it is possible to create many logger by using

BOOST_LOG_ATTRIBUTE_KEYWORD(tag_attr, "Tag", std::string)

or

BOOST_LOG_SCOPED_THREAD_TAG("Tag", tag_)

For more details, you can check the following link

Upvotes: 1

Andrey Semashev
Andrey Semashev

Reputation: 10614

You can create as many loggers as you like, see here, for instance. However, there is only one logging core, and you cannot create multiple cores.

Upvotes: 0

Related Questions