I’m writing a Python script to collect lots of data from the Oracle database and load into InfluxDB in a remote server to build dashboards in Grafana.
My code works sweetly if, for each metric collected metric, the script loads it to InfluxDB. However, using this approach, for i.e. 10 metrics collected there will be 10 database calls.
I would like to avoid this approach and load all 10 metrics using a single database call, such as “influx -import”, but using Python and loading into a remote DB.
The code I’m using is:
v_payload = [
I already tried to store all the metrics into a list and then client.write_points the list and some other tries.
Does anyone have an example of how to achieve what I’m trying to?