Crates.io | influxive-child-svc |
lib.rs | influxive-child-svc |
version | 0.0.3-alpha.1 |
source | src |
created_at | 2023-07-14 22:57:55.892012 |
updated_at | 2024-06-05 16:33:47.234314 |
description | Run influxd as a child process |
homepage | |
repository | https://github.com/holochain/influxive |
max_upload_size | |
id | 916833 |
size | 30,891 |
Run influxd as a child process.
use influxive_core::Metric;
use influxive_child_svc::*;
let tmp = tempfile::tempdir().unwrap();
let influxive = InfluxiveChildSvc::new(
InfluxiveChildSvcConfig::default()
.with_database_path(Some(tmp.path().to_owned())),
).await.unwrap();
influxive.write_metric(
Metric::new(
std::time::SystemTime::now(),
"my.metric",
)
.with_field("value", 3.14)
.with_tag("tag", "test-tag")
);