<?xml version="1.0" ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Medratio</title> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <link rev="made" href="mailto:root@localhost" /> </head> <body style="background-color: white"> <p><a name="__index__"></a></p> <!-- INDEX BEGIN --> <!-- <ul> <li><a href="#name">NAME</a></li> <li><a href="#overview">OVERVIEW</a></li> <li><a href="#description">DESCRIPTION</a></li> <li><a href="#example">EXAMPLE</a></li> <li><a href="#copyright">COPYRIGHT</a></li> <li><a href="#sponsorship">SPONSORSHIP</a></li> <li><a href="#license">LICENSE</a></li> <li><a href="#author">AUTHOR</a></li> </ul> --> <!-- INDEX END --> <p> </p> <h1><a name="name">NAME</a></h1> <p>Smokeping::matchers::Medratio - detect changes in the latency median</p> <p> </p> <hr /> <h1><a name="overview">OVERVIEW</a></h1> <p>The Medratio matcher establishes a historic median latency over several measurement rounds. It compares this median, against a second median latency value again build over several rounds of measurement.</p> <p>By looking at the median value this matcher is largly imune against spikes and will only react to long term developments.</p> <p> </p> <hr /> <h1><a name="description">DESCRIPTION</a></h1> <p>Call the matcher with the following sequence:</p> <pre> type = matcher pattern = Medratio(historic=>a,current=>b,comparator=>o,percentage=>p)</pre> <dl> <dt><strong><a name="item_historic">historic</a></strong> </dt><dd> <p>The number of values to use for building the 'historic' median.</p> </dd><dt><strong><a name="item_current">current</a></strong> </dt><dd> <p>The number of values to use for building the 'current' median.</p> </dd><dt><strong><a name="item_comparator">comparator</a></strong> </dt><dd> <p>Which comparison operator should be used to compare current/historic with percentage.</p> </dd><dt><strong><a name="item_percentage">percentage</a></strong> </dt><dd> <p>Right hand side of the comparison.</p> </dd></dl> <pre> old <--- historic ---><--- current ---> now</pre> <p> </p> <hr /> <h1><a name="example">EXAMPLE</a></h1> <p>Take the 12 last median values. Build the median out of the first 10 and the median from the other 2 values. Divide the results and decide if it is bigger than 150 percent.</p> <pre> Medratio(historic=>10,current=>2,comparator=>'>',percentage=>150);</pre> <pre> med(current)/med(historic) > 150/100</pre> <p>This means the matcher will activate when the current latency median is more than 1.5 times the historic latency median established over the last 10 rounds of measurement.</p> <p> </p> <hr /> <h1><a name="copyright">COPYRIGHT</a></h1> <p>Copyright (c) 2006 by OETIKER+PARTNER AG. All rights reserved.</p> <p> </p> <hr /> <h1><a name="sponsorship">SPONSORSHIP</a></h1> <p>The development of this matcher has been paied for by Virtela Communications, <a href="http://www.virtela.net/">http://www.virtela.net/</a>.</p> <p> </p> <hr /> <h1><a name="license">LICENSE</a></h1> <p>This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.</p> <p>This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.</p> <p>You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.</p> <p> </p> <hr /> <h1><a name="author">AUTHOR</a></h1> <p>Tobias Oetiker <<a href="mailto:tobi@oetiker.ch">tobi@oetiker.ch</a>></p> </body> </html>