Open emimarz opened 8 years ago
I also experienced this issue while using another PHP APNS library (wrapper to a C library actually) https://github.com/adobkin/php-apn I was trying to send a notification a 1000 times to the same recipient and it stopped exactly the same way at the 600th (status code 8 "invalid token" too) My guess is that this is a restriction on the Apple side itself then. I just saw this now as well http://stackoverflow.com/questions/34216006/apns-valid-token-receives-error-message.
ok, I will try to explain this bug I get the sample push to many and change it with my data so, I send 1000 push to one device then I found this Tue, 13 Oct 2015 16:53:52 +0200 ApnsPHP[27994]: STATUS: Sending message ID 608 custom identifier: unset: 66 bytes. Tue, 13 Oct 2015 16:53:52 +0200 ApnsPHP[27994]: STATUS: Sending message ID 609 custom identifier: unset: 66 bytes. Tue, 13 Oct 2015 16:53:52 +0200 ApnsPHP[27994]: STATUS: Sending message ID 610 custom identifier: unset: 66 bytes. Tue, 13 Oct 2015 16:53:52 +0200 ApnsPHP[27994]: ERROR: Unable to send message ID 600: Invalid token (8). Tue, 13 Oct 2015 16:53:52 +0200 ApnsPHP[27994]: INFO: Disconnected. Tue, 13 Oct 2015 16:53:52 +0200 ApnsPHP[27994]: INFO: Trying tls://gateway.push.apple.com:2195... Tue, 13 Oct 2015 16:53:53 +0200 ApnsPHP[27994]: INFO: Connected to tls://gateway.push.apple.com:2195. Tue, 13 Oct 2015 16:53:53 +0200 ApnsPHP[27994]: INFO: Sending messages queue, run #2: 401 message(s) left in queue. Tue, 13 Oct 2015 16:53:53 +0200 ApnsPHP[27994]: WARNING: Message ID 600 [custom identifier: unset] has an unrecoverable error (8), removing from queue without retrying... Tue, 13 Oct 2015 16:53:53 +0200 ApnsPHP[27994]: STATUS: Sending message ID 601 custom identifier: unset: 66 bytes. Tue, 13 Oct 2015 16:53:53 +0200 ApnsPHP[27994]: STATUS: Sending message ID 602 custom identifier: unset: 66 bytes.
remember, all push are sending to the same device so is a valid device id I don't understand why push 600 can't be sent if I change setWriteInterval to 0 more errors appear but all was sent also number 600 if I increment setWriteInterval always give me that error
Could you help me with this bug? thanks in advance