feat: use custom domain name for telemetry (#25782)
closes: https://github.com/influxdata/influxdb3_hub/issues/5pull/25779/merge
parent
0da0785960
commit
15de3863f3
|
@ -60,8 +60,7 @@ pub const DEFAULT_DATA_DIRECTORY_NAME: &str = ".influxdb3";
|
|||
/// The default bind address for the HTTP API.
|
||||
pub const DEFAULT_HTTP_BIND_ADDR: &str = "0.0.0.0:8181";
|
||||
|
||||
pub const DEFAULT_TELMETRY_ENDPOINT: &str =
|
||||
"https://brs5g5kad1.execute-api.us-east-1.amazonaws.com/v1/";
|
||||
pub const DEFAULT_TELMETRY_ENDPOINT: &str = "https://telemetry.v3.influxdata.com";
|
||||
|
||||
#[derive(Debug, Error)]
|
||||
pub enum Error {
|
||||
|
|
|
@ -20,7 +20,7 @@ impl TelemetrySender {
|
|||
Self {
|
||||
client,
|
||||
full_url: base_url
|
||||
.join("./telemetry")
|
||||
.join("./telem")
|
||||
.expect("Cannot set the telemetry request path"),
|
||||
}
|
||||
}
|
||||
|
@ -124,7 +124,7 @@ mod tests {
|
|||
let client = reqwest::Client::new();
|
||||
let mut mock_server = Server::new_async().await;
|
||||
let mut sender = TelemetrySender::new(client, mock_server.url());
|
||||
let mock = mock_server.mock("POST", "/telemetry").create_async().await;
|
||||
let mock = mock_server.mock("POST", "/telem").create_async().await;
|
||||
let telem_payload = create_sample_payload();
|
||||
|
||||
let result = sender.try_sending(&telem_payload).await;
|
||||
|
|
Loading…
Reference in New Issue