Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1038)

Issue 1048153002: Add an utility class to improve java logs. (Closed)

Created:
5 years, 8 months ago by dgn
Modified:
5 years, 8 months ago
Reviewers:
Ted C, Yaron, Torne
CC:
chromium-reviews, darin-cc_chromium.org, erikwright+watch_chromium.org, jam
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add an utility class to improve java logs. Add the Log class to org.chromium.base. It is meant to hold different loggers for each feature. Currently a neutral, ROOT is available. New loggers will have to be added there as classes migrate to using base.Log. BUG=472152 Committed: https://crrev.com/33e4d5203f0d166c78925215a29a1416aacee1b8 Cr-Commit-Position: refs/heads/master@{#323747}

Patch Set 1 #

Patch Set 2 : Added the NoSideEffects annotation #

Patch Set 3 : Add overrides of the log functions to allow proguard to properly remove arguments #

Total comments: 12

Patch Set 4 : Removed test, make varargs fn private, add file/line numbers #

Total comments: 3

Patch Set 5 : Fixed the code for getting the caller info #

Patch Set 6 : Fix for findbugs #

Total comments: 2

Patch Set 7 : Rename Log.info to Log.i #

Unified diffs Side-by-side diffs Delta from patch set Stats (+329 lines, -0 lines) Patch
A base/android/java/src/org/chromium/base/Log.java View 1 2 3 4 5 6 1 chunk +312 lines, -0 lines 0 comments Download
A base/android/java/src/org/chromium/base/annotations/NoSideEffects.java View 1 2 1 chunk +17 lines, -0 lines 0 comments Download

Messages

Total messages: 30 (10 generated)
dgn
Yaron: PTAL at everything (2 new files)
5 years, 8 months ago (2015-03-31 16:46:37 UTC) #2
Yaron
https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java#newcode107 base/android/java/src/org/chromium/base/Log.java:107: * For optimization purposes, use the fixed parameters versions ...
5 years, 8 months ago (2015-04-01 20:47:31 UTC) #3
Torne
https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java#newcode107 base/android/java/src/org/chromium/base/Log.java:107: * For optimization purposes, use the fixed parameters versions ...
5 years, 8 months ago (2015-04-02 10:50:05 UTC) #5
dgn
https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java#newcode107 base/android/java/src/org/chromium/base/Log.java:107: * For optimization purposes, use the fixed parameters versions ...
5 years, 8 months ago (2015-04-02 12:47:20 UTC) #6
Yaron
So outstanding is to move the test to base and make the varargs function private. ...
5 years, 8 months ago (2015-04-02 14:29:47 UTC) #7
dgn
https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/40001/base/android/java/src/org/chromium/base/Log.java#newcode115 base/android/java/src/org/chromium/base/Log.java:115: public void verbose(String secondaryTag, String messageTemplate, Object... args) { ...
5 years, 8 months ago (2015-04-02 14:47:15 UTC) #8
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1048153002/60001
5 years, 8 months ago (2015-04-02 16:10:45 UTC) #13
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1048153002/60001
5 years, 8 months ago (2015-04-02 16:17:49 UTC) #14
Ted C
https://codereview.chromium.org/1048153002/diff/60001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/60001/base/android/java/src/org/chromium/base/Log.java#newcode302 base/android/java/src/org/chromium/base/Log.java:302: return st[5].getFileName() + ":" + st[5].getLineNumber(); Is the index ...
5 years, 8 months ago (2015-04-02 16:19:55 UTC) #16
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1048153002/60001
5 years, 8 months ago (2015-04-02 16:31:23 UTC) #17
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1048153002/60001
5 years, 8 months ago (2015-04-02 16:47:19 UTC) #18
dgn
https://codereview.chromium.org/1048153002/diff/60001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/60001/base/android/java/src/org/chromium/base/Log.java#newcode302 base/android/java/src/org/chromium/base/Log.java:302: return st[5].getFileName() + ":" + st[5].getLineNumber(); On 2015/04/02 16:19:55, ...
5 years, 8 months ago (2015-04-02 16:49:04 UTC) #19
dgn
Test here: https://codereview.chromium.org/1051343002
5 years, 8 months ago (2015-04-02 17:39:59 UTC) #21
dgn
Yaron: PTAL. I changed the secondary tag for debug and verbose to be the filename ...
5 years, 8 months ago (2015-04-02 18:14:58 UTC) #22
Yaron
lgtm
5 years, 8 months ago (2015-04-02 19:52:13 UTC) #23
Yaron
https://codereview.chromium.org/1048153002/diff/100001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/100001/base/android/java/src/org/chromium/base/Log.java#newcode254 base/android/java/src/org/chromium/base/Log.java:254: public void info(String secondaryTag, String messageTemplate, Object... args) { ...
5 years, 8 months ago (2015-04-02 19:55:42 UTC) #24
dgn
https://codereview.chromium.org/1048153002/diff/100001/base/android/java/src/org/chromium/base/Log.java File base/android/java/src/org/chromium/base/Log.java (right): https://codereview.chromium.org/1048153002/diff/100001/base/android/java/src/org/chromium/base/Log.java#newcode254 base/android/java/src/org/chromium/base/Log.java:254: public void info(String secondaryTag, String messageTemplate, Object... args) { ...
5 years, 8 months ago (2015-04-03 14:40:01 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1048153002/120001
5 years, 8 months ago (2015-04-03 14:40:18 UTC) #28
commit-bot: I haz the power
Committed patchset #7 (id:120001)
5 years, 8 months ago (2015-04-03 15:44:52 UTC) #29
commit-bot: I haz the power
5 years, 8 months ago (2015-04-03 20:37:57 UTC) #30
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/33e4d5203f0d166c78925215a29a1416aacee1b8
Cr-Commit-Position: refs/heads/master@{#323747}

Powered by Google App Engine
This is Rietveld 408576698