diff options
author | Alistair Coles <alistairncoles@gmail.com> | 2022-02-04 10:58:46 +0000 |
---|---|---|
committer | Alistair Coles <alistairncoles@gmail.com> | 2022-02-07 17:46:06 +0000 |
commit | eda7d5fe3c9527ae20850b38f8b626782dd5efec (patch) | |
tree | 6a11e0bb89370be23c4f3606becc97d08f31a29f /doc | |
parent | 2a60c91f6fcf9ed165a008c8800e475e5f2fc777 (diff) | |
download | swift-eda7d5fe3c9527ae20850b38f8b626782dd5efec.tar.gz |
Deprecate LogAdapter.set_statsd_prefix
Previously, the set_statsd_prefix method was used to mutate a logger's
StatsdClient tail prefix after a logger was instantiated. This pattern
had led to unexpected mutations (see Related-Change). The tail_prefix
can now be passed as an argument to get_logger(), and is then
forwarded to the StatsdClient constructor, for a more explicit
assignment pattern.
The set_statsd_prefix method is left in place for backwards
compatibility. A DeprecationWarning will be raised if it is used
to mutate the StatsdClient tail prefix.
Change-Id: I7692860e3b741e1bc10626e26bb7b27399c325ab
Related-Change: I0522b1953722ca96021a0002cf93432b973ce626
Diffstat (limited to 'doc')
-rw-r--r-- | doc/source/admin/objectstorage-monitoring.rst | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/doc/source/admin/objectstorage-monitoring.rst b/doc/source/admin/objectstorage-monitoring.rst index cc3b31fa4..86e81711b 100644 --- a/doc/source/admin/objectstorage-monitoring.rst +++ b/doc/source/admin/objectstorage-monitoring.rst @@ -145,14 +145,6 @@ require accuracy (``sample_rate=1``) while others may not. Then the LogAdapter object returned by ``get_logger()``, usually stored in ``self.logger``, has these new methods: -- ``set_statsd_prefix(self, prefix)`` Sets the client library stat - prefix value which gets prefixed to every meter. The default prefix - is the ``name`` of the logger such as ``object-server``, - ``container-auditor``, and so on. This is currently used to turn - ``proxy-server`` into one of ``proxy-server.Account``, - ``proxy-server.Container``, or ``proxy-server.Object`` as soon as the - Controller object is determined and instantiated for the request. - - ``update_stats(self, metric, amount, sample_rate=1)`` Increments the supplied meter by the given amount. This is used when you need to add or subtract more that one from a counter, like incrementing |