New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 639313 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
no longer working on chrome
Closed: Aug 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Bug



Sign in to add a comment

GCM doesn't always contain Strings

Project Member Reported by joh...@chromium.org, Aug 19 2016

Issue description

GCM (FCM) sometimes sends a "google.sent_time" Long in the incoming message Bundle. Our code assumes the bundle values will always be Strings. Fortunately, this only results in log warnings, rather than anything more serious.
 

Comment 1 by joh...@chromium.org, Aug 19 2016

FWIW, this also affected other GCM consumers, e.g. https://github.com/morinel/gcmpush/issues/45 and https://github.com/rpush/rpush/issues/292.

Comment 2 by joh...@chromium.org, Aug 19 2016

Android patch: https://codereview.chromium.org/2265543002

I don't think this can affect desktop since google_apis/gcm/protocol/mcs.proto explicitly restricts AppData to string-string key-value pairs.

Comment 3 by peter@chromium.org, Aug 21 2016

Cc: peter@chromium.org zea@chromium.org
Does this mean that our AppData message has gotten out of date with MCS (which should be updated), or is a different protocol being used for Android altogether?
Project Member

Comment 4 by bugdroid1@chromium.org, Aug 22 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6688926c9db1c186b24b729fe8c8588f747a1a4a

commit 6688926c9db1c186b24b729fe8c8588f747a1a4a
Author: johnme <johnme@chromium.org>
Date: Mon Aug 22 13:15:18 2016

GCM: Handle non-Strings in incoming message Bundle

Google Cloud Messaging recently started including a "google.sent_time"
Long in the incoming message Bundle from Google Play Services. This
patch filters out non-String values to prevent warnings about
ClassCastExceptions.

BUG= 639313 

Review-Url: https://codereview.chromium.org/2265543002
Cr-Commit-Position: refs/heads/master@{#413435}

[modify] https://crrev.com/6688926c9db1c186b24b729fe8c8588f747a1a4a/components/gcm_driver/android/java/src/org/chromium/components/gcm_driver/GCMDriver.java

Comment 5 by joh...@chromium.org, Aug 22 2016

Labels: M-54
Status: Fixed (was: Started)
No, the MCS server proto still seems to match: https://goto.google.com/jxcgr
The long is being added by the Android Google Play Services app.

Sign in to add a comment