Add timestamp delta to telemetry events
This commit is contained in:
parent
30b7da0e4a
commit
3abd376d6a
12 changed files with 343 additions and 99 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
@ -1550,6 +1550,7 @@ dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"async-recursion 0.3.2",
|
"async-recursion 0.3.2",
|
||||||
"async-tungstenite",
|
"async-tungstenite",
|
||||||
|
"chrono",
|
||||||
"collections",
|
"collections",
|
||||||
"db",
|
"db",
|
||||||
"feature_flags",
|
"feature_flags",
|
||||||
|
@ -1586,6 +1587,7 @@ dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"async-recursion 0.3.2",
|
"async-recursion 0.3.2",
|
||||||
"async-tungstenite",
|
"async-tungstenite",
|
||||||
|
"chrono",
|
||||||
"collections",
|
"collections",
|
||||||
"db2",
|
"db2",
|
||||||
"feature_flags2",
|
"feature_flags2",
|
||||||
|
|
|
@ -15,7 +15,7 @@ use ai::{
|
||||||
use ai::prompts::repository_context::PromptCodeSnippet;
|
use ai::prompts::repository_context::PromptCodeSnippet;
|
||||||
use anyhow::{anyhow, Result};
|
use anyhow::{anyhow, Result};
|
||||||
use chrono::{DateTime, Local};
|
use chrono::{DateTime, Local};
|
||||||
use client::{telemetry::AssistantKind, ClickhouseEvent, TelemetrySettings};
|
use client::{telemetry::AssistantKind, TelemetrySettings};
|
||||||
use collections::{hash_map, HashMap, HashSet, VecDeque};
|
use collections::{hash_map, HashMap, HashSet, VecDeque};
|
||||||
use editor::{
|
use editor::{
|
||||||
display_map::{
|
display_map::{
|
||||||
|
@ -3803,12 +3803,12 @@ fn report_assistant_event(
|
||||||
.default_open_ai_model
|
.default_open_ai_model
|
||||||
.clone();
|
.clone();
|
||||||
|
|
||||||
let event = ClickhouseEvent::Assistant {
|
|
||||||
conversation_id,
|
|
||||||
kind: assistant_kind,
|
|
||||||
model: model.full_name(),
|
|
||||||
};
|
|
||||||
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
||||||
|
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings)
|
telemetry.report_assistant_event(
|
||||||
|
telemetry_settings,
|
||||||
|
conversation_id,
|
||||||
|
assistant_kind,
|
||||||
|
model.full_name(),
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,10 +5,7 @@ pub mod room;
|
||||||
use anyhow::{anyhow, Result};
|
use anyhow::{anyhow, Result};
|
||||||
use audio::Audio;
|
use audio::Audio;
|
||||||
use call_settings::CallSettings;
|
use call_settings::CallSettings;
|
||||||
use client::{
|
use client::{proto, Client, TelemetrySettings, TypedEnvelope, User, UserStore, ZED_ALWAYS_ACTIVE};
|
||||||
proto, ClickhouseEvent, Client, TelemetrySettings, TypedEnvelope, User, UserStore,
|
|
||||||
ZED_ALWAYS_ACTIVE,
|
|
||||||
};
|
|
||||||
use collections::HashSet;
|
use collections::HashSet;
|
||||||
use futures::{channel::oneshot, future::Shared, Future, FutureExt};
|
use futures::{channel::oneshot, future::Shared, Future, FutureExt};
|
||||||
use gpui::{
|
use gpui::{
|
||||||
|
@ -485,12 +482,8 @@ pub fn report_call_event_for_room(
|
||||||
) {
|
) {
|
||||||
let telemetry = client.telemetry();
|
let telemetry = client.telemetry();
|
||||||
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
||||||
let event = ClickhouseEvent::Call {
|
|
||||||
operation,
|
telemetry.report_call_event(telemetry_settings, operation, Some(room_id), channel_id)
|
||||||
room_id: Some(room_id),
|
|
||||||
channel_id,
|
|
||||||
};
|
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn report_call_event_for_channel(
|
pub fn report_call_event_for_channel(
|
||||||
|
@ -504,12 +497,12 @@ pub fn report_call_event_for_channel(
|
||||||
let telemetry = client.telemetry();
|
let telemetry = client.telemetry();
|
||||||
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
||||||
|
|
||||||
let event = ClickhouseEvent::Call {
|
telemetry.report_call_event(
|
||||||
|
telemetry_settings,
|
||||||
operation,
|
operation,
|
||||||
room_id: room.map(|r| r.read(cx).id()),
|
room.map(|r| r.read(cx).id()),
|
||||||
channel_id: Some(channel_id),
|
Some(channel_id),
|
||||||
};
|
)
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
|
|
|
@ -5,10 +5,7 @@ pub mod room;
|
||||||
use anyhow::{anyhow, Result};
|
use anyhow::{anyhow, Result};
|
||||||
use audio::Audio;
|
use audio::Audio;
|
||||||
use call_settings::CallSettings;
|
use call_settings::CallSettings;
|
||||||
use client::{
|
use client::{proto, Client, TelemetrySettings, TypedEnvelope, User, UserStore, ZED_ALWAYS_ACTIVE};
|
||||||
proto, ClickhouseEvent, Client, TelemetrySettings, TypedEnvelope, User, UserStore,
|
|
||||||
ZED_ALWAYS_ACTIVE,
|
|
||||||
};
|
|
||||||
use collections::HashSet;
|
use collections::HashSet;
|
||||||
use futures::{channel::oneshot, future::Shared, Future, FutureExt};
|
use futures::{channel::oneshot, future::Shared, Future, FutureExt};
|
||||||
use gpui::{
|
use gpui::{
|
||||||
|
@ -484,12 +481,8 @@ pub fn report_call_event_for_room(
|
||||||
) {
|
) {
|
||||||
let telemetry = client.telemetry();
|
let telemetry = client.telemetry();
|
||||||
let telemetry_settings = *TelemetrySettings::get_global(cx);
|
let telemetry_settings = *TelemetrySettings::get_global(cx);
|
||||||
let event = ClickhouseEvent::Call {
|
|
||||||
operation,
|
telemetry.report_call_event(telemetry_settings, operation, Some(room_id), channel_id)
|
||||||
room_id: Some(room_id),
|
|
||||||
channel_id,
|
|
||||||
};
|
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn report_call_event_for_channel(
|
pub fn report_call_event_for_channel(
|
||||||
|
@ -504,12 +497,12 @@ pub fn report_call_event_for_channel(
|
||||||
|
|
||||||
let telemetry_settings = *TelemetrySettings::get_global(cx);
|
let telemetry_settings = *TelemetrySettings::get_global(cx);
|
||||||
|
|
||||||
let event = ClickhouseEvent::Call {
|
telemetry.report_call_event(
|
||||||
|
telemetry_settings,
|
||||||
operation,
|
operation,
|
||||||
room_id: room.map(|r| r.read(cx).id()),
|
room.map(|r| r.read(cx).id()),
|
||||||
channel_id: Some(channel_id),
|
Some(channel_id),
|
||||||
};
|
)
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
|
|
|
@ -12,6 +12,7 @@ doctest = false
|
||||||
test-support = ["collections/test-support", "gpui/test-support", "rpc/test-support"]
|
test-support = ["collections/test-support", "gpui/test-support", "rpc/test-support"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
|
chrono = { version = "0.4", features = ["serde"] }
|
||||||
collections = { path = "../collections" }
|
collections = { path = "../collections" }
|
||||||
db = { path = "../db" }
|
db = { path = "../db" }
|
||||||
gpui = { path = "../gpui" }
|
gpui = { path = "../gpui" }
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
use crate::{TelemetrySettings, ZED_SECRET_CLIENT_TOKEN, ZED_SERVER_URL};
|
use crate::{TelemetrySettings, ZED_SECRET_CLIENT_TOKEN, ZED_SERVER_URL};
|
||||||
|
use chrono::{DateTime, Utc};
|
||||||
use gpui::{executor::Background, serde_json, AppContext, Task};
|
use gpui::{executor::Background, serde_json, AppContext, Task};
|
||||||
use lazy_static::lazy_static;
|
use lazy_static::lazy_static;
|
||||||
use parking_lot::Mutex;
|
use parking_lot::Mutex;
|
||||||
|
@ -31,6 +32,7 @@ struct TelemetryState {
|
||||||
flush_clickhouse_events_task: Option<Task<()>>,
|
flush_clickhouse_events_task: Option<Task<()>>,
|
||||||
log_file: Option<NamedTempFile>,
|
log_file: Option<NamedTempFile>,
|
||||||
is_staff: Option<bool>,
|
is_staff: Option<bool>,
|
||||||
|
first_event_datetime: Option<DateTime<Utc>>,
|
||||||
}
|
}
|
||||||
|
|
||||||
const CLICKHOUSE_EVENTS_URL_PATH: &'static str = "/api/events";
|
const CLICKHOUSE_EVENTS_URL_PATH: &'static str = "/api/events";
|
||||||
|
@ -77,42 +79,48 @@ pub enum ClickhouseEvent {
|
||||||
vim_mode: bool,
|
vim_mode: bool,
|
||||||
copilot_enabled: bool,
|
copilot_enabled: bool,
|
||||||
copilot_enabled_for_language: bool,
|
copilot_enabled_for_language: bool,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Copilot {
|
Copilot {
|
||||||
suggestion_id: Option<String>,
|
suggestion_id: Option<String>,
|
||||||
suggestion_accepted: bool,
|
suggestion_accepted: bool,
|
||||||
file_extension: Option<String>,
|
file_extension: Option<String>,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Call {
|
Call {
|
||||||
operation: &'static str,
|
operation: &'static str,
|
||||||
room_id: Option<u64>,
|
room_id: Option<u64>,
|
||||||
channel_id: Option<u64>,
|
channel_id: Option<u64>,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Assistant {
|
Assistant {
|
||||||
conversation_id: Option<String>,
|
conversation_id: Option<String>,
|
||||||
kind: AssistantKind,
|
kind: AssistantKind,
|
||||||
model: &'static str,
|
model: &'static str,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Cpu {
|
Cpu {
|
||||||
usage_as_percentage: f32,
|
usage_as_percentage: f32,
|
||||||
core_count: u32,
|
core_count: u32,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Memory {
|
Memory {
|
||||||
memory_in_bytes: u64,
|
memory_in_bytes: u64,
|
||||||
virtual_memory_in_bytes: u64,
|
virtual_memory_in_bytes: u64,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(debug_assertions)]
|
// #[cfg(debug_assertions)]
|
||||||
const MAX_QUEUE_LEN: usize = 1;
|
// const MAX_QUEUE_LEN: usize = 1;
|
||||||
|
|
||||||
#[cfg(not(debug_assertions))]
|
// #[cfg(not(debug_assertions))]
|
||||||
const MAX_QUEUE_LEN: usize = 10;
|
const MAX_QUEUE_LEN: usize = 10;
|
||||||
|
|
||||||
#[cfg(debug_assertions)]
|
// #[cfg(debug_assertions)]
|
||||||
const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(1);
|
// const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(1);
|
||||||
|
|
||||||
#[cfg(not(debug_assertions))]
|
// #[cfg(not(debug_assertions))]
|
||||||
const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(30);
|
const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(30);
|
||||||
|
|
||||||
impl Telemetry {
|
impl Telemetry {
|
||||||
|
@ -140,6 +148,7 @@ impl Telemetry {
|
||||||
flush_clickhouse_events_task: Default::default(),
|
flush_clickhouse_events_task: Default::default(),
|
||||||
log_file: None,
|
log_file: None,
|
||||||
is_staff: None,
|
is_staff: None,
|
||||||
|
first_event_datetime: None,
|
||||||
}),
|
}),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -195,20 +204,18 @@ impl Telemetry {
|
||||||
return;
|
return;
|
||||||
};
|
};
|
||||||
|
|
||||||
let memory_event = ClickhouseEvent::Memory {
|
|
||||||
memory_in_bytes: process.memory(),
|
|
||||||
virtual_memory_in_bytes: process.virtual_memory(),
|
|
||||||
};
|
|
||||||
|
|
||||||
let cpu_event = ClickhouseEvent::Cpu {
|
|
||||||
usage_as_percentage: process.cpu_usage(),
|
|
||||||
core_count: system.cpus().len() as u32,
|
|
||||||
};
|
|
||||||
|
|
||||||
let telemetry_settings = cx.update(|cx| *settings::get::<TelemetrySettings>(cx));
|
let telemetry_settings = cx.update(|cx| *settings::get::<TelemetrySettings>(cx));
|
||||||
|
|
||||||
this.report_clickhouse_event(memory_event, telemetry_settings);
|
this.report_memory_event(
|
||||||
this.report_clickhouse_event(cpu_event, telemetry_settings);
|
telemetry_settings,
|
||||||
|
process.memory(),
|
||||||
|
process.virtual_memory(),
|
||||||
|
);
|
||||||
|
this.report_cpu_event(
|
||||||
|
telemetry_settings,
|
||||||
|
process.cpu_usage(),
|
||||||
|
system.cpus().len() as u32,
|
||||||
|
);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.detach();
|
.detach();
|
||||||
|
@ -231,7 +238,123 @@ impl Telemetry {
|
||||||
drop(state);
|
drop(state);
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn report_clickhouse_event(
|
pub fn report_editor_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
file_extension: Option<String>,
|
||||||
|
vim_mode: bool,
|
||||||
|
operation: &'static str,
|
||||||
|
copilot_enabled: bool,
|
||||||
|
copilot_enabled_for_language: bool,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Editor {
|
||||||
|
file_extension,
|
||||||
|
vim_mode,
|
||||||
|
operation,
|
||||||
|
copilot_enabled,
|
||||||
|
copilot_enabled_for_language,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_copilot_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
suggestion_id: Option<String>,
|
||||||
|
suggestion_accepted: bool,
|
||||||
|
file_extension: Option<String>,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Copilot {
|
||||||
|
suggestion_id,
|
||||||
|
suggestion_accepted,
|
||||||
|
file_extension,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_assistant_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
conversation_id: Option<String>,
|
||||||
|
kind: AssistantKind,
|
||||||
|
model: &'static str,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Assistant {
|
||||||
|
conversation_id,
|
||||||
|
kind,
|
||||||
|
model,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_call_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
operation: &'static str,
|
||||||
|
room_id: Option<u64>,
|
||||||
|
channel_id: Option<u64>,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Call {
|
||||||
|
operation,
|
||||||
|
room_id,
|
||||||
|
channel_id,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_cpu_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
usage_as_percentage: f32,
|
||||||
|
core_count: u32,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Cpu {
|
||||||
|
usage_as_percentage,
|
||||||
|
core_count,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_memory_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
memory_in_bytes: u64,
|
||||||
|
virtual_memory_in_bytes: u64,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Memory {
|
||||||
|
memory_in_bytes,
|
||||||
|
virtual_memory_in_bytes,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
fn milliseconds_since_first_event(&self) -> i64 {
|
||||||
|
let mut state = self.state.lock();
|
||||||
|
match state.first_event_datetime {
|
||||||
|
Some(first_event_datetime) => {
|
||||||
|
let now: DateTime<Utc> = Utc::now();
|
||||||
|
now.timestamp_millis() - first_event_datetime.timestamp_millis()
|
||||||
|
}
|
||||||
|
None => {
|
||||||
|
state.first_event_datetime = Some(Utc::now());
|
||||||
|
0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn report_clickhouse_event(
|
||||||
self: &Arc<Self>,
|
self: &Arc<Self>,
|
||||||
event: ClickhouseEvent,
|
event: ClickhouseEvent,
|
||||||
telemetry_settings: TelemetrySettings,
|
telemetry_settings: TelemetrySettings,
|
||||||
|
@ -246,6 +369,8 @@ impl Telemetry {
|
||||||
.clickhouse_events_queue
|
.clickhouse_events_queue
|
||||||
.push(ClickhouseEventWrapper { signed_in, event });
|
.push(ClickhouseEventWrapper { signed_in, event });
|
||||||
|
|
||||||
|
dbg!(state.clickhouse_events_queue.len(), chrono::Utc::now());
|
||||||
|
|
||||||
if state.installation_id.is_some() {
|
if state.installation_id.is_some() {
|
||||||
if state.clickhouse_events_queue.len() >= MAX_QUEUE_LEN {
|
if state.clickhouse_events_queue.len() >= MAX_QUEUE_LEN {
|
||||||
drop(state);
|
drop(state);
|
||||||
|
@ -275,6 +400,7 @@ impl Telemetry {
|
||||||
|
|
||||||
fn flush_clickhouse_events(self: &Arc<Self>) {
|
fn flush_clickhouse_events(self: &Arc<Self>) {
|
||||||
let mut state = self.state.lock();
|
let mut state = self.state.lock();
|
||||||
|
state.first_event_datetime = None;
|
||||||
let mut events = mem::take(&mut state.clickhouse_events_queue);
|
let mut events = mem::take(&mut state.clickhouse_events_queue);
|
||||||
state.flush_clickhouse_events_task.take();
|
state.flush_clickhouse_events_task.take();
|
||||||
drop(state);
|
drop(state);
|
||||||
|
@ -310,6 +436,7 @@ impl Telemetry {
|
||||||
release_channel: state.release_channel,
|
release_channel: state.release_channel,
|
||||||
events,
|
events,
|
||||||
};
|
};
|
||||||
|
dbg!(&request_body);
|
||||||
json_bytes.clear();
|
json_bytes.clear();
|
||||||
serde_json::to_writer(&mut json_bytes, &request_body)?;
|
serde_json::to_writer(&mut json_bytes, &request_body)?;
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,6 +12,7 @@ doctest = false
|
||||||
test-support = ["collections/test-support", "gpui/test-support", "rpc/test-support"]
|
test-support = ["collections/test-support", "gpui/test-support", "rpc/test-support"]
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
|
chrono = { version = "0.4", features = ["serde"] }
|
||||||
collections = { path = "../collections" }
|
collections = { path = "../collections" }
|
||||||
db = { package = "db2", path = "../db2" }
|
db = { package = "db2", path = "../db2" }
|
||||||
gpui = { package = "gpui2", path = "../gpui2" }
|
gpui = { package = "gpui2", path = "../gpui2" }
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
use crate::{TelemetrySettings, ZED_SECRET_CLIENT_TOKEN, ZED_SERVER_URL};
|
use crate::{TelemetrySettings, ZED_SECRET_CLIENT_TOKEN, ZED_SERVER_URL};
|
||||||
|
use chrono::{DateTime, Utc};
|
||||||
use gpui::{serde_json, AppContext, AppMetadata, BackgroundExecutor, Task};
|
use gpui::{serde_json, AppContext, AppMetadata, BackgroundExecutor, Task};
|
||||||
use lazy_static::lazy_static;
|
use lazy_static::lazy_static;
|
||||||
use parking_lot::Mutex;
|
use parking_lot::Mutex;
|
||||||
|
@ -29,6 +30,7 @@ struct TelemetryState {
|
||||||
flush_clickhouse_events_task: Option<Task<()>>,
|
flush_clickhouse_events_task: Option<Task<()>>,
|
||||||
log_file: Option<NamedTempFile>,
|
log_file: Option<NamedTempFile>,
|
||||||
is_staff: Option<bool>,
|
is_staff: Option<bool>,
|
||||||
|
first_event_datetime: Option<DateTime<Utc>>,
|
||||||
}
|
}
|
||||||
|
|
||||||
const CLICKHOUSE_EVENTS_URL_PATH: &'static str = "/api/events";
|
const CLICKHOUSE_EVENTS_URL_PATH: &'static str = "/api/events";
|
||||||
|
@ -75,42 +77,48 @@ pub enum ClickhouseEvent {
|
||||||
vim_mode: bool,
|
vim_mode: bool,
|
||||||
copilot_enabled: bool,
|
copilot_enabled: bool,
|
||||||
copilot_enabled_for_language: bool,
|
copilot_enabled_for_language: bool,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Copilot {
|
Copilot {
|
||||||
suggestion_id: Option<String>,
|
suggestion_id: Option<String>,
|
||||||
suggestion_accepted: bool,
|
suggestion_accepted: bool,
|
||||||
file_extension: Option<String>,
|
file_extension: Option<String>,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Call {
|
Call {
|
||||||
operation: &'static str,
|
operation: &'static str,
|
||||||
room_id: Option<u64>,
|
room_id: Option<u64>,
|
||||||
channel_id: Option<u64>,
|
channel_id: Option<u64>,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Assistant {
|
Assistant {
|
||||||
conversation_id: Option<String>,
|
conversation_id: Option<String>,
|
||||||
kind: AssistantKind,
|
kind: AssistantKind,
|
||||||
model: &'static str,
|
model: &'static str,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Cpu {
|
Cpu {
|
||||||
usage_as_percentage: f32,
|
usage_as_percentage: f32,
|
||||||
core_count: u32,
|
core_count: u32,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
Memory {
|
Memory {
|
||||||
memory_in_bytes: u64,
|
memory_in_bytes: u64,
|
||||||
virtual_memory_in_bytes: u64,
|
virtual_memory_in_bytes: u64,
|
||||||
|
milliseconds_since_first_event: i64,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(debug_assertions)]
|
// #[cfg(debug_assertions)]
|
||||||
const MAX_QUEUE_LEN: usize = 1;
|
// const MAX_QUEUE_LEN: usize = 1;
|
||||||
|
|
||||||
#[cfg(not(debug_assertions))]
|
// #[cfg(not(debug_assertions))]
|
||||||
const MAX_QUEUE_LEN: usize = 10;
|
const MAX_QUEUE_LEN: usize = 10;
|
||||||
|
|
||||||
#[cfg(debug_assertions)]
|
// #[cfg(debug_assertions)]
|
||||||
const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(1);
|
// const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(1);
|
||||||
|
|
||||||
#[cfg(not(debug_assertions))]
|
// #[cfg(not(debug_assertions))]
|
||||||
const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(30);
|
const DEBOUNCE_INTERVAL: Duration = Duration::from_secs(30);
|
||||||
|
|
||||||
impl Telemetry {
|
impl Telemetry {
|
||||||
|
@ -135,6 +143,7 @@ impl Telemetry {
|
||||||
flush_clickhouse_events_task: Default::default(),
|
flush_clickhouse_events_task: Default::default(),
|
||||||
log_file: None,
|
log_file: None,
|
||||||
is_staff: None,
|
is_staff: None,
|
||||||
|
first_event_datetime: None,
|
||||||
}),
|
}),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -190,16 +199,6 @@ impl Telemetry {
|
||||||
return;
|
return;
|
||||||
};
|
};
|
||||||
|
|
||||||
let memory_event = ClickhouseEvent::Memory {
|
|
||||||
memory_in_bytes: process.memory(),
|
|
||||||
virtual_memory_in_bytes: process.virtual_memory(),
|
|
||||||
};
|
|
||||||
|
|
||||||
let cpu_event = ClickhouseEvent::Cpu {
|
|
||||||
usage_as_percentage: process.cpu_usage(),
|
|
||||||
core_count: system.cpus().len() as u32,
|
|
||||||
};
|
|
||||||
|
|
||||||
let telemetry_settings = if let Ok(telemetry_settings) =
|
let telemetry_settings = if let Ok(telemetry_settings) =
|
||||||
cx.update(|cx| *TelemetrySettings::get_global(cx))
|
cx.update(|cx| *TelemetrySettings::get_global(cx))
|
||||||
{
|
{
|
||||||
|
@ -208,8 +207,16 @@ impl Telemetry {
|
||||||
break;
|
break;
|
||||||
};
|
};
|
||||||
|
|
||||||
this.report_clickhouse_event(memory_event, telemetry_settings);
|
this.report_memory_event(
|
||||||
this.report_clickhouse_event(cpu_event, telemetry_settings);
|
telemetry_settings,
|
||||||
|
process.memory(),
|
||||||
|
process.virtual_memory(),
|
||||||
|
);
|
||||||
|
this.report_cpu_event(
|
||||||
|
telemetry_settings,
|
||||||
|
process.cpu_usage(),
|
||||||
|
system.cpus().len() as u32,
|
||||||
|
);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.detach();
|
.detach();
|
||||||
|
@ -232,7 +239,123 @@ impl Telemetry {
|
||||||
drop(state);
|
drop(state);
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn report_clickhouse_event(
|
pub fn report_editor_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
file_extension: Option<String>,
|
||||||
|
vim_mode: bool,
|
||||||
|
operation: &'static str,
|
||||||
|
copilot_enabled: bool,
|
||||||
|
copilot_enabled_for_language: bool,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Editor {
|
||||||
|
file_extension,
|
||||||
|
vim_mode,
|
||||||
|
operation,
|
||||||
|
copilot_enabled,
|
||||||
|
copilot_enabled_for_language,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_copilot_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
suggestion_id: Option<String>,
|
||||||
|
suggestion_accepted: bool,
|
||||||
|
file_extension: Option<String>,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Copilot {
|
||||||
|
suggestion_id,
|
||||||
|
suggestion_accepted,
|
||||||
|
file_extension,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_assistant_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
conversation_id: Option<String>,
|
||||||
|
kind: AssistantKind,
|
||||||
|
model: &'static str,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Assistant {
|
||||||
|
conversation_id,
|
||||||
|
kind,
|
||||||
|
model,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_call_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
operation: &'static str,
|
||||||
|
room_id: Option<u64>,
|
||||||
|
channel_id: Option<u64>,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Call {
|
||||||
|
operation,
|
||||||
|
room_id,
|
||||||
|
channel_id,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_cpu_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
usage_as_percentage: f32,
|
||||||
|
core_count: u32,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Cpu {
|
||||||
|
usage_as_percentage,
|
||||||
|
core_count,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn report_memory_event(
|
||||||
|
self: &Arc<Self>,
|
||||||
|
telemetry_settings: TelemetrySettings,
|
||||||
|
memory_in_bytes: u64,
|
||||||
|
virtual_memory_in_bytes: u64,
|
||||||
|
) {
|
||||||
|
let event = ClickhouseEvent::Memory {
|
||||||
|
memory_in_bytes,
|
||||||
|
virtual_memory_in_bytes,
|
||||||
|
milliseconds_since_first_event: self.milliseconds_since_first_event(),
|
||||||
|
};
|
||||||
|
|
||||||
|
self.report_clickhouse_event(event, telemetry_settings)
|
||||||
|
}
|
||||||
|
|
||||||
|
fn milliseconds_since_first_event(&self) -> i64 {
|
||||||
|
let mut state = self.state.lock();
|
||||||
|
match state.first_event_datetime {
|
||||||
|
Some(first_event_datetime) => {
|
||||||
|
let now: DateTime<Utc> = Utc::now();
|
||||||
|
now.timestamp_millis() - first_event_datetime.timestamp_millis()
|
||||||
|
}
|
||||||
|
None => {
|
||||||
|
state.first_event_datetime = Some(Utc::now());
|
||||||
|
0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn report_clickhouse_event(
|
||||||
self: &Arc<Self>,
|
self: &Arc<Self>,
|
||||||
event: ClickhouseEvent,
|
event: ClickhouseEvent,
|
||||||
telemetry_settings: TelemetrySettings,
|
telemetry_settings: TelemetrySettings,
|
||||||
|
@ -247,6 +370,9 @@ impl Telemetry {
|
||||||
.clickhouse_events_queue
|
.clickhouse_events_queue
|
||||||
.push(ClickhouseEventWrapper { signed_in, event });
|
.push(ClickhouseEventWrapper { signed_in, event });
|
||||||
|
|
||||||
|
dbg!(state.clickhouse_events_queue.len(), chrono::Utc::now());
|
||||||
|
dbg!(state.installation_id.is_some());
|
||||||
|
|
||||||
if state.installation_id.is_some() {
|
if state.installation_id.is_some() {
|
||||||
if state.clickhouse_events_queue.len() >= MAX_QUEUE_LEN {
|
if state.clickhouse_events_queue.len() >= MAX_QUEUE_LEN {
|
||||||
drop(state);
|
drop(state);
|
||||||
|
@ -276,10 +402,13 @@ impl Telemetry {
|
||||||
|
|
||||||
fn flush_clickhouse_events(self: &Arc<Self>) {
|
fn flush_clickhouse_events(self: &Arc<Self>) {
|
||||||
let mut state = self.state.lock();
|
let mut state = self.state.lock();
|
||||||
|
state.first_event_datetime = None;
|
||||||
let mut events = mem::take(&mut state.clickhouse_events_queue);
|
let mut events = mem::take(&mut state.clickhouse_events_queue);
|
||||||
state.flush_clickhouse_events_task.take();
|
state.flush_clickhouse_events_task.take();
|
||||||
drop(state);
|
drop(state);
|
||||||
|
|
||||||
|
dbg!("In flush");
|
||||||
|
|
||||||
let this = self.clone();
|
let this = self.clone();
|
||||||
self.executor
|
self.executor
|
||||||
.spawn(
|
.spawn(
|
||||||
|
@ -317,6 +446,7 @@ impl Telemetry {
|
||||||
release_channel: state.release_channel,
|
release_channel: state.release_channel,
|
||||||
events,
|
events,
|
||||||
};
|
};
|
||||||
|
dbg!(&request_body);
|
||||||
json_bytes.clear();
|
json_bytes.clear();
|
||||||
serde_json::to_writer(&mut json_bytes, &request_body)?;
|
serde_json::to_writer(&mut json_bytes, &request_body)?;
|
||||||
}
|
}
|
||||||
|
|
|
@ -24,7 +24,7 @@ use ::git::diff::DiffHunk;
|
||||||
use aho_corasick::AhoCorasick;
|
use aho_corasick::AhoCorasick;
|
||||||
use anyhow::{anyhow, Context, Result};
|
use anyhow::{anyhow, Context, Result};
|
||||||
use blink_manager::BlinkManager;
|
use blink_manager::BlinkManager;
|
||||||
use client::{ClickhouseEvent, Client, Collaborator, ParticipantIndex, TelemetrySettings};
|
use client::{Client, Collaborator, ParticipantIndex, TelemetrySettings};
|
||||||
use clock::{Global, ReplicaId};
|
use clock::{Global, ReplicaId};
|
||||||
use collections::{BTreeMap, Bound, HashMap, HashSet, VecDeque};
|
use collections::{BTreeMap, Bound, HashMap, HashSet, VecDeque};
|
||||||
use convert_case::{Case, Casing};
|
use convert_case::{Case, Casing};
|
||||||
|
@ -8946,12 +8946,12 @@ impl Editor {
|
||||||
let telemetry = project.read(cx).client().telemetry().clone();
|
let telemetry = project.read(cx).client().telemetry().clone();
|
||||||
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
let telemetry_settings = *settings::get::<TelemetrySettings>(cx);
|
||||||
|
|
||||||
let event = ClickhouseEvent::Copilot {
|
telemetry.report_copilot_event(
|
||||||
|
telemetry_settings,
|
||||||
suggestion_id,
|
suggestion_id,
|
||||||
suggestion_accepted,
|
suggestion_accepted,
|
||||||
file_extension,
|
file_extension,
|
||||||
};
|
)
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(any(test, feature = "test-support"))]
|
#[cfg(any(test, feature = "test-support"))]
|
||||||
|
@ -8998,14 +8998,14 @@ impl Editor {
|
||||||
.show_copilot_suggestions;
|
.show_copilot_suggestions;
|
||||||
|
|
||||||
let telemetry = project.read(cx).client().telemetry().clone();
|
let telemetry = project.read(cx).client().telemetry().clone();
|
||||||
let event = ClickhouseEvent::Editor {
|
telemetry.report_editor_event(
|
||||||
|
telemetry_settings,
|
||||||
file_extension,
|
file_extension,
|
||||||
vim_mode,
|
vim_mode,
|
||||||
operation,
|
operation,
|
||||||
copilot_enabled,
|
copilot_enabled,
|
||||||
copilot_enabled_for_language,
|
copilot_enabled_for_language,
|
||||||
};
|
)
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Copy the highlighted chunks to the clipboard as JSON. The format is an array of lines,
|
/// Copy the highlighted chunks to the clipboard as JSON. The format is an array of lines,
|
||||||
|
|
|
@ -24,7 +24,7 @@ use ::git::diff::DiffHunk;
|
||||||
use aho_corasick::AhoCorasick;
|
use aho_corasick::AhoCorasick;
|
||||||
use anyhow::{anyhow, Context as _, Result};
|
use anyhow::{anyhow, Context as _, Result};
|
||||||
use blink_manager::BlinkManager;
|
use blink_manager::BlinkManager;
|
||||||
use client::{ClickhouseEvent, Client, Collaborator, ParticipantIndex, TelemetrySettings};
|
use client::{Client, Collaborator, ParticipantIndex, TelemetrySettings};
|
||||||
use clock::ReplicaId;
|
use clock::ReplicaId;
|
||||||
use collections::{BTreeMap, Bound, HashMap, HashSet, VecDeque};
|
use collections::{BTreeMap, Bound, HashMap, HashSet, VecDeque};
|
||||||
use convert_case::{Case, Casing};
|
use convert_case::{Case, Casing};
|
||||||
|
@ -8968,12 +8968,12 @@ impl Editor {
|
||||||
let telemetry = project.read(cx).client().telemetry().clone();
|
let telemetry = project.read(cx).client().telemetry().clone();
|
||||||
let telemetry_settings = *TelemetrySettings::get_global(cx);
|
let telemetry_settings = *TelemetrySettings::get_global(cx);
|
||||||
|
|
||||||
let event = ClickhouseEvent::Copilot {
|
telemetry.report_copilot_event(
|
||||||
|
telemetry_settings,
|
||||||
suggestion_id,
|
suggestion_id,
|
||||||
suggestion_accepted,
|
suggestion_accepted,
|
||||||
file_extension,
|
file_extension,
|
||||||
};
|
)
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(any(test, feature = "test-support"))]
|
#[cfg(any(test, feature = "test-support"))]
|
||||||
|
@ -8985,7 +8985,7 @@ impl Editor {
|
||||||
) {
|
) {
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(not(any(test, feature = "test-support")))]
|
// #[cfg(not(any(test, feature = "test-support")))]
|
||||||
fn report_editor_event(
|
fn report_editor_event(
|
||||||
&self,
|
&self,
|
||||||
operation: &'static str,
|
operation: &'static str,
|
||||||
|
@ -9020,14 +9020,14 @@ impl Editor {
|
||||||
.show_copilot_suggestions;
|
.show_copilot_suggestions;
|
||||||
|
|
||||||
let telemetry = project.read(cx).client().telemetry().clone();
|
let telemetry = project.read(cx).client().telemetry().clone();
|
||||||
let event = ClickhouseEvent::Editor {
|
telemetry.report_editor_event(
|
||||||
|
telemetry_settings,
|
||||||
file_extension,
|
file_extension,
|
||||||
vim_mode,
|
vim_mode,
|
||||||
operation,
|
operation,
|
||||||
copilot_enabled,
|
copilot_enabled,
|
||||||
copilot_enabled_for_language,
|
copilot_enabled_for_language,
|
||||||
};
|
)
|
||||||
telemetry.report_clickhouse_event(event, telemetry_settings)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Copy the highlighted chunks to the clipboard as JSON. The format is an array of lines,
|
/// Copy the highlighted chunks to the clipboard as JSON. The format is an array of lines,
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
|
|
||||||
use anyhow::{anyhow, Context, Result};
|
use anyhow::{anyhow, Context, Result};
|
||||||
use backtrace::Backtrace;
|
use backtrace::Backtrace;
|
||||||
|
use chrono::{DateTime, Utc};
|
||||||
use cli::FORCE_CLI_MODE_ENV_VAR_NAME;
|
use cli::FORCE_CLI_MODE_ENV_VAR_NAME;
|
||||||
use client::{
|
use client::{
|
||||||
self, Client, TelemetrySettings, UserStore, ZED_APP_VERSION, ZED_SECRET_CLIENT_TOKEN,
|
self, Client, TelemetrySettings, UserStore, ZED_APP_VERSION, ZED_SECRET_CLIENT_TOKEN,
|
||||||
|
@ -490,10 +491,7 @@ fn init_panic_hook(app: &App, installation_id: Option<String>, session_id: Strin
|
||||||
.ok()
|
.ok()
|
||||||
.map(|os_version| os_version.to_string()),
|
.map(|os_version| os_version.to_string()),
|
||||||
architecture: env::consts::ARCH.into(),
|
architecture: env::consts::ARCH.into(),
|
||||||
panicked_on: SystemTime::now()
|
panicked_on: Utc::now().timestamp_millis(),
|
||||||
.duration_since(UNIX_EPOCH)
|
|
||||||
.unwrap()
|
|
||||||
.as_millis(),
|
|
||||||
backtrace,
|
backtrace,
|
||||||
installation_id: installation_id.clone(),
|
installation_id: installation_id.clone(),
|
||||||
session_id: session_id.clone(),
|
session_id: session_id.clone(),
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
|
|
||||||
use anyhow::{anyhow, Context as _, Result};
|
use anyhow::{anyhow, Context as _, Result};
|
||||||
use backtrace::Backtrace;
|
use backtrace::Backtrace;
|
||||||
|
use chrono::{DateTime, Utc};
|
||||||
use cli::FORCE_CLI_MODE_ENV_VAR_NAME;
|
use cli::FORCE_CLI_MODE_ENV_VAR_NAME;
|
||||||
use client::UserStore;
|
use client::UserStore;
|
||||||
use db::kvp::KEY_VALUE_STORE;
|
use db::kvp::KEY_VALUE_STORE;
|
||||||
|
@ -72,6 +73,7 @@ fn main() {
|
||||||
let app = App::production(Arc::new(Assets));
|
let app = App::production(Arc::new(Assets));
|
||||||
|
|
||||||
let installation_id = app.background_executor().block(installation_id()).ok();
|
let installation_id = app.background_executor().block(installation_id()).ok();
|
||||||
|
dbg!("HERE", &installation_id);
|
||||||
let session_id = Uuid::new_v4().to_string();
|
let session_id = Uuid::new_v4().to_string();
|
||||||
init_panic_hook(&app, installation_id.clone(), session_id.clone());
|
init_panic_hook(&app, installation_id.clone(), session_id.clone());
|
||||||
|
|
||||||
|
@ -172,7 +174,7 @@ fn main() {
|
||||||
// })
|
// })
|
||||||
// .detach();
|
// .detach();
|
||||||
|
|
||||||
// client.telemetry().start(installation_id, session_id, cx);
|
client.telemetry().start(installation_id, session_id, cx);
|
||||||
|
|
||||||
let app_state = Arc::new(AppState {
|
let app_state = Arc::new(AppState {
|
||||||
languages,
|
languages,
|
||||||
|
@ -514,10 +516,7 @@ fn init_panic_hook(app: &App, installation_id: Option<String>, session_id: Strin
|
||||||
.as_ref()
|
.as_ref()
|
||||||
.map(SemanticVersion::to_string),
|
.map(SemanticVersion::to_string),
|
||||||
architecture: env::consts::ARCH.into(),
|
architecture: env::consts::ARCH.into(),
|
||||||
panicked_on: SystemTime::now()
|
panicked_on: Utc::now().timestamp_millis(),
|
||||||
.duration_since(UNIX_EPOCH)
|
|
||||||
.unwrap()
|
|
||||||
.as_millis(),
|
|
||||||
backtrace,
|
backtrace,
|
||||||
installation_id: installation_id.clone(),
|
installation_id: installation_id.clone(),
|
||||||
session_id: session_id.clone(),
|
session_id: session_id.clone(),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue