check file xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1-state with path /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1/STATE
  if match
    "^.*SHUTDOWN.*$"
    then exec "/etc/monit/tools/monit-unmonitor.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1"
  if match
    "^.*STARTUP.*$"
    then exec "/etc/monit/tools/monit-monitor.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1"
  set alert h.hasenbein@24technology.de but not on { instance, nonexist }
  mail-format {
    from: monit@tehhrxxxxx1.24t.loc
    subject: $SERVICE $EVENT at $DATE
    message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION.
    best regards,
    Hendrik Hasenbein
  }
  set mailserver x.24translate.de

check file xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1-catalina with path /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1/logs/catalina.out
  group xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1
  if does not exist then unmonitor
  if match
    "^.*OutOfMemoryError.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  if match
    "^.*SEVERE: All threads .* are currently busy.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  set alert h.hasenbein@24technology.de but not on { instance, nonexist }
  mail-format {
    from: monit@tehhrxxxxx1.24t.loc
    subject: $SERVICE $EVENT at $DATE
    message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION.
    best regards,
    Hendrik Hasenbein
  }
  set mailserver x.24translate.de

check file xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1-APP_NAME with path /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1/logs/APP_NAME.log
  group "xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1"
  if match
    "^.*OutOfMemoryError.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  if match
    "^.*SEVERE: All threads .* are currently busy.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  set alert h.hasenbein@24technology.de but not on { instance }
  mail-format {
    from: monit@tehhrxxxxx1.24t.loc
    subject: $SERVICE $EVENT at $DATE
    message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION.
    best regards,
    Hendrik Hasenbein
  }
  set mailserver x.24translate.de

check file xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1-probe with path /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1/logs/probe.log
  group "xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1"
  if match
    "^.*OutOfMemoryError.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  if match
    "^.*SEVERE: All threads .* are currently busy.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  set alert h.hasenbein@24technology.de but not on { instance }
  mail-format {
    from: monit@tehhrxxxxx1.24t.loc
    subject: $SERVICE $EVENT at $DATE
    message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION.
    best regards,
    Hendrik Hasenbein
  }
  set mailserver x.24translate.de

check file xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1-slow-requests with path /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1/logs/slow-requests.log
  group "xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1"
  if match
    "^.*OutOfMemoryError.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  if match
    "^.*SEVERE: All threads .* are currently busy.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  set alert h.hasenbein@24technology.de but not on { instance }
  mail-format {
    from: monit@tehhrxxxxx1.24t.loc
    subject: $SERVICE $EVENT at $DATE
    message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION.
    best regards,
    Hendrik Hasenbein
  }
  set mailserver x.24translate.de

check file xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1-xxx-xxx-xxxx-supplier with path /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1/logs/xxx-xxx-xxxx-supplier.log
  group "xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1"
  if match
    "^.*OutOfMemoryError.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  if match
    "^.*SEVERE: All threads .* are currently busy.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  set alert h.hasenbein@24technology.de but not on { instance }
  mail-format {
    from: monit@tehhrxxxxx1.24t.loc
    subject: $SERVICE $EVENT at $DATE
    message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION.
    best regards,
    Hendrik Hasenbein
  }
  set mailserver x.24translate.de

check file xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1-tempFileDeletionService with path /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1/logs/tempFileDeletionService.log
  group "xxxxxxxx-xxxxxxxxxx-xxx-xxxx-su1"
  if match
    "^.*OutOfMemoryError.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  if match
    "^.*SEVERE: All threads .* are currently busy.*$"
    then exec "/etc/monit/tools/tomcat-restart.sh /opt/xxxx/xxxx-xxxxxxx/TomC/xxx-xxx-xxxx-su1" as uid tomcat and gid tomcat
  set alert h.hasenbein@24technology.de but not on { instance }
  mail-format {
    from: monit@tehhrxxxxx1.24t.loc
    subject: $SERVICE $EVENT at $DATE
    message: Monit $ACTION $SERVICE at $DATE on $HOST: $DESCRIPTION.
    best regards,
    Hendrik Hasenbein
  }
  set mailserver x.24translate.de
