{ "info": { "author": "Ben Hoyt", "author_email": "benhoyt@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5" ], "description": "graphyte\n========\n\n.. image:: https://img.shields.io/pypi/v/graphyte.svg\n :target: https://pypi.python.org/pypi/graphyte\n :alt: graphyte on PyPI (Python Package Index)\n\n.. image:: https://travis-ci.org/Jetsetter/graphyte.svg?branch=master\n :target: https://travis-ci.org/Jetsetter/graphyte\n :alt: Travis CI tests (Linux)\n\n.. image:: https://ci.appveyor.com/api/projects/status/github/Jetsetter/graphyte?branch=master&svg=true\n :target: https://ci.appveyor.com/project/benhoyt/graphyte\n :alt: Appveyor tests (Windows)\n\n\ngraphyte is a small Python library that sends data to a Graphite metrics\nserver (Carbon). We wrote it because the existing `graphitesend`_ library\ndidn\u2019t support Python 3, and it also required gevent for asyncronous use.\ngraphyte is compatible with Python 3.4+ as well as Python 2.7, and uses the\nstandard library\u2019s ``threading`` module for asynchronous use.\n\nThe library is `on the Python Package Index (PyPI)`_, so to install it, fire up\na command prompt, activate your virtualenv if you\u2019re using one, and type:\n\n::\n\n pip install graphyte\n\nUsing graphyte is simple \u2013 just call ``init()`` to initialize the default\nsender and then ``send()`` to send a message. For example, to send\n``system.sync.foo.bar 42 {timestamp}\\n`` to graphite.example.com:2003\nsynchronously:\n\n.. code:: python\n\n import graphyte\n graphyte.init('graphite.example.com', prefix='system.sync')\n graphyte.send('foo.bar', 42)\n\nIf you want to send asynchronously on a background thread (for example, in a\nweb server context), just specify a send interval. For example, this will\nsetup a background thread to send every 10 seconds:\n\n.. code:: python\n\n graphyte.init('graphite.example.com', prefix='system.async', interval=10)\n graphyte.send('foo.bar', 42)\n\nIf you want to send tagged metrics, the usage is as follows:\n\n.. code:: python\n\n graphite.send('foo.bar', 42, tags={'ding': 'dong'})\n\nFor more advanced usage, for example if you want to send to multiple servers\nor if you want to subclass ``Sender``, you can instantiate instances of\n``Sender`` directly. For example, to instantiate two senders sending to\ndifferent servers (one synchronous, one using a background thread with send\ninterval 10 seconds), use something like the following:\n\n.. code:: python\n\n sender1 = graphyte.Sender('graphite1.example.com', prefix='system.one')\n sender2 = graphyte.Sender('graphite2.example.com', prefix='system.two', interval=10)\n sender1.send('foo.bar1', 42)\n sender2.send('foo.bar2', 43)\n\nIf you want to send via UDP instead of TCP, just add ``protocol='udp'`` to\nthe ``init()`` or ``Sender()`` call.\n\nOr, to customize how messages are logged or sent to the socket, subclass\n``Sender`` and override ``send_message`` (or even ``send_socket`` if you\nwant to override logging and exception handling):\n\n.. code:: python\n\n class CustomSender(graphyte.Sender):\n def send_message(self, message):\n print('Sending bytes in some custom way: {!r}'.format(message))\n\nSocket sending errors are logged using the Python logging system (using\nlogger name \u201cgraphyte\u201d). If the sender is initialized with\n``log_sends=True``, all sends are logged at the INFO level.\n\nYou can also use graphyte to send metrics directly from the command line:\n\n::\n\n python -m graphyte foo.bar 42\n\nThere are command line arguments to specify the server and port and other\nconfiguration. Type ``python -m graphyte --help`` for help.\n\nRead the code in `graphyte.py`_ for more details \u2013 it\u2019s pretty small!\n\ngraphyte was written by `Ben Hoyt`_ for `Jetsetter`_ and is licensed with a\npermissive MIT license (see `LICENSE.txt`_).\n\n\n.. _graphitesend: https://github.com/daniellawrence/graphitesend\n.. _on the Python Package Index (PyPI): https://pypi.python.org/pypi/graphyte\n.. _graphyte.py: https://github.com/Jetsetter/graphyte/blob/master/graphyte.py\n.. _Ben Hoyt: http://benhoyt.com/\n.. _Jetsetter: http://www.jetsetter.com/\n.. _LICENSE.txt: https://github.com/Jetsetter/graphyte/blob/master/LICENSE.txt", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/Jetsetter/graphyte", "keywords": "", "license": "MIT License", "maintainer": "", "maintainer_email": "", "name": "graphyte", "package_url": "https://pypi.org/project/graphyte/", "platform": "", "project_url": "https://pypi.org/project/graphyte/", "project_urls": { "Homepage": "https://github.com/Jetsetter/graphyte" }, "release_url": "https://pypi.org/project/graphyte/1.6.0/", "requires_dist": null, "requires_python": "", "summary": "Python 3 compatible library to send data to a Graphite metrics server (Carbon)", "version": "1.6.0" }, "last_serial": 5417872, "releases": { "1.0": [ { "comment_text": "", "digests": { "md5": "ad4176169d83fd0cc647a0a2b196a38a", "sha256": "f12d750063c696a32dfd5887de62d68c3970fed2a139e14f15e88019ce2de186" }, "downloads": -1, "filename": "graphyte-1.0.tar.gz", "has_sig": false, "md5_digest": "ad4176169d83fd0cc647a0a2b196a38a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5787, "upload_time": "2016-07-22T18:40:26", "url": "https://files.pythonhosted.org/packages/90/f9/0ee412a6a6010564c72b15b4769fa1173428eea68db1b545a24f5345fc82/graphyte-1.0.tar.gz" }, { "comment_text": "", "digests": { "md5": "7a963e014c8967551ce5fb348fd76486", "sha256": "2f316850a1187f650a69db91e80df557af0c8df35f0511d346df8a793f8ed8b5" }, "downloads": -1, "filename": "graphyte-1.0.zip", "has_sig": false, "md5_digest": "7a963e014c8967551ce5fb348fd76486", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6943, "upload_time": "2016-07-22T18:40:28", "url": "https://files.pythonhosted.org/packages/05/29/a75a53bc1d42262c39d9006de0d18a4b6a67693ae244c03e8be218f9b2cf/graphyte-1.0.zip" } ], "1.1": [ { "comment_text": "", "digests": { "md5": "ea1fbdaa14a27a0ecaee117349aefe57", "sha256": "5016febd3ebdf84490c559ecf28058e3065a26474131b629137b958fe561d75c" }, "downloads": -1, "filename": "graphyte-1.1.tar.gz", "has_sig": false, "md5_digest": "ea1fbdaa14a27a0ecaee117349aefe57", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6211, "upload_time": "2016-10-10T20:08:28", "url": "https://files.pythonhosted.org/packages/24/49/5d918961217346ebcddbf0702afc9f229dfe65c0e08143fb9939279fa14a/graphyte-1.1.tar.gz" }, { "comment_text": "", "digests": { "md5": "838b762d7bc0053b7183e7d5500db6b4", "sha256": "599b33adb02db762210c808f571200aa07a745731816c2c6c0a3aa75370cef06" }, "downloads": -1, "filename": "graphyte-1.1.zip", "has_sig": false, "md5_digest": "838b762d7bc0053b7183e7d5500db6b4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7406, "upload_time": "2016-10-10T20:08:30", "url": "https://files.pythonhosted.org/packages/b7/e0/3c319dd2a998addc5730f93194fdbc1f571634c87a3adddd6ce79dea2a43/graphyte-1.1.zip" } ], "1.2": [ { "comment_text": "", "digests": { "md5": "f21a95a0e853f167fd406d3801ca4bf6", "sha256": "623c81d0b89fa1bfe4b28eab62388d88d3bcb76c18411aab6ce8bd23e9e69a63" }, "downloads": -1, "filename": "graphyte-1.2.tar.gz", "has_sig": false, "md5_digest": "f21a95a0e853f167fd406d3801ca4bf6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6545, "upload_time": "2017-01-31T14:14:50", "url": "https://files.pythonhosted.org/packages/ce/cd/13a526b7a08dd8354bffd27804eb7c14caef9a6394847cdd7a8374e5c553/graphyte-1.2.tar.gz" } ], "1.3": [ { "comment_text": "", "digests": { "md5": "6348ef9a8296e9a76a6f3ae8691e4c5e", "sha256": "73c727b0bb32d033ac27d44567a868acb6a8d5a7088579f3e428f9bb4a645f3f" }, "downloads": -1, "filename": "graphyte-1.3.tar.gz", "has_sig": false, "md5_digest": "6348ef9a8296e9a76a6f3ae8691e4c5e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6622, "upload_time": "2017-08-22T13:33:22", "url": "https://files.pythonhosted.org/packages/73/8a/7e20580cde9cf7e8526fe93fc15a2b58c00d4178751781728bac96d313e6/graphyte-1.3.tar.gz" } ], "1.4": [ { "comment_text": "", "digests": { "md5": "3c16ef1810c09cb5db824853d4c785a6", "sha256": "56967589831e33de17f1a3f32a6dd8b7bc9eaa62fb90ceeec42fa1a7c8c8ad6a" }, "downloads": -1, "filename": "graphyte-1.4.tar.gz", "has_sig": false, "md5_digest": "3c16ef1810c09cb5db824853d4c785a6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6909, "upload_time": "2017-09-20T01:48:50", "url": "https://files.pythonhosted.org/packages/94/65/e7ee5e35cef9a1b72975399eeea440ff1b04e758d078840b5d2a9c85e1e4/graphyte-1.4.tar.gz" } ], "1.5": [ { "comment_text": "", "digests": { "md5": "b4551195f2f11dfc4cb9ef0d3af561df", "sha256": "7cfc76f0b9abf3806eb45058f6f7e95613fb362dc539c7a93b8d18d9864e48a8" }, "downloads": -1, "filename": "graphyte-1.5.tar.gz", "has_sig": false, "md5_digest": "b4551195f2f11dfc4cb9ef0d3af561df", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7224, "upload_time": "2018-09-24T12:36:10", "url": "https://files.pythonhosted.org/packages/ef/58/13eed40806c56022d683f378596a47328c4665faed981859c875652a1a3a/graphyte-1.5.tar.gz" } ], "1.6.0": [ { "comment_text": "", "digests": { "md5": "7c31b308afc84b611f9cc47acaf2faeb", "sha256": "ab1fd5a0061cd8f412d379273e36dfb4b80906c4c804052cfe3aa1ed416dc072" }, "downloads": -1, "filename": "graphyte-1.6.0.tar.gz", "has_sig": false, "md5_digest": "7c31b308afc84b611f9cc47acaf2faeb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7330, "upload_time": "2019-06-19T00:52:26", "url": "https://files.pythonhosted.org/packages/29/83/6c63b792f822aa439165596d288373911a13e5c9fe6c79043a8727448144/graphyte-1.6.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "7c31b308afc84b611f9cc47acaf2faeb", "sha256": "ab1fd5a0061cd8f412d379273e36dfb4b80906c4c804052cfe3aa1ed416dc072" }, "downloads": -1, "filename": "graphyte-1.6.0.tar.gz", "has_sig": false, "md5_digest": "7c31b308afc84b611f9cc47acaf2faeb", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7330, "upload_time": "2019-06-19T00:52:26", "url": "https://files.pythonhosted.org/packages/29/83/6c63b792f822aa439165596d288373911a13e5c9fe6c79043a8727448144/graphyte-1.6.0.tar.gz" } ] }