Skip to content

Conversation

@SergeiPavlov
Copy link
Contributor

Currently even when we use NullLog the log messages are resolved from resources.

Suggested optimization:

  • Pass message ID to logger. Heavy ResourceManager.GetString() is called only for real logging. If the message id not found then messageId is used as message - it gurantees compatibility with existing code
  • IndentScope converted to struct to decrease memory allocations
  • Indent parameter converted from string to int, and indenting string is generated on demand.

SergeiPavlov and others added 8 commits July 13, 2022 11:12
Co-authored-by: Alexey Kulakov <alexey.kulakov@dataobjects.net>
Co-authored-by: Alexey Kulakov <alexey.kulakov@dataobjects.net>
Co-authored-by: Alexey Kulakov <alexey.kulakov@dataobjects.net>
Co-authored-by: Alexey Kulakov <alexey.kulakov@dataobjects.net>
Co-authored-by: Alexey Kulakov <alexey.kulakov@dataobjects.net>
SergeiPavlov and others added 2 commits July 14, 2022 00:48
Co-authored-by: Alexey Kulakov <alexey.kulakov@dataobjects.net>
Co-authored-by: Alexey Kulakov <alexey.kulakov@dataobjects.net>
@alex-kulakov alex-kulakov merged commit 0afc1c1 into DataObjects-NET:master Jul 15, 2022
@SergeiPavlov SergeiPavlov deleted the upstream/optimize_Logging branch July 15, 2022 08:54
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