Homec4science

Enable log discard modes for all scripts

Authored by epriestley <git@epriestley.com> on Jan 9 2013, 00:54.

Description

Enable log discard modes for all scripts

Summary:
Fixes T2273. We currently discard logs, service calls, etc., for daemons, but not for other scripts. However, other scripts may be long-running or issue a large body of service calls (e.g., bin/search index --all). We never retrieve this information from scripts (it is used to build darkconsole; in scripts, we echo it immediately under --trace), so discard it immediately to prevent these scripts from requiring a large amount of memory.

(When the daemons load __init_script__.php they end up calling this code, so this doesn't change anything for them. They hit another ServiceProfiler discard along the daemon pathways in libphutil, but the call is idempotent.)

Test Plan: Ran bin/search index --all and saw increasing memory usage before this patch, but steady memory usage after this patch.

Reviewers: btrahan, vrana, codeblock

Reviewed By: codeblock

CC: aran

Maniphest Tasks: T2273

Differential Revision: https://secure.phabricator.com/D4364

Details

Committed
epriestley <git@epriestley.com>Jan 9 2013, 00:54
Pushed
aubortJan 31 2017, 17:16
Parents
rPH7752717125de: Fix a MetaMTA array_combine() warning
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHcbe9aea8761e: Enable log discard modes for all scripts (authored by epriestley <git@epriestley.com>).Jan 9 2013, 00:54