Method: Pushr::Daemon::GcmSupport::ConnectionGcm#write
- Defined in:
- lib/pushr/daemon/gcm_support/connection_gcm.rb
#write(data) ⇒ Object
24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/pushr/daemon/gcm_support/connection_gcm.rb', line 24 def write(data) retry_count = 0 begin response = notification_request(data.) handle_response(response, data, retry_count) rescue GcmError => e raise e rescue => e retry_count += 1 if retry_count < 10 retry else raise e end end end |