[aerogear-dev] GCM3: InstanceID tokens versus 'old' tokens

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[aerogear-dev] GCM3: InstanceID tokens versus 'old' tokens

Matthias Wessendorf
Hi,

the format for tokens received from InstanceID API have a slightly different format:

It's basically (prefix_string : RegistrationID).

Now, in order to be able to subscribe on a topic is it _really_ required to have a 'new' InstanceID token ? I could not find a _clear_ statement

I am asking because I'm working on the server hook to send topic request.

If the answer yes, only InstanceID tokens can subscribe, we need a little switch on the server (not a show stopper):
1) send /topics/{something} (should not affect 'old' tokens_
2) fallback: find tokens w/o the ':', so we can fallback to pure registration Id for "non-Instance ID " tokens


Thanks,
Matthias

--

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] GCM3: InstanceID tokens versus 'old' tokens

Matthias Wessendorf


On Wed, Apr 20, 2016 at 12:19 PM, Matthias Wessendorf <[hidden email]> wrote:
Hi,

the format for tokens received from InstanceID API have a slightly different format:

It's basically (prefix_string : RegistrationID).

Now, in order to be able to subscribe on a topic is it _really_ required to have a 'new' InstanceID token ? I could not find a _clear_ statement

looks like InstanceID tokens are required:

But, on the other hand it does not mention that GCM.register() tokens are not allowed :-)
 

I am asking because I'm working on the server hook to send topic request.

If the answer yes, only InstanceID tokens can subscribe, we need a little switch on the server (not a show stopper):
1) send /topics/{something} (should not affect 'old' tokens_
2) fallback: find tokens w/o the ':', so we can fallback to pure registration Id for "non-Instance ID " tokens


Thanks,
Matthias

--



--

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] GCM3: InstanceID tokens versus 'old' tokens

Matthias Wessendorf
Even if they were allowed... Apps, with older AGDroid SDKs aren't able to subscribe. That means if the UPS server updates, they all would receive no message :-)

Therefore that look up for 'old' tokens is generally needed 

On Wed, Apr 20, 2016 at 1:23 PM, Matthias Wessendorf <[hidden email]> wrote:


On Wed, Apr 20, 2016 at 12:19 PM, Matthias Wessendorf <[hidden email]> wrote:
Hi,

the format for tokens received from InstanceID API have a slightly different format:

It's basically (prefix_string : RegistrationID).

Now, in order to be able to subscribe on a topic is it _really_ required to have a 'new' InstanceID token ? I could not find a _clear_ statement

looks like InstanceID tokens are required:

But, on the other hand it does not mention that GCM.register() tokens are not allowed :-)
 

I am asking because I'm working on the server hook to send topic request.

If the answer yes, only InstanceID tokens can subscribe, we need a little switch on the server (not a show stopper):
1) send /topics/{something} (should not affect 'old' tokens_
2) fallback: find tokens w/o the ':', so we can fallback to pure registration Id for "non-Instance ID " tokens


Thanks,
Matthias

--



--



--

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] GCM3: InstanceID tokens versus 'old' tokens

Summers Pittman
One of the things to consider is that applications re-register each time they load.  So an app can move from being registered with a GCM.register token to being registered with a InstanceID token.

I think that instanceID tokens have ":"'s and GCM.register tokens do not.

We should probably make a contrived scenario where an app registered and then changes to InstanceID to see what happens.  It SHOULDN'T get double messages because the app update relaunch step should break the old gcm token.  But we need to test it.

On Wed, Apr 20, 2016 at 7:33 AM, Matthias Wessendorf <[hidden email]> wrote:
Even if they were allowed... Apps, with older AGDroid SDKs aren't able to subscribe. That means if the UPS server updates, they all would receive no message :-)

Therefore that look up for 'old' tokens is generally needed 

On Wed, Apr 20, 2016 at 1:23 PM, Matthias Wessendorf <[hidden email]> wrote:


On Wed, Apr 20, 2016 at 12:19 PM, Matthias Wessendorf <[hidden email]> wrote:
Hi,

the format for tokens received from InstanceID API have a slightly different format:

It's basically (prefix_string : RegistrationID).

Now, in order to be able to subscribe on a topic is it _really_ required to have a 'new' InstanceID token ? I could not find a _clear_ statement

looks like InstanceID tokens are required:

But, on the other hand it does not mention that GCM.register() tokens are not allowed :-)
 

I am asking because I'm working on the server hook to send topic request.

If the answer yes, only InstanceID tokens can subscribe, we need a little switch on the server (not a show stopper):
1) send /topics/{something} (should not affect 'old' tokens_
2) fallback: find tokens w/o the ':', so we can fallback to pure registration Id for "non-Instance ID " tokens


Thanks,
Matthias

--



--



--

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev
Reply | Threaded
Open this post in threaded view
|

Re: [aerogear-dev] GCM3: InstanceID tokens versus 'old' tokens

Matthias Wessendorf


On Wed, Apr 20, 2016 at 2:42 PM, Summers Pittman <[hidden email]> wrote:
One of the things to consider is that applications re-register each time they load. 

right
 
So an app can move from being registered with a GCM.register token to being registered with a InstanceID token.

right, but until than ;-)
 

I think that instanceID tokens have ":"'s and GCM.register tokens do not.

right, 
 

We should probably make a contrived scenario where an app registered and then changes to InstanceID to see what happens.

I guess, it will get a token, following the new format.
 
  It SHOULDN'T get double messages because the app update relaunch step should break the old gcm token.  But we need to test it.

I think for apps that (for what ever reason) not upgrade to newest AGDroid SDK, we need to use the old way of pushing: query all tokens that do NOT have a : inside

-M

 

On Wed, Apr 20, 2016 at 7:33 AM, Matthias Wessendorf <[hidden email]> wrote:
Even if they were allowed... Apps, with older AGDroid SDKs aren't able to subscribe. That means if the UPS server updates, they all would receive no message :-)

Therefore that look up for 'old' tokens is generally needed 

On Wed, Apr 20, 2016 at 1:23 PM, Matthias Wessendorf <[hidden email]> wrote:


On Wed, Apr 20, 2016 at 12:19 PM, Matthias Wessendorf <[hidden email]> wrote:
Hi,

the format for tokens received from InstanceID API have a slightly different format:

It's basically (prefix_string : RegistrationID).

Now, in order to be able to subscribe on a topic is it _really_ required to have a 'new' InstanceID token ? I could not find a _clear_ statement

looks like InstanceID tokens are required:

But, on the other hand it does not mention that GCM.register() tokens are not allowed :-)
 

I am asking because I'm working on the server hook to send topic request.

If the answer yes, only InstanceID tokens can subscribe, we need a little switch on the server (not a show stopper):
1) send /topics/{something} (should not affect 'old' tokens_
2) fallback: find tokens w/o the ':', so we can fallback to pure registration Id for "non-Instance ID " tokens


Thanks,
Matthias

--



--



--

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev


_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev



--

_______________________________________________
aerogear-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/aerogear-dev