Home Screenshots Download Order Contact Help


Content parser.

Overview Overview
Using ProtoMon Using ProtoMon
Monitor list Monitor List
Info panel Info Panel
Features list Failures List
Statistics viewer Statistics Viewer
Maintenance scheduler Maintenance Scheduler
Reports scheduler Reports Scheduler
Adding monitors Adding Monitors
Import monitors Import Monitors
General settings General Settings
Content filter Content Filter
Content parser Content Parser
Monitor alerts Monitor Alerts
Testing monitor Testing Monitor
Monitor types Monitor Types
Ping monitor Ping Monitor
HTTP monitor HTTP Monitor
FTP monitor FTP Monitor
POP3 monitor POP3 Monitor
IMAP monitor IMAP Monitor
SMTP monitor SMTP Monitor
Telnet monitor Telnet Monitor
SFTP monitor SFTP Monitor
Custom monitor Custom Monitor
Console monitor Console Monitor
Agent monitor Agent Monitor
Alerts Alerts
Pop-up window Pop-up Window
Sound alert Sound Alert
E-Mail notification E-Mail Notification
Overriding alerts Launch Application
Overriding Alerts
Sound settings Sound Settings
E-mail settings E-Mail Settings
Launch settings Launch Settings
Other features Other Features
Bulk edit monitors Bulk Edit Monitors
Internet connection Internet Connection
Remote viewing Remote Viewing
Summary report Summary Report
Logging Logging Settings
Registration Registration
Support Support

Content parser is an advanced version of a Content filter, which was described in the previous topic. It also works with the content received by the HTTP, FTP, SFTP, Telnet, SSH and Console monitors. But it doesn't simply searches for some text strings.

Content parser checks the content against the specified Parsing Template and extracts pieces of content to a named variables. Then it evaluates the Success Criteria boolean expression which can compare these variables between each other or some constant values. If this expression returns "false", ProtoMon considers that the monitor check failed, and triggers the corresponding alerts.

Content parser

The placeholders for variables are marked in the template using the double curly brackets. For example, if you getting an HTML page from your server, indicating some tabled stats including a cell with the temperature in the server room:

...<td id="temperature">22</td>...

The temperature can be parsed using the following template:

<td id="temperature">{{Temperature}}</td>

And then checked for an acceptable range using the following expression:

Temperature > 0 and Temperature < 25

You can include any number of variables to the template, just make sure to separate them with some text, so ProtoMon can define the boundaries of each variable. Opened and closed double curly brackets without the variable name inside means "any text" and allows you to skip useless parts of the content.

The parsed variables with values will be printed to the monitor check log, so you will easily know either your template extracts needed parts of content or not.

Content parser results

Last but not least, ProtoMon saves parsed variables prepending the underscore character to each of them. These variables will be accessible during the next monitor check. So you can compare the new value with the old one. For example, this success criteria says ProtoMon to trigger an alert, if the temperature is changed since the previous check:

Temperature = _Temperature

Please note, that on the very first monitor check, when there is no saved old value yet, ProtoMon will consider that old and new values are equal.