checks: no auto-const-set (was unclean), cl-parameter removed.
This commit is contained in:
parent
7832b62b51
commit
0480986133
|
@ -16,7 +16,6 @@ TO DO AND DONE
|
||||||
TODO
|
TODO
|
||||||
----
|
----
|
||||||
|
|
||||||
* build packet with performance data
|
|
||||||
* server side parsing of performance data
|
* server side parsing of performance data
|
||||||
* more documentations
|
* more documentations
|
||||||
* mcrypt-support
|
* mcrypt-support
|
||||||
|
@ -30,6 +29,7 @@ DONE
|
||||||
* server-API (recv from client)
|
* server-API (recv from client)
|
||||||
* check-API (describe checks and performance data)
|
* check-API (describe checks and performance data)
|
||||||
* fast usable API for sending checks
|
* fast usable API for sending checks
|
||||||
|
* build packet with performance data
|
||||||
|
|
||||||
Copyright
|
Copyright
|
||||||
=========
|
=========
|
||||||
|
|
|
@ -186,12 +186,12 @@ module NSCA
|
||||||
end
|
end
|
||||||
|
|
||||||
module Checks
|
module Checks
|
||||||
def perfdata( cl, *params) const_set cl, NSCA::PerformanceData.new( *params) end
|
def perfdata( *params) NSCA::PerformanceData.new( *params) end
|
||||||
|
|
||||||
def check cl, service, hostname, perfdatas = nil
|
def check service, hostname, perfdatas = nil
|
||||||
perfdatas ||= []
|
perfdatas ||= []
|
||||||
perfdatas.map! {|cl| cl.is_a?( Symbol) ? const_get( cl) : cl }
|
perfdatas.map! {|cl| cl.is_a?( Symbol) ? const_get( cl) : cl }
|
||||||
const_set cl, NSCA::Check.new( service, hostname, perfdatas)
|
NSCA::Check.new service, hostname, perfdatas
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue