Skip to main content

A package that can be used to convert csv file to influxdb line protocol format.

Project description

Influxify: Convert CSV to InfluxDB Line Protocol

PyPI Python Versions License

Influxify is a Python package that simplifies the process of converting time-series data from a CSV file into the InfluxDB Line Protocol format. With Influxify, you can seamlessly import your existing data into InfluxDB for efficient storage and analysis.

Features

  • Easily convert CSV data to InfluxDB Line Protocol format.
  • Supports custom field and tag mappings for flexible data transformation.
  • Can write data into a .lp (Line Protocol) file for convenient import into InfluxDB by simply dragging the file into a bucket.
  • Compatible with Python 3.6+.
  • Open-source and available under the MIT License.

Installation

You can install Influxify via pip:

pip install influxify

Usage

Influxify simplifies the process of converting time-series data from a CSV file into InfluxDB Line Protocol format. Follow these steps to get started:

  1. Import the InfluxConverter class in your Python script:
from influxify import InfluxConverter
  1. Initialize the converter:
converter = InfluxConverter('csv_file_name.csv', 'measurement', ['tag_columns'], ['field_columns'], 'timestamp_column', 'timestamp_format')
  1. Convert the CSV data to InfluxDB Line Protocol format:
line_protocols = converter.convert_csv_to_lineprotocol()
  1. Optionally, write the converted data into a (.line or .lp or .txt) file for easy import into InfluxDB by dragging the file into a bucket:
lp_file_path = "path/to/save/data.lp"
converter.write_to_lp_file(lp_file_path, line_protocols)
  1. Now, you can use the generated line_protocols to insert data into InfluxDB or use the line protocol file for quick and convenient import.

Contributing

We welcome contributions from the community! If you'd like to contribute to Influxify.

License

Influxify is distributed under the MIT License. See LICENSE for more information.

Support

If you have any questions, issues, or feature requests, please open an issue on our GitHub repository.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

influxify-0.0.3.tar.gz (4.6 kB view hashes)

Uploaded Source

Built Distribution

influxify-0.0.3-py3-none-any.whl (4.3 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page