Vortex: make GCM response supports multicast

Review Request #440 — Created May 18, 2016 and submitted

tardypad
Lunr
push_notification_response_multicast_gcm
lunr
Vortex: make GCM response supports multicast

unit tests

  • 0
  • 0
  • 2
  • 1
  • 3
Description From Last Updated
tardypad
pprkut
  1. 
      
  2. src/Lunr/Vortex/GCM/GCMResponse.php (Diff revision 2)
     
     

    I don't understand this comment

    1. https://developers.google.com/cloud-messaging/http-server-ref#interpret-downstream
      We are normally suppose to update the endpoint token internally in case GCM return us a registration_id field
      But this is out of scope for now
      This is just a reminder, not to forget that we can get this information there

  3. src/Lunr/Vortex/GCM/GCMResponse.php (Diff revision 2)
     
     
     
     
     
     

    retry later is what PushNotificationStatus::TEMPORARY_ERROR is about

    1. https://developers.google.com/cloud-messaging/http-server-ref#table4
      Basically Google says "there is an error, you should probably retry later"
      Not sure where to make the distinction "error" vs "temporary error" here
      I can only try to make it individually per endpoint when it sends back a message description
      Not with just the HTTP code, and that documentation

    2. I get that. All I was saying is that we have "suggestions" to retry later also in other response objects (MPNS, at least).
      The idea is to return a TEMPORARY_ERROR for all endpoints that should be retried later, and then the application can implement the retry logic based on that.

    3. Here is the doc of GCM regarding this

      Errors in the 500-599 range (such as 500 or 503) indicate that there was an internal error in the GCM connection server while trying to process the request, or that the server is temporarily unavailable (for example, because of timeouts). Sender must retry later, honoring any Retry-After header included in the response. Application servers must implement exponential back-off.
      

      Let's say I mark all the endpoints status as TEMPORARY_ERROR, the application logic can retry them but not using those headers and methods
      Maybe it's not a problem...

  4. 
      
tardypad
smillernl
  1. Ship It!
  2. 
      
pprkut
  1. 
      
  2. you say 12, but there are 13 "error"s under "results"

  3. 
      
tardypad
Review request changed

Status: Closed (submitted)

Loading...