Python library for Services metrics logging

mozilla-services mozilla-services Last update: Jul 02, 2021

This project has been superceded byheka-py https://github.com/mozilla-services/heka-py andhekad https://github.com/mozilla-services/heka.

This repository is no longer being actively maintained.

metlog-py

https://secure.travis-ci.org/mozilla-services/metlog-py.png

metlog-py is a Python client for the "Metlog" system of application logging andmetrics gathering developed by the Mozilla Services team. The Metlog system is meant to makelife easier for application developers with regard to generating and sendinglogging and analytics data to various destinations. It achieves this goal (wehope!) by separating the concerns of message generation from those of messagedelivery and analysis. Front end application code no longer has to dealdirectly with separate back end client libraries, or even know what back enddata storage and processing tools are in use. Instead, a message is labeledwith a type (and possibly other metadata) and handed to the Metlog system,which then handles ultimate message delivery.

The Metlog system consists of three pieces:

generator
This is the application that will be generating the data that is to be sentinto the system.
router
This is the initial recipient of the messages that the generator will besending. Typically, a metlog router deserializes the messages it receives,examines them, and decides based on the message metadata or contents whichendpoint(s) to which the message should be delivered.
endpoints
Different types of messages lend themselves to different types ofpresentation, processing, and analytics. The router has the ability todeliver messages of various types to destinations that are appropriate forhandling those message types. For example, simple log messages might beoutput to a log file, while counter timer info is delivered to a statsd server, and Python exception informationis sent to a Sentry server.

The metlog-py library you are currently reading about is a client library meantto be used by Python-based generator applications. It provides a means forthose apps to insert messages into the system for delivery to the router and,ultimately, one or more endpoints.

More information about how Mozilla Services is using Metlog (including what isbeing used for a router and what endpoints are in use / planning to be used)can be found on the relevant spec page.

Tags:

PRAGMA foreign_keys = off; BEGIN TRANSACTION; COMMIT TRANSACTION; PRAGMA foreign_keys = on;

Subscribe to our newsletter