Skip to content

Commit

Permalink
Merge 47628c2 into 1b58857
Browse files Browse the repository at this point in the history
  • Loading branch information
susam committed Apr 13, 2019
2 parents 1b58857 + 47628c2 commit 9f53e80
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 0 deletions.
22 changes: 22 additions & 0 deletions cloudmarker/alerts/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
"""A package for alert plugins packaged with this project.
This package contains alert plugins that are packaged as part of this
project. The alert plugins implement a function named ``write()`` that
accepts input records and typically sends them to an alerting
destination. The alert plugins also implement and a function named
``done`` that perform cleanup work when called.
Note that the alert plugins implement the exact same interface as the
store plugins in the :mod:`cloudmarker.stores` package. So a store
plugin can usually serve equally well as an alert plugin, and vice
versa. In fact, some of the store plugins such as
:class:`cloudmarker.stores.esstore.EsStore` and
:class:`cloudmarker.stores.mongodbstore.MongoDBStore` are indeed used as
alert plugins too because security events can be alerted by storing them
in an Elasticsearch index or MongoDB collection.
If a plugin can serve as both a store plugin and an alert plugin, we
keep them in the :mod:`cloudmarker.stores` package. If a plugin makes
sense only as an alert plugin, we keep them in this
:mod:`cloudmarker.alerts` package.
"""
28 changes: 28 additions & 0 deletions docs/api/cloudmarker.alerts.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
cloudmarker.alerts package
==========================

.. automodule:: cloudmarker.alerts
:members:
:undoc-members:
:show-inheritance:

Submodules
----------

cloudmarker.alerts.emailalert module
------------------------------------

.. automodule:: cloudmarker.alerts.emailalert
:members:
:undoc-members:
:show-inheritance:

cloudmarker.alerts.slackalert module
------------------------------------

.. automodule:: cloudmarker.alerts.slackalert
:members:
:undoc-members:
:show-inheritance:


1 change: 1 addition & 0 deletions docs/api/cloudmarker.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Subpackages

.. toctree::

cloudmarker.alerts
cloudmarker.clouds
cloudmarker.events
cloudmarker.stores
Expand Down

0 comments on commit 9f53e80

Please sign in to comment.