Repository: storm Updated Branches: refs/heads/1.0.x-branch 9ce36ad76 -> 106dfff61
STORM-2063: allow default thread name in case we don't have a better name for it, turn on %t in worker.xml by default Project: http://git-wip-us.apache.org/repos/asf/storm/repo Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/54dd2a8f Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/54dd2a8f Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/54dd2a8f Branch: refs/heads/1.0.x-branch Commit: 54dd2a8f8fabb4d4a58034392717558d95b6a3de Parents: 9ce36ad Author: Alessandro Bellina <[email protected]> Authored: Mon Aug 29 07:44:18 2016 -0500 Committer: Jungtaek Lim <[email protected]> Committed: Wed Aug 31 16:25:27 2016 +0900 ---------------------------------------------------------------------- log4j2/worker.xml | 2 +- storm-core/src/clj/org/apache/storm/util.clj | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/storm/blob/54dd2a8f/log4j2/worker.xml ---------------------------------------------------------------------- diff --git a/log4j2/worker.xml b/log4j2/worker.xml index a9aeaed..f1e23a1 100644 --- a/log4j2/worker.xml +++ b/log4j2/worker.xml @@ -18,7 +18,7 @@ <configuration monitorInterval="60"> <properties> - <property name="pattern">%d{yyyy-MM-dd HH:mm:ss.SSS} %c{1.} [%p] %msg%n</property> + <property name="pattern">%d{yyyy-MM-dd HH:mm:ss.SSS} %c{1.} %t [%p] %msg%n</property> <property name="patternNoTime">%msg%n</property> <property name="patternMetrics">%d %-8r %m%n</property> </properties> http://git-wip-us.apache.org/repos/asf/storm/blob/54dd2a8f/storm-core/src/clj/org/apache/storm/util.clj ---------------------------------------------------------------------- diff --git a/storm-core/src/clj/org/apache/storm/util.clj b/storm-core/src/clj/org/apache/storm/util.clj index 4765de8..4297a21 100644 --- a/storm-core/src/clj/org/apache/storm/util.clj +++ b/storm-core/src/clj/org/apache/storm/util.clj @@ -494,7 +494,8 @@ (kill-fn t)))))] (.setDaemon thread daemon) (.setPriority thread priority) - (when thread-name + (when-not (clojure.string/blank? thread-name) + ;; if thead-name is blank, just use the default thread name (.setName thread (str (.getName thread) "-" thread-name))) (when start (.start thread))
