-
Notifications
You must be signed in to change notification settings - Fork 58
Windows write to log if no debugger attached #1098
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
lib/pal/PAL.cpp
Outdated
| } | ||
| else | ||
| { | ||
| // Log to debug log file if enabled |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Biggest complaint was usually if something goes wrong (e.g. customer blocks the end-point with firewall), these logs may grow substantially big on disk. Win 10 Storage Sense somewhat alleviates it by cleaning up the old session logs, but still it may get bad, especially on server flavor. This needs to be carefully tested and the logs should def be OFF by default. Like, no logs should ever be created by default unless the app config for debug/dev/test environments explicitly enables it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have shifted logging to be default off. Is there somewhere I can note the change of behavior for users to be aware of that they will need to add a setting to continue getting logs?
Could you be more specific on the type of testing you would like to see?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please check with @lalitb during weekly meeting. As long as you can avoid SDK spewing too many warnings into log file (ensuring that normally the file isn't being written into), it's all good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just to add, there is plan to add the support for log rotation/limiting in near future.
f5af205 to
231ed84
Compare
…icrosoft/cpp_client_telemetry into thkarago/outputWindowsDebugLog
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. We can merge this after discussing in next week's community meeting.
* Windows write to log if no debugger attached * Added a preprocessor directive to turn on disk logging on windows
Should attempt to write debug info to log on windows if no debugger is available to recieve output
Debug logging will now be off by default