Make slow queries logs show only when log tag enabled

Test: Manual
Bug: 205056348
Change-Id: Ie3ef14e053381003f0c3de00b0260c7669d18c8c
This commit is contained in:
Edgar Arriaga
2021-11-03 18:34:06 -07:00
parent 2de9ed3130
commit 87e9c5da46

View File

@@ -70,7 +70,8 @@ public final class SQLiteDebug {
/**
* True to enable database performance testing instrumentation.
*/
public static final boolean DEBUG_LOG_SLOW_QUERIES = Build.IS_DEBUGGABLE;
public static final boolean DEBUG_LOG_SLOW_QUERIES =
Log.isLoggable("SQLiteSlowQueries", Log.VERBOSE);
private static final String SLOW_QUERY_THRESHOLD_PROP = "db.log.slow_query_threshold";