Sometimes push notifications don't come

0 votes
Hello there!
 
I have downloaded example with push notification service and have built it.
 
If application is open or just working in background I can get push notification, but sometimes it does not come.
 
Moreover I can't get notification when application is closed.
 
How do I fix it?
asked Jun 23, 2016 in Announcements by xerolp933 (22 points)

1 Answer

0 votes

Hi Xero,

Greetings!!!!!!

Sometime there may be a delay form Google side, so you can receive the same after a time interval.

We have recently updated our sample application with following enhancements.

  • You will be able to send extra data as Json format.
  • You can also configure for No notification in Bar if application is opened.
  • It will be able to show Notification if application is fully closed.

Please download latest Unity Push Sample.

Let me know if you have any queries regarding this.

Thanks

Vishnu Garg

 

 

answered Jun 24, 2016 by Vishnu Garg (674 points)
I have downloaded the sample project and have built an app again. When app is open then I can get the notification, but if it's closed then I can't. So nothing has changed.
Here is my manifest, maybe it's wrong or something.. http://pastebin.com/pinLkKXJ
the bundle identifier is "com.pushgame.game"
Can you share the logcat logs of Android application. If you are getting the Push when app is open then AndroidManifest.xml is fine.
I opened the app, pressed the button to send push for all users and then I received the push notification and then I closed the app.
here is the link
http://puu.sh/pEhM6/16bbdaf63b.txt
So how you are sending Push again when application is closed.
in AppHQ.
By the way the notification comes after a while so that I can push the button and close the app at once and then just wait for the notification, but again - it never comes if app is closed
Will you please share the logcat logs only when application is closed and sent notification from AppHQ
I started log, then went to AppHQ and sent the push notification. After that I was waiting 3 minutes and then the Push Logs said that message was successfully sent. After that I was waiting for 5 minutes and then stopped the log.
here is the link
http://puu.sh/pEj1T/c3f145bff5.txt
btw I logged only messages that Unity sends
here is full log, I did all the same - closed app, sent message, was waiting while Push Logs said that message was sent successfully and then was waiting for 5 minutes

http://puu.sh/pEjEj/e52d002d89.txt
Hey are u using Application.quit for closing the application or just closing the same using backbutton.Please open the example using Project not by using the UnityPackage.
I have tested the same and its working my side when application is closed.
I use some kind of backbutton.
I opened the example by using Project and not by the UnityPackage.
I have checked my app on another android device and the push notification does not come to that device too. So the problem is in my apk.
As you said - you can get the push notification when app is closed, so could you share your apk?
Please send me API,Secret and Google Project No so that I can share the same application with you. Or can replace the plugin folder with
http://cdn.shephertz.com/repository/files/1236b99b5930a6d469c4a1dd426d380e3875b8a9b1947177ab0cf813225ee234/792f53b56cba8a17fdf793cd721c3d62d2df140a/Plugin.zip
api key 44ed7160338675e020ba9170245be9b01551a6dd1b5223189f858c6a3e34c29e
secret key
29913616ab8826c24743787ecc8516cb4e49f3573265b78a625f993dbc7632a6
google no
938115766942
Please try with replacing the Plugin folder and make necessary changes in PushSample.cs file mean while I am sharing the the Android application. Download it from Drop-Box here is the link
https://www.dropbox.com/s/5fm2qt9jnjkcpl1/Client_Push_Test.apk?dl=0
Hi Vishnu,

As mentioned in your first comment to this question:

"We have recently updated our sample application with following enhancements.

You will be able to send extra data as Json format.
You can also configure for No notification in Bar if application is opened.
It will be able to show Notification if application is fully closed."

I downloaded the latest Unity Sample and checked the code but did not find the code for above three points. Can you please let me know the methods to be used for these three functionality ?

Thanks in advance
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...