Pigeon v1.1.1 Pigeon.Configurable protocol View Source
Link to this section Summary
Functions
Returns whether connection should reconnect if dropped
Schedules connection ping if necessary
Returns worker name for config
Link to this section Types
Link to this section Functions
Returns whether connection should reconnect if dropped.
Examples
iex> reconnect?(%Pigeon.APNS.Config{reconnect: true})
true
iex> reconnect?(%Pigeon.FCM.Config{}) # always false
false
Schedules connection ping if necessary.
Examples
iex> schedule_ping(%Pigeon.APNS.Config{ping_period: 2})
iex> receive do
...> :ping -> "Got ping!"
...> after
...> 5000 -> "No ping received."
...> end
"Got ping!"
iex> schedule_ping(%Pigeon.FCM.Config{})
iex> receive do
...> :ping -> "Got ping!"
...> after
...> 5000 -> "No ping received."
...> end
"No ping received."