From 3b1152615a2788c676d92b69e19d85ff3f9d8c7e Mon Sep 17 00:00:00 2001 From: "Lucas.Xu" Date: Fri, 14 Apr 2023 20:14:47 +0800 Subject: [PATCH] chore: add tracing to document2 (#2263) --- frontend/rust-lib/Cargo.lock | 1 + frontend/rust-lib/flowy-core/src/lib.rs | 1 + frontend/rust-lib/flowy-document2/Cargo.toml | 1 + 3 files changed, 3 insertions(+) diff --git a/frontend/rust-lib/Cargo.lock b/frontend/rust-lib/Cargo.lock index f8438e7031..82a1111913 100644 --- a/frontend/rust-lib/Cargo.lock +++ b/frontend/rust-lib/Cargo.lock @@ -1368,6 +1368,7 @@ dependencies = [ "serde_json", "strum", "strum_macros", + "tracing", ] [[package]] diff --git a/frontend/rust-lib/flowy-core/src/lib.rs b/frontend/rust-lib/flowy-core/src/lib.rs index 09bbecc1bd..984705a533 100644 --- a/frontend/rust-lib/flowy-core/src/lib.rs +++ b/frontend/rust-lib/flowy-core/src/lib.rs @@ -94,6 +94,7 @@ fn create_log_filter(level: String, with_crates: Vec) -> String { filters.push(format!("collab_folder={}", level)); filters.push(format!("flowy_user={}", level)); filters.push(format!("flowy_document={}", level)); + filters.push(format!("flowy_document2={}", level)); filters.push(format!("flowy_database={}", level)); filters.push(format!("flowy_sync={}", "info")); filters.push(format!("flowy_client_sync={}", "info")); diff --git a/frontend/rust-lib/flowy-document2/Cargo.toml b/frontend/rust-lib/flowy-document2/Cargo.toml index 3d76696705..4d6135e811 100644 --- a/frontend/rust-lib/flowy-document2/Cargo.toml +++ b/frontend/rust-lib/flowy-document2/Cargo.toml @@ -24,6 +24,7 @@ strum = "0.21" strum_macros = "0.21" serde = { version = "1.0", features = ["derive"] } serde_json = {version = "1.0"} +tracing = { version = "0.1", features = ["log"] } [build-dependencies] flowy-codegen = { path = "../flowy-codegen"}