Open dipenpatel235 opened 4 years ago
I think it's a silly bug that can be ignored.
If you look closely you can see that Google does return a 200 OK response, so all should be fine.
Do you receive the push notification?
Do you receive the push notification? - No. not received push notification also.
Hi guys,
I can confirm I have the exact same bug in my tests. Running a fresh Flexisip 2.0 beta installation on Debian 9.
Apple's push notifications work fine, while Google's firebase push notification has the bug that @dipenpatel235 describes above. Even though the Flexisip logs show that Google does at first reply with 200 OK, afterwards it replies with the "Invalid server response: Unexpected HTTP response value (not 200 OK)" message and the client device DOES NOT get woken up.
@fgrisez can you confirm on your end that this is a known bug?
I stand corrected. Sometimes it seems the pushes do work even though the flexisip logs show the error mentioned above. Other times the push notification never seems to arrive at the client device.
Doing some digging I think the reason for this strange behaviour is that FCM has upgraded to a newer version, 1, as detailed here https://firebase.google.com/docs/cloud-messaging/migrate-v1
Looking at the flexisip code it seems to still use the legacy version even though the http headers seem to imply it is using v1. I presume this mismatch is the reason for the buggy behavior, but only belledonne can confirm if this is the case.
Looking through the source code it seems confirmed that flexisip is using only legacy FCM, which could explain the buggy behavior since Google is pushing companies to migrate to the the newer v1.
See Below Pushnotification error log. so push notification sent successfully but HTTP error 200 Not Ok. thats why mobile app is not wakeup.
it is work with few devices and not working with few devices. so not getting idea where is issue in response of Pushnotification related error.