Skip to content

Commit

Permalink
disable telemetry logging for scm commands
Browse files Browse the repository at this point in the history
Summary: Disable telemetry logging in the FB version of mercurial by default, as we generate a LOT of log calls.

Reviewed By: wez

Differential Revision: D9141848

fbshipit-source-id: 5fd6bac867527bbe1ae7ce35d0eba460308c9542
  • Loading branch information
singhsrb authored and facebook-github-bot committed Aug 3, 2018
1 parent b7ccef8 commit 174dfa8
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions scm/Mercurial.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@ ChildProcess::Options Mercurial::makeHgOptions(w_string requestId) const {
// Ensure that the hgrc doesn't mess with the behavior
// of the commands that we're runing.
opt.environment().set("HGPLAIN", w_string("1"));
// Ensure that we do not telemetry log profiling data for the commands we are
// running by default. This is to avoid a significant increase in the rate of
// logging.
if (!cfg_get_bool("enable_hg_telemetry_logging", false)) {
opt.environment().set("NOSCMLOG", w_string("1"));
}
// chg can elect to kill all children if an error occurs in any child.
// This can cause commands we spawn to fail transiently. While we'd
// love to have the lowest latency, the transient failure causes problems
Expand Down

0 comments on commit 174dfa8

Please sign in to comment.