From 3b4fb45a8879c937d78f8bcb1db32af132cb99f4 Mon Sep 17 00:00:00 2001 From: Ficus Kirkpatrick Date: Mon, 6 Jul 2015 14:26:30 -0700 Subject: Stop logging slow requests outside of debug logs. This dumps the URL, which can contain PII. --- src/main/java/com/android/volley/Request.java | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/src/main/java/com/android/volley/Request.java b/src/main/java/com/android/volley/Request.java index 9832952..5b42d1f 100644 --- a/src/main/java/com/android/volley/Request.java +++ b/src/main/java/com/android/volley/Request.java @@ -90,12 +90,6 @@ public abstract class Request implements Comparable> { /** Whether or not a response has been delivered for this request yet. */ private boolean mResponseDelivered = false; - // A cheap variant of request tracing used to dump slow requests. - private long mRequestBirthTime = 0; - - /** Threshold at which we should log the request (even when debug logging is not enabled). */ - private static final long SLOW_REQUEST_THRESHOLD_MS = 3000; - /** The retry policy for this request. */ private RetryPolicy mRetryPolicy; @@ -209,8 +203,6 @@ public abstract class Request implements Comparable> { public void addMarker(String tag) { if (MarkerLog.ENABLED) { mEventLog.add(tag, Thread.currentThread().getId()); - } else if (mRequestBirthTime == 0) { - mRequestBirthTime = SystemClock.elapsedRealtime(); } } @@ -241,11 +233,6 @@ public abstract class Request implements Comparable> { mEventLog.add(tag, threadId); mEventLog.finish(this.toString()); - } else { - long requestTime = SystemClock.elapsedRealtime() - mRequestBirthTime; - if (requestTime >= SLOW_REQUEST_THRESHOLD_MS) { - VolleyLog.d("%d ms: %s", requestTime, this.toString()); - } } } -- cgit v1.2.3