storm-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bo...@apache.org
Subject [09/11] git commit: Merge branch 'storm-monitor-cmd' of https://github.com/Gvain/incubator-storm into STORM-312
Date Wed, 16 Jul 2014 14:48:14 GMT
Merge branch 'storm-monitor-cmd' of https://github.com/Gvain/incubator-storm into STORM-312

STORM-312: add storm monitor tools to monitor throughtput interactively


Project: http://git-wip-us.apache.org/repos/asf/incubator-storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-storm/commit/bbb3e749
Tree: http://git-wip-us.apache.org/repos/asf/incubator-storm/tree/bbb3e749
Diff: http://git-wip-us.apache.org/repos/asf/incubator-storm/diff/bbb3e749

Branch: refs/heads/master
Commit: bbb3e749ea3a5ccb5d04916656bba670477fa696
Parents: e5226db e6b6e3c
Author: Robert (Bobby) Evans <bobby@apache.org>
Authored: Tue Jul 15 12:52:29 2014 -0500
Committer: Robert (Bobby) Evans <bobby@apache.org>
Committed: Tue Jul 15 12:52:29 2014 -0500

----------------------------------------------------------------------
 bin/storm                                       |  20 +-
 .../src/clj/backtype/storm/command/monitor.clj  |  37 +++
 .../src/jvm/backtype/storm/utils/Monitor.java   | 249 +++++++++++++++++++
 3 files changed, 305 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-storm/blob/bbb3e749/bin/storm
----------------------------------------------------------------------
diff --cc bin/storm
index 2cdf2be,9d7b133..a4aadb1
--- a/bin/storm
+++ b/bin/storm
@@@ -422,14 -388,32 +422,32 @@@ def print_classpath()
  
      Prints the classpath used by the storm client when running commands.
      """
 -    print get_classpath([])
 +    print(get_classpath([]))
  
+ def monitor(*args):
+     """Syntax: [storm monitor topology-name [-i interval-secs] [-m component-id] [-s stream-id]
[-w [emitted | transferred]]]
+ 
+     Monitor given topology's throughput interactively.
+     One can specify poll-interval, component-id, stream-id, watch-item[emitted | transferred]
+     By default,
+         poll-interval is 4 seconds;
+         all component-ids will be list;
+         stream-id is 'default';
+         watch-item is 'emitted';
+     """
+     exec_storm_class(
+         "backtype.storm.command.monitor",
+         args=args,
+         jvmtype="-client",
+         extrajars=[USER_CONF_DIR, STORM_DIR + "/bin"])
+ 
+ 
  def print_commands():
      """Print all client commands and link to documentation"""
 -    print "Commands:\n\t",  "\n\t".join(sorted(COMMANDS.keys()))
 -    print "\nHelp:", "\n\thelp", "\n\thelp <command>"
 -    print "\nDocumentation for the storm client can be found at http://storm.incubator.apache.org/documentation/Command-line-client.html\n"
 -    print "Configs can be overridden using one or more -c flags, e.g. \"storm list -c nimbus.host=nimbus.mycompany.com\"\n"
 +    print("Commands:\n\t" +  "\n\t".join(sorted(COMMANDS.keys())))
 +    print("\nHelp: \n\thelp \n\thelp <command>")
 +    print("\nDocumentation for the storm client can be found at http://storm.incubator.apache.org/documentation/Command-line-client.html\n")
 +    print("Configs can be overridden using one or more -c flags, e.g. \"storm list -c nimbus.host=nimbus.mycompany.com\"\n")
  
  def print_usage(command=None):
      """Print one help message or list of available commands"""


Mime
View raw message