1. Home
  2. Docs
  3. Monitoring rules
  4. Jeyzer Rules
  5. Stickers

Stickers

Rules and groups of rules can have optional stickers that indicate in which situation those gets activated and therefore the rules applied.

Stickers are static conditions which can be either:

  • Ambient analyzer condition
    The sticker is a flag provided within a list, usually set through an environment variable.
    <!-- Analyzer ambient stickers. Examples : code_quality, performance, security.. -->
    <sticker_set list="${JEYZER_MONITOR_ANALYZER_STICKERS}" group="analyzer"/>


  • Target applicative condition
    The sticker can be matched against a value available in the JZR recording. It can be a :

    • Process card property value
      <sticker name="windows" type="property card" property="os.name" pattern="Windows"/>
    • Process command line parameter
      Below example would match any startup parameter such as -Dlevel=debug or -level=debug or level=debug
      <sticker name="debug" type="process command line property" property="level" pattern="debug"/>
    • Process jar version
      <sticker name="logback-1.0.x" type="process jar version" jar_name="logback-classic" pattern="^1.0.*"/>
    • Java module version (since Jeyzer 2.2)
      <sticker name="logback-1.0.x" type="process module version" module_name="ch.qos.logback.core" pattern="^1.0.*"/>

      Sticker relies here on the process card, process jar and process module information availability.
      If not available, the sticker will match negatively by default.
      To get a positive match instead, set the appliance attribute on the sticker with the value lazy (default is strict).
  • Rule blocker condition
    The rule blocker permits to disable a monitoring rule.
    It is interesting when overriding standard monitoring rules with more elaborated ones. One could also disable any standard rule that would not be suitable.
    The blocker rule sticker must simply be created by declaring a “rule-block-<rule reference>" in any sticker list.
    Example : rule-block-JZR-STD-015
    To test it, add it to the JEYZER_MONITOR_ANALYZER_STICKERS variable.
    To industrialize it, create your own list of stickers in the monitoring configuration and/or related sheets :
    <sticker_set list="rule-block-JZR-STD-015, rule-block-JZR-STD-019" group="blockers"/>
    Since Jeyzer 3.0

Stickers can be defined at global level (in the default_setup.xml) or at master or shared profile level along with the monitoring rule declarations.

Stickers usually belong to a group :
<stickers group="Operating Systems">
<sticker name="windows" type="property card" property="os.name" pattern="Windows"/>

Stickers are referenced either at rule group level (which therefore applies to all the rules of this group) or at rule level :
<rules stickers="windows">
<rule name="Frozen stacks" stickers="java8, debug">

Sticker reference can be the sticker name (java8) or the full sticker name (group prefixed : Java version.java8).

Sticker reference can use the negative logical operator :
<rule name="Frozen stacks" stickers="!prod">

The JZR sheet monitoring_stickers permits to list the available stickers in the analysis and their matching value.

The Jeyzer monitoring rule “Sticker match” permits to generate monitoring events based only on its rule stickers.