Class: CheckHTTP::Checker
- Inherits:
-
Object
- Object
- CheckHTTP::Checker
- Defined in:
- lib/check_http/checker.rb
Instance Method Summary collapse
Instance Method Details
#blacklist ⇒ Object
3 4 5 |
# File 'lib/check_http/checker.rb', line 3 def blacklist [:response_header, :response_body, :httpauth_avail, :starttransfer_time, :appconnect_time, :pretransfer_time] end |
#check(url) ⇒ Object
7 8 9 10 11 12 13 |
# File 'lib/check_http/checker.rb', line 7 def check(url) ethon.reset ethon.url = url ethon.prepare ethon.perform ethon.to_hash.reject { |k,v| blacklist.include?(k) }.merge(:url => url) end |
#ethon ⇒ Object
15 16 17 |
# File 'lib/check_http/checker.rb', line 15 def ethon @ethon ||= Ethon::Easy.new end |