masterpiece-influx


Namemasterpiece-influx JSON
Version 0.1.4 PyPI version JSON
download
home_pageNone
SummaryInflux v3 timeseries plugin for `masterpiece` applications
upload_time2025-01-19 11:05:14
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseMIT License =========== Copyright (c) 2024, Juha Meskanen Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
keywords influx masterpiece database timeseries
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            InfluxDB V3 Plugin for MasterPiece
==================================

This project adds InfluxDB V3 timeseries recording functionality to `MasterPiece` framework.


Usage
-----

Pre-requisities:

- Create Influx cloud account, or install local Influx instance. Please consult the Influx site for
  more information on this.


To install the 'masterpiece_influx' plugin:

.. code-block:: bash

  pip install masterpiece_influx

Once installed, you can create `~/.yourapp/config/Influx.json` configuration file to specify
information needed for reading and writing time series data to your Influx database. 

.. code-block:: text

  {
    "token": "your token",
    "org": "your organization",
    "host": "https://eu-central-1-1.aws.cloud2.influxdata.com",
    "database": "your database"
  }


To import and instantiate Influx database for use:

.. code-block:: python

  from masterpiece_influx import Influx

  db = Influx()


An example to write and read data:

.. code-block:: python


  db.write_dict(name="temperature", tags={"sensor": "A1"}, fields={"value": 23.4}, ts="2024-12-14T12:00:00Z")
  data = db.read_dict(measurement="temperature", start_time="2024-12-01T00:00:00Z")


Note
----

The `masterpiece_influx.Influx` class is an implementation of the abstract `masterpiece.TimeSeries` 
base class,  designed for reading and writing time series data.
The TimeSeries interface allows  all time series operations  in your application to remain 
implementation-independent. 



License
-------

This project is licensed under the MIT License - see the `LICENSE` file for details.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "masterpiece-influx",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "\"J. Meskanen\" <juham.api@gmail.com>",
    "keywords": "influx, masterpiece, database, timeseries",
    "author": null,
    "author_email": "J Meskanen <juham.api@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/ac/53/2e67082b81ce0f6854c3f7b68791fb51686c180d0249bfdf8a9e4a3cd25f/masterpiece_influx-0.1.4.tar.gz",
    "platform": null,
    "description": "InfluxDB V3 Plugin for MasterPiece\n==================================\n\nThis project adds InfluxDB V3 timeseries recording functionality to `MasterPiece` framework.\n\n\nUsage\n-----\n\nPre-requisities:\n\n- Create Influx cloud account, or install local Influx instance. Please consult the Influx site for\n  more information on this.\n\n\nTo install the 'masterpiece_influx' plugin:\n\n.. code-block:: bash\n\n  pip install masterpiece_influx\n\nOnce installed, you can create `~/.yourapp/config/Influx.json` configuration file to specify\ninformation needed for reading and writing time series data to your Influx database. \n\n.. code-block:: text\n\n  {\n    \"token\": \"your token\",\n    \"org\": \"your organization\",\n    \"host\": \"https://eu-central-1-1.aws.cloud2.influxdata.com\",\n    \"database\": \"your database\"\n  }\n\n\nTo import and instantiate Influx database for use:\n\n.. code-block:: python\n\n  from masterpiece_influx import Influx\n\n  db = Influx()\n\n\nAn example to write and read data:\n\n.. code-block:: python\n\n\n  db.write_dict(name=\"temperature\", tags={\"sensor\": \"A1\"}, fields={\"value\": 23.4}, ts=\"2024-12-14T12:00:00Z\")\n  data = db.read_dict(measurement=\"temperature\", start_time=\"2024-12-01T00:00:00Z\")\n\n\nNote\n----\n\nThe `masterpiece_influx.Influx` class is an implementation of the abstract `masterpiece.TimeSeries` \nbase class,  designed for reading and writing time series data.\nThe TimeSeries interface allows  all time series operations  in your application to remain \nimplementation-independent. \n\n\n\nLicense\n-------\n\nThis project is licensed under the MIT License - see the `LICENSE` file for details.\n",
    "bugtrack_url": null,
    "license": "MIT License ===========  Copyright (c) 2024, Juha Meskanen  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE  ",
    "summary": "Influx v3 timeseries plugin for `masterpiece` applications",
    "version": "0.1.4",
    "project_urls": {
        "Bug Reports": "https://gitlab.com/juham/masterpiece",
        "Homepage": "https://gitlab.com/juham/masterpiece_influx",
        "Say Thanks!": "http://meskanen.com",
        "Source": "https://gitlab.com/juham/masterpiece_influx"
    },
    "split_keywords": [
        "influx",
        " masterpiece",
        " database",
        " timeseries"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "bfe996748cc72379950053865169f74f9e3695f8c212ffd7ff6e5f4c4a1d0510",
                "md5": "fd045dc00453ed2c2efe1d76f8b88ef8",
                "sha256": "203429b17dfd73b1ec10272975a0ac86bdcf627ec496eca9a22b4ae2994a8a53"
            },
            "downloads": -1,
            "filename": "masterpiece_influx-0.1.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "fd045dc00453ed2c2efe1d76f8b88ef8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 7683,
            "upload_time": "2025-01-19T11:05:12",
            "upload_time_iso_8601": "2025-01-19T11:05:12.420054Z",
            "url": "https://files.pythonhosted.org/packages/bf/e9/96748cc72379950053865169f74f9e3695f8c212ffd7ff6e5f4c4a1d0510/masterpiece_influx-0.1.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ac532e67082b81ce0f6854c3f7b68791fb51686c180d0249bfdf8a9e4a3cd25f",
                "md5": "eecf5137cbd956f10679e71f297e6060",
                "sha256": "c300384b094a44f44b8020b00c7264d345f995cdfd5042279d69f4b385e84ee9"
            },
            "downloads": -1,
            "filename": "masterpiece_influx-0.1.4.tar.gz",
            "has_sig": false,
            "md5_digest": "eecf5137cbd956f10679e71f297e6060",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 7731,
            "upload_time": "2025-01-19T11:05:14",
            "upload_time_iso_8601": "2025-01-19T11:05:14.061885Z",
            "url": "https://files.pythonhosted.org/packages/ac/53/2e67082b81ce0f6854c3f7b68791fb51686c180d0249bfdf8a9e4a3cd25f/masterpiece_influx-0.1.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-01-19 11:05:14",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "juham",
    "gitlab_project": "masterpiece",
    "lcname": "masterpiece-influx"
}
        
Elapsed time: 0.40278s