Enable Rust trace log packs (#4514)

* Enable Rust trace log packs

This is a way to forcefully enable trace logs only for a few Rust crates in a safe way
This commit is contained in:
Jorge Martin Espinosa 2025-04-02 13:21:53 +02:00 committed by GitHub
parent b2791d5aad
commit c3ff9c9bda
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 131 additions and 4 deletions

View file

@ -0,0 +1,22 @@
/*
* Copyright 2025 New Vector Ltd.
*
* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial
* Please see LICENSE files in the repository root for full details.
*/
package io.element.android.libraries.matrix.api.tracing
enum class TraceLogPack(val key: String) {
EVENT_CACHE("event_cache") {
override val title: String = "Event Cache"
},
SEND_QUEUE("send_queue") {
override val title: String = "Send Queue"
},
TIMELINE("timeline") {
override val title: String = "Timeline"
};
abstract val title: String
}

View file

@ -10,6 +10,7 @@ package io.element.android.libraries.matrix.api.tracing
data class TracingConfiguration(
val logLevel: LogLevel,
val extraTargets: List<String>,
val traceLogPacks: Set<TraceLogPack>,
val writesToLogcat: Boolean,
val writesToFilesConfiguration: WriteToFilesConfiguration,
)