Xymon Mailing List Archive search

Any way to do http tests with HEAD request?

list Japheth Cleaver
Fri, 17 Apr 2015 10:12:40 -0700
Message-Id: <user-73293830c01d@xymon.invalid>


On Thu, April 16, 2015 6:00 pm, Andrew Rakowski wrote:
Hi jc,

On Mon, 13 Apr 2015, J.C. Cleaver wrote:
Thinking about it, this might be something that's not too difficult to
add
into xymonnet either. A HEAD is basically just a GET from the poller's
perspective, and any evaluation on body contents (or lack thereof) is
semantically identical to the configuration options available now.

An open question is what the best way to indicate that this is a
"HEAD-only" test would be.

It could be something applied to the entire host line (like browser=),
made into a separate column (similar to httpstatus= or post=, except
without the... POST), or another per-URL protocol specifier similar to
how
the TLS/SSL configuration is handled.
Unless there's significant savings in overhead one way over the other, I
see no problem with doing it whichever way is simplest to implement.

From my point of view, if I'm testing multiple URLs on the same server, it
would typically be for different applications, and I'd probably make a
separate host line for each app (so I could have different notifications
to the app maintainer.)  If the web server itself is failing, then I'd see
the problem across multiple app URLs and know the problem was with the web
server itself.

However, if per URL is easier, that would work just as well.

For the time being, I guess I'll just have to make a special case external
script to test using curl (and try to convince the developers that they
should always have a 'test' URL that doesn't take large amounts of
processing just to verify things are working...)

-Andrew
Hi Andrew,


HEAD support using the syntax
"httphead[=COL];http://www.example.com/blah/"; has been added in, and
should be available in the next release.


HTH,

-jc