替换生产推送证书后后台报错
SimplePushNotificationResponse{pushNotification=SimpleApnsPushNotification{token='27c8b93b3dc4e0ea9b490e43fcca8f103ea9325d1379e37f1295462e6c7ea8e5', payload='{"data":{"pushTime":"1574239455819","content":"{"caseid":"8344fd132de139b0","type":"2","sendnick":"lvluo865","content":"陌陌我摸哦哟哟哦哟走咯哦哦吐了垃圾垃圾咯啦里叽叽叽叽进攻ing民工hi里logo红你会你会你来家叽叽叽叽理解里叽叽叽叽楼KKKKK叽叽叽叽理解叽叽叽叽理解啦咯啦咯啦咯啦咯K咯监控考虑考虑咯哦哦OK了咯某KKK哦吐了来咯哦吐了咯啦咯","pushType":"901","littleiconkey":"http://192.168.100.202:8080/file/download?fileId=5d491e51296cc968d3dd6f4e"}"},"aps":{"badge":1,"alert":{"body":"您收到一条新消息","title":"收到新的留言"}}}', invalidationTime=Thu Nov 21 16:44:15 CST 2019, priority=IMMEDIATE, topic='com.wed;ad', collapseId='null', apnsId=null}, success=false, apnsId=c273e054-fe6b-7bd9-6ec9-92f25435a35e, rejectionReason='BadDeviceToken', tokenExpirationTimestamp=null}
经测试,生产证书没有问题。
关于证书设置的问题,请看这篇文章 苹果APNS证书创建
最后经后台查证,发现是其 推送时,指定的环境为开发环境,并不是生产。所以生产环境提示bad devicetoken.
网友评论