X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=doc%2FMCollective%2FRPC%2FStats.html;fp=doc%2Fclasses%2FMCollective%2FRPC%2FStats.html;h=50b77ae97d82d37b1945ff243c8f4ad2458c8c79;hb=refs%2Fheads%2Fhavana;hp=8f4522dbc7fbac900c3a0fcd61b74165096ec7bd;hpb=d1f1649ba43c5cbc43c4beb2380096ba051d646a;p=packages%2Fprecise%2Fmcollective.git diff --git a/doc/classes/MCollective/RPC/Stats.html b/doc/MCollective/RPC/Stats.html similarity index 50% rename from doc/classes/MCollective/RPC/Stats.html rename to doc/MCollective/RPC/Stats.html index 8f4522d..50b77ae 100644 --- a/doc/classes/MCollective/RPC/Stats.html +++ b/doc/MCollective/RPC/Stats.html @@ -1,290 +1,749 @@ - - - + +
-Class | -MCollective::RPC::Stats | -
In: | -
-
- lib/mcollective/rpc/stats.rb
-
- - |
-
Parent: | -- Object - | -
+ +
+ +Class to wrap all the stats and to keep track of some timings
-aggregate_failures | -[RW] | -- |
aggregate_summary | -[RW] | -- |
blocktime | -[RW] | -- |
ddl | -[RW] | -- |
discovered | -[RW] | -- |
discovered_nodes | -[RW] | -- |
discoverytime | -[RW] | -- |
failcount | -[RW] | -- |
noresponsefrom | -[RW] | -- |
noresponsefrom | -[RW] | -- |
okcount | -[RW] | -- |
requestid | -[RW] | -- |
responses | -[RW] | -- |
responsesfrom | -[RW] | -- |
starttime | -[RW] | -- |
totaltime | -[RW] | -- |
Fake hash access to keep things backward compatible
- -# File lib/mcollective/rpc/stats.rb, line 51 51: def [](key) 52: to_hash[key] 53: rescue 54: nil -55: end --
Re-initializes the object with stats from the basic client
- -# File lib/mcollective/rpc/stats.rb, line 72 72: def client_stats=(stats) @@ -295,83 +754,109 @@ Re-initializes the object with stats from the basic client 77: @totaltime = stats[:totaltime] 78: @requestid = stats[:requestid] 79: @discoverytime = stats[:discoverytime] if @discoverytime == 0 -80: end --
+Update discovered and discovered_nodes based on discovery +results
- -# File lib/mcollective/rpc/stats.rb, line 110 110: def discovered_agents(agents) 111: @discovered_nodes = agents 112: @discovered = agents.size -113: end --
increment the count of failed hosts
- -# File lib/mcollective/rpc/stats.rb, line 65 65: def fail 66: @failcount += 1 67: rescue 68: @failcount = 1 -69: end --
Helper to calculate total time etc
- -# File lib/mcollective/rpc/stats.rb, line 116 116: def finish_request @@ -384,28 +869,36 @@ Helper to calculate total time etc 123: rescue 124: @totaltime = 0 125: @noresponsefrom = [] -126: end --
Returns a blob of text indicating what nodes did not respond
- -# File lib/mcollective/rpc/stats.rb, line 237 237: def no_response_report @@ -424,85 +917,109 @@ Returns a blob of text indicating what nodes did not respond 250: end 251: 252: result_text.string -253: end --
Helper to keep track of who we received responses from
- -# File lib/mcollective/rpc/stats.rb, line 129 129: def node_responded(node) 130: @responsesfrom << node 131: rescue 132: @responsesfrom = [node] -133: end --
+increment the count of ok hosts
- -# File lib/mcollective/rpc/stats.rb, line 58 58: def ok 59: @okcount += 1 60: rescue 61: @okcount = 1 -62: end --
Returns a blob of text representing the request status based on the stats contained in this class
- -# File lib/mcollective/rpc/stats.rb, line 187 187: def report(caption = "rpc stats", summarize = true, verbose = false) @@ -552,28 +1069,36 @@ contained in this class 231: end 232: 233: result_text.join("\n") -234: end --
Resets stats, if discovery time is set we keep it as it was
- -# File lib/mcollective/rpc/stats.rb, line 14 14: def reset @@ -592,25 +1117,34 @@ Resets stats, if discovery time is set we keep it as it was 27: @requestid = nil 28: @aggregate_summary = [] 29: @aggregate_failures = [] -30: end --
(Not documented)
+ + + +# File lib/mcollective/rpc/stats.rb, line 135 135: def text_for_aggregates @@ -661,28 +1195,36 @@ Resets stats, if discovery time is set we keep it as it was 180: end 181: 182: result.string -183: end --
helper to time block execution time
- -# File lib/mcollective/rpc/stats.rb, line 96 96: def time_block_execution(action) @@ -695,28 +1237,36 @@ helper to time block execution time 103: end 104: rescue 105: @blocktime = 0 -106: end --
Utility to time discovery from :start to :end
- -# File lib/mcollective/rpc/stats.rb, line 83 83: def time_discovery(action) @@ -729,28 +1279,36 @@ Utility to time discovery from :start to :end 90: end 91: rescue 92: @discoverytime = 0 -93: end --
returns a hash of our stats
- -# File lib/mcollective/rpc/stats.rb, line 33 33: def to_hash @@ -768,22 +1326,33 @@ returns a hash of our stats 45: :failcount => @failcount, 46: :aggregate_summary => @aggregate_summary, 47: :aggregate_failures => @aggregate_failures} -48: end --
Disabled; run with --debug to generate this.
+ +Generated with the Darkfish + Rdoc Generator 1.1.6.
+