You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
STOMP bots: several updates, fixes and improvements + some refactoring
The updates, fixes and improvements regard the *STOMP collector* and
*STOMP output* bots. Important changes are described below...
From now on, newer versions of the `stomp.py` package are supported --
including the latest (8.1.0).
Now both STOMP bots coerce the `port` configuration parameter to int --
so that a string representing an integer number is also acceptable (even
if not recommended) as a value of that parameter.
In the *STOMP output* bot, a bug has been fixed: `AttributeError` caused
by attempts to get unset attributes (`ssl_ca_cert` and companions...).
The *STOMP collector*'s reconnection mechanism has been fixed: from now
on, no reconnection attempts are made after `shutdown()`. Apart from
that, reconnection is not attempted at all for versions of `stomp.py`
older than 4.1.21 (as it did not work properly anyway).
Also regarding the *STOMP collector* bot, the following (undocumented
and unused) attributes of `StompCollectorBot` instances are no longer
set in `init()`: `ssl_ca_cert`, `ssl_cl_cert`, `ssl_cl_cert_key`.
Various checks have been improved/enhanced. Now, for example, both STOMP
bot classes implement the `check()` static/class method -- whose role is
to check ("statically", without the need to run the bot) configuration
parameters; in particular, it checks whether necessary certificate files
are accessible. When it comes to runtime (on-initialization) checks, one
notable improvement is that now also the *STOMP output* bot will raise a
`MissingDependencyError` if the `stomp.py` version is older than 4.1.8
(an analogous check has already been implemented by *STOMP collector*).
The code of those bot classes have also been significantly refactored
-- in particular, several common operations have been factored out and
placed in a new mix-in class: `intelmq.lib.mixins.StompMixin`; its
definition resides in a new module: `intelmq.lib.mixins.stomp`.
0 commit comments