Closed mwkirk closed 11 years ago
From liu4ze4h...@gmail.com on November 09, 2012 04:01:35 i have incounter the same problem !! when i send fast it tell me succeessful but nothing on the device
From ki...@crispygam.es on November 20, 2012 22:28:46 We are having same issue. Everything is going well but nothing on device. Any ideas on how to debug this.
From so...@schantz.com on November 21, 2012 14:26:15 We have the same issue, seems to be a java 1.7 issue. Are you using java 7 ?
From cr...@fancred.com on December 21, 2012 01:32:38 Works fine for me on 1.7.0_10 x64 on Linux.
From norbert....@gmail.com on February 02, 2013 23:03:04 I have the same prob, sent successfully but not getting anything on device.
From sype...@gmail.com on February 05, 2013 19:27:30 Please follow the Troubleshooting Guide and report any issue that arises:
From sype...@gmail.com on March 01, 2013 17:38:45 Closing for lack of feedback from original poster.
Original author: rahu1...@gmail.com (October 31, 2012 11:02:24)
Hi all,
I tried using javapns as follows : Issue : Nothing came on the device.!
Code:
private static String certificate = "path_to_cer/Certificates.p12"; private static String passwd = "*****"; private static String deviceToken = "00000000000000000000000000";
Push.alert("Push!", certificate, passwd, false, deviceToken); PushNotificationPayload payLoad = new PushNotificationPayload(); try { payLoad.addAlert("Push!!"); payLoad.addBadge(10); } catch (JSONException e) { // TODO Auto-generated catch block e.printStackTrace(); }
Log:
0 [main] DEBUG javapns.notification.Payload - Adding alert [Push!] 499 [main] DEBUG javapns.communication.ConnectionToAppleServer - Creating SSLSocketFactory 523 [main] DEBUG javapns.communication.ConnectionToAppleServer - Creating SSLSocket to gateway.sandbox.push.apple.com:2195 1338 [main] DEBUG javapns.notification.PushNotificationManager - Initialized Connection to Host: [gateway.sandbox.push.apple.com] Port: [2195]: 44050988[SSL_NULL_WITH_NULL_NULL: Socket[addr=gateway.sandbox.push.apple.com/17.149.34.66,port=2195,localport=59635]] 1340 [main] DEBUG javapns.notification.PushNotificationManager - Building Raw message from deviceToken and payload 1341 [main] DEBUG javapns.notification.PushNotificationManager - Built raw message ID 1 of total length 74 1341 [main] DEBUG javapns.notification.PushNotificationManager - Attempting to send notification: {"aps":{"alert":"Push!"}} 1341 [main] DEBUG javapns.notification.PushNotificationManager - to device: 40245253e43864cf112d4589e3db8aafee931bf8ea394516b87a33b6acfddbe1 2175 [main] DEBUG javapns.notification.PushNotificationManager - Flushing 2175 [main] DEBUG javapns.notification.PushNotificationManager - At this point, the entire 74-bytes message has been streamed out successfully through the SSL connection 2175 [main] DEBUG javapns.notification.PushNotificationManager - Notification sent on first attempt 2175 [main] DEBUG javapns.notification.PushNotificationManager - Reading responses 7180 [main] DEBUG javapns.notification.PushNotificationManager - Closing connection 7180 [main] DEBUG javapns.notification.Payload - Adding alert [Push!!] 7180 [main] DEBUG javapns.notification.Payload - Adding badge [10] BUILD SUCCESSFUL (total time: 7 seconds)
Thanks in advance..
Happy coding
Original issue: http://code.google.com/p/javapns/issues/detail?id=153