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

Issue 2849753002: Logs all reasons card upload was not offered in UKM and UMA. (Closed)

Created:
3 years, 7 months ago by csashi
Modified:
3 years, 7 months ago
CC:
chromium-reviews, rouslan+autofill_chromium.org, rogerm+autofillwatch_chromium.org, sebsg+autofillwatch_chromium.org, browser-components-watch_chromium.org, mathp+autofillwatch_chromium.org, vabr+watchlistautofill_chromium.org, estade+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Logs all reasons card upload was not offered in UKM and UMA. UPLOAD_OFFERED and UPLOAD_NOT_OFFERED are the 2 big buckets. Other buckets count the specific reasons. Fixes DeveloperEngagementUkm to also use bit mask instead of separate metrics. BUG=713842 Review-Url: https://codereview.chromium.org/2849753002 Cr-Commit-Position: refs/heads/master@{#468852} Committed: https://chromium.googlesource.com/chromium/src/+/bc9f3b2b440eac0f15e651a9c3fd38eb40c849bf

Patch Set 1 #

Total comments: 18

Patch Set 2 : Encodes enum metrics as bitmask. #

Patch Set 3 : Encodes enum metrics as bitmask. #

Total comments: 3

Patch Set 4 : Replaces CardUploadDecisionExpanded with CardUploadDecisionMetric. #

Total comments: 8

Patch Set 5 : Uses bitmask to log both UKM and UMA metrics. #

Patch Set 6 : Uses bitmask to log both UKM and UMA metrics. #

Total comments: 2

Patch Set 7 : Removes redundant bits for UPLOAD_OFFERED and UPLOAD_NOT_OFFERED. #

Total comments: 3

Patch Set 8 : Formatting fix. #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+259 lines, -202 lines) Patch
M components/autofill/core/browser/autofill_manager.h View 1 2 3 4 2 chunks +13 lines, -14 lines 0 comments Download
M components/autofill/core/browser/autofill_manager.cc View 1 2 3 4 5 6 7 14 chunks +51 lines, -69 lines 0 comments Download
M components/autofill/core/browser/autofill_manager_unittest.cc View 1 2 3 4 5 6 19 chunks +95 lines, -65 lines 0 comments Download
M components/autofill/core/browser/autofill_metrics.h View 1 2 3 4 5 6 4 chunks +24 lines, -22 lines 4 comments Download
M components/autofill/core/browser/autofill_metrics.cc View 1 2 3 4 3 chunks +25 lines, -21 lines 0 comments Download
M components/autofill/core/browser/autofill_metrics_unittest.cc View 1 2 3 4 5 1 chunk +5 lines, -3 lines 0 comments Download
M components/autofill/core/browser/form_structure.cc View 1 1 chunk +7 lines, -5 lines 0 comments Download
M tools/metrics/histograms/histograms.xml View 1 2 3 4 5 5 chunks +35 lines, -1 line 0 comments Download
M tools/metrics/ukm/ukm.xml View 1 2 chunks +4 lines, -2 lines 0 comments Download

Messages

Total messages: 65 (34 generated)
csashi
Hi, Please take a look. Thanks, -sashi.
3 years, 7 months ago (2017-04-28 05:25:00 UTC) #3
csashi
On 2017/04/28 05:25:00, csashi wrote: > Hi, > Please take a look. Thanks, -sashi. Hi, ...
3 years, 7 months ago (2017-04-28 07:21:43 UTC) #8
sebsg
Very glad to see this change! Some comments: https://codereview.chromium.org/2849753002/diff/1/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/2849753002/diff/1/components/autofill/core/browser/autofill_manager.cc#newcode1272 components/autofill/core/browser/autofill_manager.cc:1272: if ...
3 years, 7 months ago (2017-04-28 15:26:24 UTC) #9
Jared Saul
https://codereview.chromium.org/2849753002/diff/1/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/2849753002/diff/1/components/autofill/core/browser/autofill_manager.cc#newcode1261 components/autofill/core/browser/autofill_manager.cc:1261: bool get_profiles_succeeded = GetProfilesForCreditCardUpload( Is this new formatting the ...
3 years, 7 months ago (2017-04-28 19:21:42 UTC) #10
csashi
Hi, Still have to fix some unit tests and add new ones but please take ...
3 years, 7 months ago (2017-04-28 23:47:45 UTC) #11
csashi
On 2017/04/28 23:47:45, csashi wrote: > Hi, > Still have to fix some unit tests ...
3 years, 7 months ago (2017-04-29 02:12:13 UTC) #13
csashi
Hi Steven, Please review tools/metrics. Thanks! -sashi.
3 years, 7 months ago (2017-04-29 04:11:47 UTC) #19
sebsg
Nice improvements! Some comments, could you also add in your description that you add a ...
3 years, 7 months ago (2017-05-01 02:46:21 UTC) #22
csashi
https://codereview.chromium.org/2849753002/diff/1/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/2849753002/diff/1/components/autofill/core/browser/autofill_manager.cc#newcode1272 components/autofill/core/browser/autofill_manager.cc:1272: if (get_profiles_succeeded && On 2017/05/01 02:46:20, sebsg wrote: > ...
3 years, 7 months ago (2017-05-01 16:01:56 UTC) #23
csashi
3 years, 7 months ago (2017-05-01 16:01:58 UTC) #24
sebsg
https://codereview.chromium.org/2849753002/diff/40001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/2849753002/diff/40001/components/autofill/core/browser/autofill_manager.cc#newcode1060 components/autofill/core/browser/autofill_manager.cc:1060: card_upload_decision_metrics = 1 << AutofillMetrics::UPLOAD_OFFERED; On 2017/05/01 16:01:56, csashi ...
3 years, 7 months ago (2017-05-01 16:10:17 UTC) #25
csashi
On 2017/05/01 16:10:17, sebsg wrote: > https://codereview.chromium.org/2849753002/diff/40001/components/autofill/core/browser/autofill_manager.cc > File components/autofill/core/browser/autofill_manager.cc (right): > > https://codereview.chromium.org/2849753002/diff/40001/components/autofill/core/browser/autofill_manager.cc#newcode1060 > ...
3 years, 7 months ago (2017-05-01 17:16:21 UTC) #26
sebsg
Thanks :) Could you use the same variable to store the values for both UKM ...
3 years, 7 months ago (2017-05-01 21:00:13 UTC) #27
Jared Saul
https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_manager.cc#newcode1087 components/autofill/core/browser/autofill_manager.cc:1087: AutofillMetrics::UPLOAD_NOT_OFFERED_GET_UPLOAD_DETAILS_FAILED); It feels kind of flaky that if anything ...
3 years, 7 months ago (2017-05-01 21:05:13 UTC) #28
csashi
On 2017/05/01 02:46:21, sebsg wrote: > Nice improvements! > > Some comments, could you also ...
3 years, 7 months ago (2017-05-01 21:29:15 UTC) #29
Steven Holte
https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_manager.cc#newcode1064 components/autofill/core/browser/autofill_manager.cc:1064: card_upload_decision_metrics |= 1 Are you always calling AutofillMetrics::LogCardUploadDecisionMetric for ...
3 years, 7 months ago (2017-05-02 00:36:33 UTC) #30
csashi
Hi, Please take a look. Thanks! -sashi. https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_manager.cc#newcode1064 components/autofill/core/browser/autofill_manager.cc:1064: card_upload_decision_metrics |= ...
3 years, 7 months ago (2017-05-02 00:43:56 UTC) #31
Jared Saul
https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_metrics.cc File components/autofill/core/browser/autofill_metrics.cc (right): https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_metrics.cc#newcode82 components/autofill/core/browser/autofill_metrics.cc:82: On 2017/05/02 00:43:56, csashi wrote: > On 2017/05/01 21:05:12, ...
3 years, 7 months ago (2017-05-02 01:39:46 UTC) #38
Steven Holte
https://codereview.chromium.org/2849753002/diff/100001/components/autofill/core/browser/autofill_metrics.h File components/autofill/core/browser/autofill_metrics.h (right): https://codereview.chromium.org/2849753002/diff/100001/components/autofill/core/browser/autofill_metrics.h#newcode135 components/autofill/core/browser/autofill_metrics.h:135: UPLOAD_NOT_OFFERED = 1 << 9, Does it make sense ...
3 years, 7 months ago (2017-05-02 19:33:20 UTC) #41
csashi
Hi, Please take a look. Thanks, -sashi. https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_metrics.cc File components/autofill/core/browser/autofill_metrics.cc (right): https://codereview.chromium.org/2849753002/diff/60001/components/autofill/core/browser/autofill_metrics.cc#newcode82 components/autofill/core/browser/autofill_metrics.cc:82: On 2017/05/02 ...
3 years, 7 months ago (2017-05-02 20:23:31 UTC) #42
sebsg
LGTM for autofill code with a small nit. Thanks for your perseverance! https://codereview.chromium.org/2849753002/diff/120001/components/autofill/core/browser/autofill_metrics.h File components/autofill/core/browser/autofill_metrics.h ...
3 years, 7 months ago (2017-05-02 20:31:29 UTC) #43
csashi
https://codereview.chromium.org/2849753002/diff/120001/components/autofill/core/browser/autofill_metrics.h File components/autofill/core/browser/autofill_metrics.h (right): https://codereview.chromium.org/2849753002/diff/120001/components/autofill/core/browser/autofill_metrics.h#newcode889 components/autofill/core/browser/autofill_metrics.h:889: static const int kNumCardUploadDecisionMetrics = 9; On 2017/05/02 20:31:29, ...
3 years, 7 months ago (2017-05-02 20:35:19 UTC) #44
sebsg
https://codereview.chromium.org/2849753002/diff/120001/components/autofill/core/browser/autofill_metrics.h File components/autofill/core/browser/autofill_metrics.h (right): https://codereview.chromium.org/2849753002/diff/120001/components/autofill/core/browser/autofill_metrics.h#newcode889 components/autofill/core/browser/autofill_metrics.h:889: static const int kNumCardUploadDecisionMetrics = 9; On 2017/05/02 20:35:19, ...
3 years, 7 months ago (2017-05-02 20:36:36 UTC) #45
csashi
On 2017/05/02 20:36:36, sebsg wrote: > https://codereview.chromium.org/2849753002/diff/120001/components/autofill/core/browser/autofill_metrics.h > File components/autofill/core/browser/autofill_metrics.h (right): > > https://codereview.chromium.org/2849753002/diff/120001/components/autofill/core/browser/autofill_metrics.h#newcode889 > ...
3 years, 7 months ago (2017-05-02 23:49:39 UTC) #54
Steven Holte
lgtm, with or without flag changes. https://codereview.chromium.org/2849753002/diff/140001/components/autofill/core/browser/autofill_metrics.h File components/autofill/core/browser/autofill_metrics.h (right): https://codereview.chromium.org/2849753002/diff/140001/components/autofill/core/browser/autofill_metrics.h#newcode106 components/autofill/core/browser/autofill_metrics.h:106: UPLOAD_NOT_OFFERED_NO_ADDRESS = 1 ...
3 years, 7 months ago (2017-05-02 23:50:29 UTC) #55
csashi
https://codereview.chromium.org/2849753002/diff/140001/components/autofill/core/browser/autofill_metrics.h File components/autofill/core/browser/autofill_metrics.h (right): https://codereview.chromium.org/2849753002/diff/140001/components/autofill/core/browser/autofill_metrics.h#newcode106 components/autofill/core/browser/autofill_metrics.h:106: UPLOAD_NOT_OFFERED_NO_ADDRESS = 1 << 2, On 2017/05/02 23:50:29, Steven ...
3 years, 7 months ago (2017-05-02 23:54:43 UTC) #56
Jared Saul
lgtm
3 years, 7 months ago (2017-05-03 00:22:38 UTC) #57
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2849753002/140001
3 years, 7 months ago (2017-05-03 00:49:08 UTC) #60
Steven Holte
https://codereview.chromium.org/2849753002/diff/140001/components/autofill/core/browser/autofill_metrics.h File components/autofill/core/browser/autofill_metrics.h (right): https://codereview.chromium.org/2849753002/diff/140001/components/autofill/core/browser/autofill_metrics.h#newcode106 components/autofill/core/browser/autofill_metrics.h:106: UPLOAD_NOT_OFFERED_NO_ADDRESS = 1 << 2, On 2017/05/02 23:54:43, csashi ...
3 years, 7 months ago (2017-05-03 01:04:05 UTC) #61
commit-bot: I haz the power
Committed patchset #8 (id:140001) as https://chromium.googlesource.com/chromium/src/+/bc9f3b2b440eac0f15e651a9c3fd38eb40c849bf
3 years, 7 months ago (2017-05-03 01:09:55 UTC) #64
csashi
3 years, 7 months ago (2017-05-03 01:20:41 UTC) #65
Message was sent while issue was closed.
https://codereview.chromium.org/2849753002/diff/140001/components/autofill/co...
File components/autofill/core/browser/autofill_metrics.h (right):

https://codereview.chromium.org/2849753002/diff/140001/components/autofill/co...
components/autofill/core/browser/autofill_metrics.h:106:
UPLOAD_NOT_OFFERED_NO_ADDRESS = 1 << 2,
On 2017/05/03 01:04:05, Steven Holte wrote:
> On 2017/05/02 23:54:43, csashi wrote:
> > On 2017/05/02 23:50:29, Steven Holte wrote:
> > > What about the UPLOAD_NOT_OFFERED part of UPLOAD_NOT_OFFERED_NO_ADDRESS? 
Is
> > > that needed?
> > 
> > I don't follow this comment. We log this bit if the upload was not offered
> > because we could not find an address - i.e.
> > UPLOAD_NOT_OFFERED_NO_ADDRESS => UPLOAD_NOT_OFFERED.
> > 
> > I removed the separate UPLOAD_NOT_OFFERED bit.
> > 
> > Can you clarify? Thanks.
> 
> For logging this to UKM, it seems like the bit is redundant, since the fact
that
> you are not setting UPLOAD_OFFERED means upload was not offered. It seems like
> it's nice if each bit's meaning is fairly independent, even if one is the
cause
> for another.
> 
> For UMA it seems like you are not actually trying to co-occurances, like
whether
> NO_ZIP_CODE is occuring with NO_ADDRESS, with the exception of OFFERED and
> NO_CVC, which is the only "recoverable" error?  And it seems like you are
> planning to compare counts of buckets against another bucket as a baseline,
> rather than total counts since you recording multiple times for a single
> opportunity.  I guess you also need to update the descriptions of these values
> here?
> 
> There are maybe a couple other ways you might encode this:
> 
> 1. If you don't actually have that many distinct combinations of errors, and
it
> seems like some of them are exclusive/dependent, you could probably get away
> with using a SPARSE_HISTOGRAM and just sending the same mask to UMA as you
send
> to UMA as your buckets, though you'd have to encode the combinations in
> histograms.xml
> 
> 2. If there are more combinations than you care about, and you just care about
> co-occurence with Upload offered or not for UMA, you could probably record two
> histograms, with the different errors as values, one for offered one for not.
> 
> It seems like that might allow you to disentangle some of these bits from a
> logic, but it will probably work fine as is too.

Unfortunately, not setting UPLOAD_OFFERED does not mean upload was not offered.
The reason is we also have UPLOAD_OFFERED_NO_CVC and we hope to imminently add
additional such bits like UPLOAD_OFFERED_NAME_NORMALIZED etc.

In retrospect, I should have renamed UPLOAD_OFFERED to
UPLOAD_OFFERED_WITHOUT_ANY_FIX (or some such equivalent). I can do that in a
follow up CL or in this CL if the commit fails anyway for some reason.

I agreed that we lose the total count of failures in UMA because we are
recording multiple failures for a single opportunity. Jared also pointed this
out offline. But we will be able to find the total count of failures in UKM.

My primary goal for this change for UMA was to find out if there are big counts
in any of the UPLOAD_NOT_OFFERED bits. This will help us prioritize fixing that
error. Co-occurrences are useful but we will get that from UKM.

Reg. Sparse histograms - Sebastien also suggested this but we don't know if we
will have many distinct combinations or not - UKM will tell us that but right
now we don't know.

Powered by Google App Engine
This is Rietveld 408576698