Skip to content
This repository has been archived by the owner on Mar 3, 2023. It is now read-only.

Commit

Permalink
Reduce verbosity of zookeeper logging (#1547)
Browse files Browse the repository at this point in the history

* reduce more log verbosity
  • Loading branch information
Bill Graham authored Nov 10, 2016
1 parent 61e8e15 commit 3c0add9
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,16 @@ public static void loggerInit(Level level, boolean isRedirectStdOutErr, String f

rootLogger.setLevel(level);

if (rootLogger.getLevel().intValue() < Level.WARNING.intValue()) {
// zookeeper logging scares me. if people want this, we can patch to config-drive this
Logger.getLogger("org.apache.zookeeper").setLevel(Level.WARNING);
}

if (isRedirectStdOutErr) {

// Remove ConsoleHandler if present, to avoid StackOverflowError.
// ConsoleHandler writes to System.err and since we are redirecting
// System.err to Logger, it results in an infinte loop.
// System.err to Logger, it results in an infinite loop.
for (Handler handler : rootLogger.getHandlers()) {
if (handler instanceof ConsoleHandler) {
rootLogger.removeHandler(handler);
Expand Down
6 changes: 3 additions & 3 deletions third_party/pex/_pex.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def main():
poptions.disable_cache = options.disable_cache


print("pex options: %s" % poptions)
#print("pex options: %s" % poptions)
os.environ["PATH"] = ".:%s:/bin:/usr/bin" % poptions.python

# The version of pkg_resources.py (from setuptools) on some distros is too old for PEX. So
Expand All @@ -156,8 +156,8 @@ def main():

# Add prebuilt libraries listed in the manifest.
reqs = manifest.get('requirements', {}).keys()
if len(reqs) > 0:
print("pex requirements: %s" % reqs)
#if len(reqs) > 0:
# print("pex requirements: %s" % reqs)
pex_builder = build_pex(reqs, poptions,
resolver_options_builder, interpreter=interpreter)

Expand Down

0 comments on commit 3c0add9

Please sign in to comment.