IcsUtils.IcsAlert Common Library

IcsAlert: Library for Alert

This is the IcsAlert common library.
class opslib.icsutils.icsalert.IcsAlert(region, topic, msg_prefix='', **kwargs)[source]
__dict__ = <dictproxy object at 0x4b01b78>
__init__(region, topic, msg_prefix='', **kwargs)[source]

Generate and send alerts when exceptions occur

Parameters:
  • region (str) – indicate region name you need to generate SNS alerts
  • topic (str) – indicate topic name you have already setup in SNS
  • msg_prefix (str) – prefix of alert message
__module__ = 'opslib.icsutils.icsalert'
__weakref__

list of weak references to the object (if defined)

sendAlert(msg, subj_result)[source]

Send SNS message as an Alert

Parameters:
  • msg (str) – message of the alert
  • subj_result (str) – SUCCESS/ERROR described in subject content
sendHealthAlert(msg, subj)[source]

Send SNS message as an Alert

Parameters:
  • msg (str) – message of the alert
  • subj (str) – subject of message

Indices and tables

Table Of Contents

Previous topic

IcsSQS Common Library

Next topic

IcsUtils.Misc Common Library

This Page