Skip to content

Conversation

@lalitb
Copy link
Contributor

@lalitb lalitb commented Jan 20, 2023

Ongoing PR, not yet for review.
Included changes

  • Deprecate shared global state (the LogManager instance that is not really an instance).
  • Return unique_ptr for ILogManager.

@lalitb lalitb marked this pull request as draft January 20, 2023 05:34
/// Obtain a raw pointer to the ILogManager singleton instance.
/// NOTE: this API should not be used concurrently with Initialize or FlushAndTeardown API calls.
/// </summary>
static ILogManager* GetInstance() noexcept
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This probably needs to go as well

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really all the static methods

Copy link
Contributor Author

@lalitb lalitb Mar 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I am trying to see if we can make LogManager as instance of LogManagerBase instead of global static, and then make all these methods as non-static. Though LogConfiguration is still a concern here, as it is difficult to create deep copy of it (as it can contain void * as the config value).

@lalitb lalitb marked this pull request as ready for review March 16, 2023 03:50
@lalitb lalitb marked this pull request as draft March 16, 2023 19:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants