You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
when i create a new client,how can i check health of it ?
In Apple Privider Api Doc, it said: "You can check the health of your connection using an HTTP/2 PING frame." In your "Push" fuction, you said:
"If the underlying http.Client is not currently connected, this method will attempt to reconnect transparently before sending the notification."
so, did i need do something else to keep alive of the connetion?
The text was updated successfully, but these errors were encountered:
Because we use the higher level HTTP Client which is designed to abstract the complexity of the underlying HTTP/2 connection and make it look like standard HTTP, currently there is no way to check the health of a connection.
That said, If you init a apns2.Client and hold on to it, it will stay open until something happens (network connection drops etc). In the advent that it does drop, it would just transparently re-connect the next time you call Push() and stay open again.
Theoretically you could do this if you dropped down to using x/net/http2 ping frames etc, but we haven't yet needed to do so. Just keeping a handle on the apns2.Client should be sufficient.
when i create a new client,how can i check health of it ?
In Apple Privider Api Doc, it said: "You can check the health of your connection using an HTTP/2 PING frame." In your "Push" fuction, you said:
"If the underlying http.Client is not currently connected, this method will attempt to reconnect transparently before sending the notification."
so, did i need do something else to keep alive of the connetion?
The text was updated successfully, but these errors were encountered: