-
Notifications
You must be signed in to change notification settings - Fork 364
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Errno::ECONNRESET, Connection reset by peer after a few minutes when using apns2 #607
Comments
Hey @favrik! Sadly I am not a user of the APNs part of the code base, so I'm afraid I cannot directly help out. But since version 5.0.0 that you are using there have been quite some APNs fixes, see the CHANGELOG.md for more details as well as the commits since the last release. It would help to figure out if this behavior still exists in the latest version. |
Thank you @aried3r ! Just remembered we tested up to 5.2.0, but will test with latest version, and see if I'm able to reproduce. |
this is a duplicate of #538 |
Hi @CR4567 and @benlangfeld ! the experience has been similar, in the sense that a notification can fail for a device that was successful previously, or is successful afterwards. However, I'm not sure how the longer stack trace at #538 was produced (I might ask on the issue later). We could close as duplicate, the main difference I'm seeing is that I'm able to reproduce every time, seems the current magic number is 13 minutes, so I would send a notification to a device, wait 13 minutes, and then submit again and get an I've been testing apnotic, where I get the error as a When reading rpush code, where either the Once I get more details, I'll update this issue, and/or the other one. Thanks!! |
I experience this issue but it mostly appeared when during the off-peak hours when my Rpush server is idle. During peak time, I'm sending tens of thousands of notifications to Apnd2 over 256 connections. When I increase the number of connections to Apns2 to 512 I saw that happened more. Based on these observations, I suspect Apple is closing the socket on the Apn2 without explicitly telling the developers what is the limit in the Apple Developer documentation. @favrik and others, what is the number connection specified in your config/initializers/rpush.rb file? |
This is still a problem, any clue/suggestions on how to resolve it ?! |
+1 |
Hello!,
have you seen anything like this before? I've searched through the issues, and the ones that are similar are marked as "Stale".
Updated rpush version to 5.2.0, the updates in latest versions seem to be unrelated
Describe the bug
We recently switched to rpush 5.2.0 in order to use apns2 due to the binary protocol coming to end of life. I'm not sure if this is a bug, but we are getting the following error between successful IOS push notifications:
To Reproduce
Steps to reproduce the behavior:
(note: we start rpush with
bundle exec rpush start -f -e <env>
)This is the code we are using to send a push notification:
Expected behavior
We don't get a connection reset, or the notification is retried successfully
Logs and other output
System configuration (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: