Skip to content

Commit dc30a6f

Browse files
nipunn1313Convex, Inc.
authored andcommitted
Reduce startup logging verbosity (#25582)
Reduce to debug - squash many lines of logs into one. Makes `just run-backend` look nicer as well as reduce production datadog logging volume during push. GitOrigin-RevId: e22dae5aaf450efda53617f46bd92701a59f6956
1 parent 24a9547 commit dc30a6f

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

crates/database/src/transaction.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -698,7 +698,7 @@ impl<RT: Runtime> Transaction<RT> {
698698
.await?;
699699
tracing::info!("Created system table: {table_name}");
700700
} else {
701-
tracing::info!("Skipped creating system table {table_name} since it already exists");
701+
tracing::debug!("Skipped creating system table {table_name} since it already exists");
702702
};
703703
Ok(is_new)
704704
}
@@ -727,7 +727,7 @@ impl<RT: Runtime> Transaction<RT> {
727727
.await?;
728728
tracing::info!("Created virtual table: {table_name} with doc_id {table_doc_id}");
729729
} else {
730-
tracing::info!("Skipped creating virtual table {table_name} since it already exists");
730+
tracing::debug!("Skipped creating virtual table {table_name} since it already exists");
731731
};
732732
Ok(is_new)
733733
}

crates/indexing/src/backend_in_memory_indexes.rs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,9 @@ impl BackendInMemoryIndexes {
136136
snapshot: &PersistenceSnapshot,
137137
tables: &BTreeSet<TableName>,
138138
) -> anyhow::Result<()> {
139-
for index_metadata in index_registry.all_enabled_indexes() {
139+
let enabled_indexes = index_registry.all_enabled_indexes();
140+
tracing::info!("Loading {} enabled indexes", enabled_indexes.len());
141+
for index_metadata in enabled_indexes {
140142
let table_name = table_mapping.tablet_name(*index_metadata.name.table())?;
141143
if tables.contains(&table_name) {
142144
match &index_metadata.config {
@@ -152,14 +154,14 @@ impl BackendInMemoryIndexes {
152154
continue;
153155
},
154156
}
155-
tracing::info!(
157+
tracing::debug!(
156158
"Loading {table_name}.{} ...",
157159
index_metadata.name.descriptor()
158160
);
159161
let (num_keys, total_bytes) = self
160162
.load_enabled(index_registry, &index_metadata.name, snapshot)
161163
.await?;
162-
tracing::info!("Loaded {num_keys} keys, {total_bytes} bytes.");
164+
tracing::debug!("Loaded {num_keys} keys, {total_bytes} bytes.");
163165
}
164166
}
165167
Ok(())

0 commit comments

Comments
 (0)