linphone-iphone icon indicating copy to clipboard operation
linphone-iphone copied to clipboard

When app is sleep or idle, can not ring at first time.

Open ivylee1108 opened this issue 7 years ago • 8 comments

I build the latest code of linphone and use our self's sip push server to send voip push notification. When app enter background mode for a while, the app can not ring; it don't receive linphone_iphone_call_state callback and will not call reportIncomingCallwithUUID to show incoming call screen of call kit. But if call again, linphone_iphone_call_state will be call and can ring normally. To check the log, app really receive didReceiveIncomingPushWithPayload, but the linphone_iphone_call_state callback does't call. Refers to the solution in https://github.com/BelledonneCommunications/linphone-iphone/issues/258, but still can't resolve my issue.

My Log: 2017-08-14 18:12:49:828 MESSAGE Ring MSTicker priority set to SCHED_RR and value (47) 2017-08-14 18:12:49:853 MESSAGE (honeAppDelegate.m:341 ) app launched with state : 2 2017-08-14 18:12:49:853 MESSAGE (honeAppDelegate.m:342 ) FINISH LAUNCHING WITH OPTION : (null) 2017-08-14 18:12:49:905 MESSAGE (honeAppDelegate.m:628 ) PushKit credentials updated 2017-08-14 18:12:49:905 MESSAGE (honeAppDelegate.m:629 ) voip token: <a0cbb264 ca6aff29 e8f06bbb b110d52e 4cecbeb6 98ebb2c4 1879c7cc 983471b9> 2017-08-14 18:12:49:905 MESSAGE (honeAppDelegate.m:543 ) PushKit : incoming voip notfication: { aps = { alert = { "loc-args" = ( M2906, "08/14 18:12" ); "loc-key" = "Incoming call"; }; badge = 1; sound = "ringtone.wav"; }; } 2017-08-14 18:12:49:908 MESSAGE (LinphoneManager.m:1689) Network connection flags: kSCNetworkReachabilityFlagsTransientConnection, kSCNetworkReachabilityFlagsReachable, kSCNetworkReachabilityFlagsIsWWAN, 2017-08-14 18:12:49:908 MESSAGE SIP network reachability state is now [UP] 2017-08-14 18:12:49:908 MESSAGE Media network reachability state is now [UP] 2017-08-14 18:12:49:908 MESSAGE Starting stun server resolution [stun.linphone.org] 2017-08-14 18:12:49:909 MESSAGE Resolver is using DNS server(s): 2017-08-14 18:12:49:909 MESSAGE 168.95.1.1 2017-08-14 18:12:49:909 MESSAGE 168.95.192.1 2017-08-14 18:12:49:909 MESSAGE resolver_process_data dns_res_check() in progress 2017-08-14 18:12:49:909 MESSAGE DNS resolution awaiting response, queued to main loop 2017-08-14 18:12:49:910 MESSAGE LinphoneProxyConfig [0x10250f340] about to register (LinphoneCore version: 3.12.0-37-g3c446b769) 2017-08-14 18:12:49:914 MESSAGE Background task belle-sip transaction(0x17016f180) started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:49:914 MESSAGE transaction [0x17016f180]: starting transaction background task with id=[3]. 2017-08-14 18:12:49:914 MESSAGE belle_sip_client_transaction_send_request(): waiting channel to be ready 2017-08-14 18:12:49:916 MESSAGE Background task belle-sip send channel started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:49:916 MESSAGE channel [0x1027ac000]: starting send background task with id=[4]. 2017-08-14 18:12:49:916 MESSAGE channel [0x1027ac000]: starting resolution of 210.63.100.188 2017-08-14 18:12:49:916 MESSAGE channel 0x1027ac000: state RES_IN_PROGRESS 2017-08-14 18:12:49:917 MESSAGE transaction [0x17016f180] channel state changed to [RES_IN_PROGRESS] 2017-08-14 18:12:49:917 MESSAGE channel 0x1027ac000: state RES_DONE 2017-08-14 18:12:49:917 MESSAGE transaction [0x17016f180] channel state changed to [RES_DONE] 2017-08-14 18:12:49:917 MESSAGE channel 0x1027ac000: state CONNECTING 2017-08-14 18:12:49:917 MESSAGE transaction [0x17016f180] channel state changed to [CONNECTING] 2017-08-14 18:12:49:917 MESSAGE Trying to connect to [TLS://::ffff:210.63.100.188:5068] 2017-08-14 18:12:49:924 MESSAGE Neither Expires header nor corresponding Contact header found, checking from original request 2017-08-14 18:12:49:924 MESSAGE Refresher [0x170141ef0] takes ownership of transaction [0x17016f180] 2017-08-14 18:12:49:924 MESSAGE Proxy config [0x10250f340] for identity [sip:[email protected]:5068] moving from state [LinphoneRegistrationNone] to [LinphoneRegistrationProgress] on core [0x10281bc00] 2017-08-14 18:12:49:924 MESSAGE (LinphoneManager.m:1067) New registration state: LinphoneRegistrationProgress (message: Registration in progress) 2017-08-14 18:12:49:940 MESSAGE Linphone core [0x10281bc00] notified [registration_state_changed] 2017-08-14 18:12:49:940 MESSAGE (LinphoneManager.m:1758) Network connectivity changed to type [wwan] 2017-08-14 18:12:49:940 WARNING ( Utils.m:452 ) +[LinphoneUtils deviceModelIdentifier]: Oops, unknown machine iPhone9,4... consider completing me! 2017-08-14 18:12:49:962 DEBUG (FastAddressBook.m:147 ) CNContactStore successfully synchronized 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: url. 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: utc. 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: appdata. 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: content. 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: key_size. 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: messageId 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: content_type 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: is_secured 2017-08-14 18:12:49:964 MESSAGE Table already up to date: duplicate column name: call_id. 2017-08-14 18:12:49:966 MESSAGE linphone_core_get_call_history(): completed in 1 ms 2017-08-14 18:12:49:966 WARNING nothing to migrate, skipping... 2017-08-14 18:12:49:966 MESSAGE (LinphoneManager.m:1777) Cancelling old network reachability 2017-08-14 18:12:49:966 MESSAGE (LinphoneManager.m:1689) Network connection flags: kSCNetworkReachabilityFlagsTransientConnection, kSCNetworkReachabilityFlagsReachable, kSCNetworkReachabilityFlagsIsWWAN, 2017-08-14 18:12:49:967 MESSAGE (LinphoneManager.m:1908) Using '/var/containers/Bundle/Application/9BEC9899-AF85-47AD-B281-6FF91742DC26/linphone.app/nowebcamCIF.jpg' as source image for no webcam 2017-08-14 18:12:49:967 MESSAGE (LinphoneManager.m:1920) Setting default camera [AV Capture: com.apple.avfoundation.avcapturedevice.built-in_video:1] 2017-08-14 18:12:49:967 MESSAGE (LinphoneManager.m:1943) Linphone [3.12.0-37-g3c446b769] started on [iPhone] 2017-08-14 18:12:49:983 MESSAGE Channel [0x1027ac000]: Connected at TCP level, now doing TLS handshake with cname=210.63.100.188 2017-08-14 18:12:49:983 MESSAGE Channel [0x1027ac000]: SSL handshake in progress... 2017-08-14 18:12:49:983 MESSAGE (LinphoneManager.m:2862) Proxy config sip:[email protected]:5068 NOT configured for push notifications 2017-08-14 18:12:49:984 MESSAGE linphone_proxy_config_is_server_config_changed : 1 2017-08-14 18:12:49:984 MESSAGE Refresher [0x170141ef0] stopped. 2017-08-14 18:12:49:984 MESSAGE Changing [client] [REGISTER] transaction [0x17016f180], from state [INIT] to [TERMINATED] 2017-08-14 18:12:49:984 MESSAGE Client internal REGISTER transaction [0x17016f180] terminated 2017-08-14 18:12:49:984 MESSAGE transaction [0x17016f180]: ending transaction background task with id=[3]. 2017-08-14 18:12:49:984 MESSAGE Publish params have not changed on proxy config [0x10250f340] 2017-08-14 18:12:49:984 MESSAGE (honeAppDelegate.m:484 ) Notification { aps = { alert = { "loc-args" = ( M2906, "08/14 18:12" ); "loc-key" = "Incoming call"; }; badge = 1; sound = "ringtone.wav"; }; } processed 2017-08-14 18:12:49:986 MESSAGE ( Contact.m:81 ) Contact Connie initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:986 MESSAGE ( Contact.m:81 ) Contact Karen initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:986 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:987 MESSAGE ( Contact.m:81 ) Contact Wyatt initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:987 MESSAGE ( Contact.m:81 ) Contact Naly initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:987 MESSAGE ( Contact.m:81 ) Contact Frye initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:987 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:987 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:988 MESSAGE ( Contact.m:81 ) Contact Doris initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:991 MESSAGE ( Contact.m:81 ) Contact liao Alice initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:991 MESSAGE ( Contact.m:81 ) Contact Calvin initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:991 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:992 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:992 MESSAGE ( Contact.m:81 ) Contact KLASH initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:998 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:998 MESSAGE ( Contact.m:81 ) Contact PIN initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:998 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:998 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:999 MESSAGE ( Contact.m:81 ) Contact Laya initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:49:999 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:999 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:999 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:49:999 MESSAGE ( Contact.m:81 ) Contact Zoe initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:000 MESSAGE ( Contact.m:81 ) Contact Chase initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:000 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:000 MESSAGE ( Contact.m:81 ) Contact Dd initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:000 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:001 MESSAGE ( Contact.m:81 ) Contact Cherry initialized with 2 phones, 0 sip, 0 emails 2017-08-14 18:12:50:001 MESSAGE ( Contact.m:81 ) Contact Landlord initialized with 2 phones, 0 sip, 0 emails 2017-08-14 18:12:50:001 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:001 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:001 MESSAGE ( Contact.m:81 ) Contact Mayuki initialized with 2 phones, 0 sip, 0 emails 2017-08-14 18:12:50:002 MESSAGE ( Contact.m:81 ) Contact Tommy initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:002 MESSAGE ( Contact.m:81 ) Contact Ivy Su initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:002 MESSAGE ( Contact.m:81 ) Contact Yiyo initialized with 2 phones, 0 sip, 0 emails 2017-08-14 18:12:50:002 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:002 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:002 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:002 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:003 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:003 MESSAGE ( Contact.m:81 ) Contact Richard initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:003 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:003 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:003 MESSAGE ( Contact.m:81 ) Contact Wei initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:003 MESSAGE ( Contact.m:81 ) Contact Linsu initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:003 MESSAGE ( Contact.m:81 ) Contact Joy initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:004 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:004 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:004 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:004 MESSAGE ( Contact.m:81 ) Contact .Bai JY initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:005 MESSAGE ( Contact.m:81 ) Contact Hank initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:005 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:005 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:005 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:006 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:006 MESSAGE ( Contact.m:81 ) Contact Happy Hair Miyake initialized with 2 phones, 0 sip, 0 emails 2017-08-14 18:12:50:006 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:006 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:006 MESSAGE ( Contact.m:81 ) Contact Tom initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:007 MESSAGE ( Contact.m:81 ) Contact Jorden initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:007 MESSAGE ( Contact.m:81 ) Contact Ted initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:007 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:008 MESSAGE ( Contact.m:81 ) Contact Elvis initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:008 MESSAGE ( Contact.m:81 ) Contact lab initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:008 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:008 MESSAGE ( Contact.m:81 ) Contact Jerry initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:009 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:009 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:009 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:009 MESSAGE ( Contact.m:81 ) Contact AMY initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:009 MESSAGE ( Contact.m:81 ) Contact chen 1B initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:009 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:010 MESSAGE ( Contact.m:81 ) Contact Lin Vicky-acer initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:010 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:010 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:010 MESSAGE ( Contact.m:81 ) Contact jay initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:011 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:011 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:011 MESSAGE ( Contact.m:81 ) Contact Akino initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:011 MESSAGE ( Contact.m:81 ) Contact Ken initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:011 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:011 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:012 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:012 MESSAGE ( Contact.m:81 ) Contact Eric initialized with 1 phones, 0 sip, 1 emails 2017-08-14 18:12:50:012 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:012 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:012 MESSAGE ( Contact.m:81 ) Contact Twingo initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:012 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:013 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:013 MESSAGE ( Contact.m:81 ) Contact Test initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:013 MESSAGE ( Contact.m:81 ) Contact Kimberly initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:013 MESSAGE ( Contact.m:81 ) Contact WU ALICE initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:013 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:013 MESSAGE ( Contact.m:81 ) Contact Bryan initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:014 MESSAGE ( Contact.m:81 ) Contact 1b initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:014 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:014 MESSAGE ( Contact.m:81 ) Contact Blue initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:014 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:014 MESSAGE ( Contact.m:81 ) Contact Paul initialized with 1 phones, 0 sip, 1 emails 2017-08-14 18:12:50:014 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:015 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:015 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:015 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:015 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:015 MESSAGE ( Contact.m:81 ) Contact Jacqueline initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:016 MESSAGE ( Contact.m:81 ) Contact Unique initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:016 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:016 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:016 MESSAGE ( Contact.m:81 ) Contact STONE initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:016 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:016 MESSAGE ( Contact.m:81 ) Contact Evermore initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:016 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:017 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:017 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:017 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:017 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:017 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:017 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:017 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:018 MESSAGE ( Contact.m:81 ) Contact Horus initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:018 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:018 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:018 MESSAGE ( Contact.m:81 ) Contact Josh initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:018 MESSAGE ( Contact.m:81 ) Contact Chase initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:018 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:019 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:019 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:019 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:019 MESSAGE ( Contact.m:81 ) Contact Clark initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:019 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:019 MESSAGE ( Contact.m:81 ) Contact Judy initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:020 MESSAGE ( Contact.m:81 ) Contact Lynn initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:020 MESSAGE ( Contact.m:81 ) Contact 123 Lee initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:020 MESSAGE ( Contact.m:81 ) Contact Ivy Lee initialized with 1 phones, 1 sip, 0 emails 2017-08-14 18:12:50:020 MESSAGE ( Contact.m:81 ) Contact Choey initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:020 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:021 MESSAGE ( Contact.m:81 ) Contact Test Stanly initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:021 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:021 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:021 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:022 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:022 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:022 MESSAGE ( Contact.m:81 ) Contact HC initialized with 0 phones, 0 sip, 0 emails 2017-08-14 18:12:50:022 MESSAGE ( Contact.m:81 ) Contact 123 qer initialized with 1 phones, 1 sip, 0 emails 2017-08-14 18:12:50:023 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:023 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:023 MESSAGE ( Contact.m:81 ) (null) 2017-08-14 18:12:50:023 MESSAGE ( Contact.m:81 ) Contact test server initialized with 1 phones, 0 sip, 0 emails 2017-08-14 18:12:50:023 MESSAGE ( Contact.m:81 ) Contact # Whoscall Database Update Time # initialized with 0 phones, 0 sip, 0 emails 2017-08-14 18:12:50:023 MESSAGE Friends list [0x170161980] subscription update skipped since subscriptions not enabled yet 2017-08-14 18:12:50:024 MESSAGE Found certificate depth=[0], flags=[CN-mismatch not-trusted ]: cert. version : 1 serial number : 01 issuer name : C=TW, ST=Taiwan, L=Taipei, O=CHT, OU=TL, CN=10.144.169.210, [email protected] subject name : C=TW, ST=Taiwan, L=Taipei, O=CHT, OU=TL, CN=cs210 issued on : 2015-04-22 08:59:10 expires on : 2025-04-19 08:59:10 signed using : RSA with SHA1 RSA key size : 1024 bits

2017-08-14 18:12:50:024 WARNING Certificate verification bypassed (requested by application). 2017-08-14 18:12:50:025 MESSAGE Channel [0x1027ac000]: SSL handshake in progress... 2017-08-14 18:12:50:025 MESSAGE SRV _stun._udp.stun.linphone.org resolved to [target:stun.linphone.org. port:3478 prio:0 weight:100] 2017-08-14 18:12:50:025 MESSAGE SRV _stun._udp.stun.linphone.org resolved to [target:sip1.linphone.org. port:3478 prio:10 weight:100] 2017-08-14 18:12:50:025 MESSAGE Starting A/AAAA query for srv result [stun.linphone.org.] 2017-08-14 18:12:50:025 MESSAGE Resolver is using DNS server(s): 2017-08-14 18:12:50:025 MESSAGE 168.95.1.1 2017-08-14 18:12:50:026 MESSAGE 168.95.192.1 2017-08-14 18:12:50:026 MESSAGE resolver_process_data dns_res_check() in progress 2017-08-14 18:12:50:026 MESSAGE DNS resolution awaiting response, queued to main loop 2017-08-14 18:12:50:026 MESSAGE Resolver is using DNS server(s): 2017-08-14 18:12:50:026 MESSAGE 168.95.1.1 2017-08-14 18:12:50:026 MESSAGE 168.95.192.1 2017-08-14 18:12:50:026 MESSAGE resolver_process_data dns_res_check() in progress 2017-08-14 18:12:50:026 MESSAGE DNS resolution awaiting response, queued to main loop 2017-08-14 18:12:50:026 MESSAGE Starting A/AAAA query for srv result [sip1.linphone.org.] 2017-08-14 18:12:50:027 MESSAGE Resolver is using DNS server(s): 2017-08-14 18:12:50:027 MESSAGE 168.95.1.1 2017-08-14 18:12:50:027 MESSAGE 168.95.192.1 2017-08-14 18:12:50:027 MESSAGE resolver_process_data dns_res_check() in progress 2017-08-14 18:12:50:027 MESSAGE DNS resolution awaiting response, queued to main loop 2017-08-14 18:12:50:028 MESSAGE Resolver is using DNS server(s): 2017-08-14 18:12:50:028 MESSAGE 168.95.1.1 2017-08-14 18:12:50:028 MESSAGE 168.95.192.1 2017-08-14 18:12:50:028 MESSAGE resolver_process_data dns_res_check() in progress 2017-08-14 18:12:50:028 MESSAGE DNS resolution awaiting response, queued to main loop 2017-08-14 18:12:50:028 MESSAGE LinphoneProxyConfig [0x10250f340] about to register (LinphoneCore version: 3.12.0-37-g3c446b769) 2017-08-14 18:12:50:028 MESSAGE Refresher [0x170141ef0] stopped. 2017-08-14 18:12:50:028 MESSAGE Destroying op [0x102555060] of type [SalOpRegister] 2017-08-14 18:12:50:028 MESSAGE Refresher [0x170141ef0] stopped. 2017-08-14 18:12:50:028 MESSAGE Transaction [0x17016f180] deleted 2017-08-14 18:12:50:029 MESSAGE Background task belle-sip transaction(0x174168d00) started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:029 MESSAGE transaction [0x174168d00]: starting transaction background task with id=[5]. 2017-08-14 18:12:50:029 MESSAGE Neither Expires header nor corresponding Contact header found, checking from original request 2017-08-14 18:12:50:029 MESSAGE Refresher [0x17414a710] takes ownership of transaction [0x174168d00] 2017-08-14 18:12:50:068 MESSAGE sip1.linphone.org. resolved to 91.121.209.194 2017-08-14 18:12:50:068 MESSAGE Channel [0x1027ac000]: SSL handshake finished, SSL version is [TLSv1.2], selected ciphersuite is [TLS-RSA-WITH-3DES-EDE-CBC-SHA] 2017-08-14 18:12:50:068 MESSAGE Channel has local address 10.230.15.234:64052 2017-08-14 18:12:50:068 MESSAGE channel 0x1027ac000: state READY 2017-08-14 18:12:50:068 MESSAGE transaction [0x174168d00] channel state changed to [READY] 2017-08-14 18:12:50:068 MESSAGE Changing [client] [REGISTER] transaction [0x174168d00], from state [INIT] to [TRYING] 2017-08-14 18:12:50:069 MESSAGE channel [0x1027ac000]: message sent to [TLS://210.63.100.188:5068], size: [611] bytes REGISTER sip:210.63.100.188:5068 SIP/2.0 Via: SIP/2.0/TLS 10.230.15.234:64052;alias;branch=z9hG4bK.gCJSpvI1B;rport From: sip:[email protected];tag=mq0eN7nOU To: sip:[email protected] CSeq: 20 REGISTER Call-ID: GzDlUkS-wk Max-Forwards: 70 Supported: replaces, outbound Accept: application/sdp Accept: text/plain Accept: application/vnd.gsma.rcs-ft-http+xml Contact: sip:[email protected]:64052;transport=tls;+sip.instance="urn:uuid:c0cfe8ba-106d-4857-b639-9ecc8580fec7" Expires: 3600 User-Agent: Linphone_iPhone9.4_iOS10.3.3/3.16.4-94-g8937a2ca (belle-sip/1.6.3) Content-Length: 0

2017-08-14 18:12:50:069 MESSAGE channel [0x1027ac000]: ending send background task with id=[4]. 2017-08-14 18:12:50:108 MESSAGE A query finished for srv result [sip1.linphone.org.] 2017-08-14 18:12:50:108 MESSAGE stun.linphone.org. resolved to 37.59.51.72 2017-08-14 18:12:50:108 MESSAGE A query finished for srv result [stun.linphone.org.] 2017-08-14 18:12:50:108 MESSAGE All A/AAAA results for combined resolution have arrived. 2017-08-14 18:12:50:108 MESSAGE Stun server resolution successful. 2017-08-14 18:12:50:109 MESSAGE Background task belle-sip recv channel started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:109 MESSAGE channel [0x1027ac000]: starting recv background task with id=[6]. 2017-08-14 18:12:50:109 MESSAGE channel [0x1027ac000]: received [404] new bytes from [TLS://210.63.100.188:5068]: SIP/2.0 100 Trying Via: SIP/2.0/TLS 10.230.15.234:64052;alias;branch=z9hG4bK.gCJSpvI1B;received=223.140.7.137;rport=55086 From: sip:[email protected];tag=mq0eN7nOU To: sip:[email protected] Call-ID: GzDlUkS-wk CSeq: 20 REGISTER Server: cs210 Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, UPDATE, PRACK Supported: replaces, timer Content-Length: 0

2017-08-14 18:12:50:114 MESSAGE channel [0x1027ac000] [404] bytes parsed 2017-08-14 18:12:50:114 MESSAGE channel [0x1027ac000]: discovered public ip and port are [223.140.7.137:55086] 2017-08-14 18:12:50:114 MESSAGE Found transaction matching response. 2017-08-14 18:12:50:114 MESSAGE Changing [client] [REGISTER] transaction [0x174168d00], from state [TRYING] to [PROCEEDING] 2017-08-14 18:12:50:114 MESSAGE Register refresher [100] reason [Trying] for proxy [sip:210.63.100.188:5068;transport=tls] 2017-08-14 18:12:50:114 MESSAGE channel [0x1027ac000]: ending recv background task with id=[6]. 2017-08-14 18:12:50:126 MESSAGE Background task belle-sip recv channel started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:126 MESSAGE channel [0x1027ac000]: starting recv background task with id=[7]. 2017-08-14 18:12:50:127 MESSAGE channel [0x1027ac000]: received [498] new bytes from [TLS://210.63.100.188:5068]: SIP/2.0 401 Unauthorized Via: SIP/2.0/TLS 10.230.15.234:64052;alias;branch=z9hG4bK.gCJSpvI1B;received=223.140.7.137;rport=55086 From: sip:[email protected];tag=mq0eN7nOU To: sip:[email protected];tag=as0985dea9 Call-ID: GzDlUkS-wk CSeq: 20 REGISTER Server: cs210 Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, UPDATE, PRACK Supported: replaces, timer WWW-Authenticate: Digest algorithm=MD5, realm="cs210", nonce="7b8f549b" Content-Length: 0

2017-08-14 18:12:50:128 MESSAGE channel [0x1027ac000] [498] bytes parsed 2017-08-14 18:12:50:128 MESSAGE Found transaction matching response. 2017-08-14 18:12:50:128 MESSAGE Changing [client] [REGISTER] transaction [0x174168d00], from state [PROCEEDING] to [COMPLETED] 2017-08-14 18:12:50:128 MESSAGE linphone_core_find_auth_info(): returning auth info username=M2908, realm=210.63.100.188 2017-08-14 18:12:50:128 MESSAGE Auth info found for [M2908] realm [cs210] 2017-08-14 18:12:50:128 MESSAGE Background task belle-sip transaction(0x170362400) started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:128 MESSAGE transaction [0x170362400]: starting transaction background task with id=[8]. 2017-08-14 18:12:50:128 MESSAGE Changing [client] [REGISTER] transaction [0x170362400], from state [INIT] to [TRYING] 2017-08-14 18:12:50:129 MESSAGE channel [0x1027ac000]: message sent to [TLS://210.63.100.188:5068], size: [777] bytes REGISTER sip:210.63.100.188:5068 SIP/2.0 Via: SIP/2.0/TLS 10.230.15.234:64052;alias;branch=z9hG4bK.NKs1Dt90m;rport From: sip:[email protected];tag=mq0eN7nOU To: sip:[email protected] CSeq: 21 REGISTER Call-ID: GzDlUkS-wk Max-Forwards: 70 Supported: replaces, outbound Accept: application/sdp Accept: text/plain Accept: application/vnd.gsma.rcs-ft-http+xml Contact: sip:[email protected]:55086;transport=tls;+sip.instance="urn:uuid:c0cfe8ba-106d-4857-b639-9ecc8580fec7" Expires: 3600 User-Agent: Linphone_iPhone9.4_iOS10.3.3/3.16.4-94-g8937a2ca (belle-sip/1.6.3) Content-Length: 0 Authorization: Digest realm="cs210", nonce="7b8f549b", algorithm=MD5, username="M2908", uri="sip:210.63.100.188:5068", response="882f769d4e218bc7ae28aee3666589b8"

2017-08-14 18:12:50:129 MESSAGE Changing [client] [REGISTER] transaction [0x174168d00], from state [COMPLETED] to [TERMINATED] 2017-08-14 18:12:50:129 MESSAGE Client internal REGISTER transaction [0x174168d00] terminated 2017-08-14 18:12:50:129 MESSAGE transaction [0x174168d00]: ending transaction background task with id=[5]. 2017-08-14 18:12:50:129 MESSAGE channel [0x1027ac000]: ending recv background task with id=[7]. 2017-08-14 18:12:50:182 MESSAGE Background task belle-sip recv channel started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:183 MESSAGE channel [0x1027ac000]: starting recv background task with id=[9]. 2017-08-14 18:12:50:183 MESSAGE channel [0x1027ac000]: received [404] new bytes from [TLS://210.63.100.188:5068]: SIP/2.0 100 Trying Via: SIP/2.0/TLS 10.230.15.234:64052;alias;branch=z9hG4bK.NKs1Dt90m;received=223.140.7.137;rport=55086 From: sip:[email protected];tag=mq0eN7nOU To: sip:[email protected] Call-ID: GzDlUkS-wk CSeq: 21 REGISTER Server: cs210 Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, UPDATE, PRACK Supported: replaces, timer Content-Length: 0

2017-08-14 18:12:50:185 MESSAGE channel [0x1027ac000] [404] bytes parsed 2017-08-14 18:12:50:185 MESSAGE Found transaction matching response. 2017-08-14 18:12:50:198 MESSAGE Changing [client] [REGISTER] transaction [0x170362400], from state [TRYING] to [PROCEEDING] 2017-08-14 18:12:50:198 MESSAGE Register refresher [100] reason [Trying] for proxy [sip:210.63.100.188:5068;transport=tls] 2017-08-14 18:12:50:199 MESSAGE channel [0x1027ac000]: ending recv background task with id=[9]. 2017-08-14 18:12:50:248 MESSAGE Background task belle-sip recv channel started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:248 MESSAGE channel [0x1027ac000]: starting recv background task with id=[a]. 2017-08-14 18:12:50:249 MESSAGE channel [0x1027ac000]: received [536] new bytes from [TLS://210.63.100.188:5068]: SIP/2.0 200 OK Via: SIP/2.0/TLS 10.230.15.234:64052;alias;branch=z9hG4bK.NKs1Dt90m;received=223.140.7.137;rport=55086 From: sip:[email protected];tag=mq0eN7nOU To: sip:[email protected];tag=as0985dea9 Call-ID: GzDlUkS-wk CSeq: 21 REGISTER Server: cs210 Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, UPDATE, PRACK Supported: replaces, timer Expires: 3600 Contact: sip:[email protected]:55086;transport=tls;expires=3600 Date: Mon, 14 Aug 2017 10:12:50 GMT Content-Length: 0

2017-08-14 18:12:50:250 MESSAGE channel [0x1027ac000] [536] bytes parsed 2017-08-14 18:12:50:250 MESSAGE Found transaction matching response. 2017-08-14 18:12:50:250 MESSAGE Changing [client] [REGISTER] transaction [0x170362400], from state [PROCEEDING] to [COMPLETED] 2017-08-14 18:12:50:250 MESSAGE Refresher [0x17414a710]: has no contact for request [0x1700e3d80]. 2017-08-14 18:12:50:250 MESSAGE Refresher[0x17414a710]: scheduling next timer in 3240000 ms for purpose [normal refresh] 2017-08-14 18:12:50:250 MESSAGE Register refresher [200] reason [OK] for proxy [sip:210.63.100.188:5068;transport=tls] 2017-08-14 18:12:50:250 MESSAGE Proxy config [0x10250f340] for identity [sip:[email protected]:5068] moving from state [LinphoneRegistrationProgress] to [LinphoneRegistrationOk] on core [0x10281bc00] 2017-08-14 18:12:50:250 MESSAGE Updating friends for identity [sip:[email protected]:5068] on core [0x10281bc00] 2017-08-14 18:12:50:250 MESSAGE Friends list [0x170161980] subscription update skipped since subscriptions not enabled yet 2017-08-14 18:12:50:250 MESSAGE (LinphoneManager.m:1067) New registration state: LinphoneRegistrationOk (message: Registration successful) 2017-08-14 18:12:50:287 MESSAGE Linphone core [0x10281bc00] notified [registration_state_changed] 2017-08-14 18:12:50:287 MESSAGE Changing [client] [REGISTER] transaction [0x170362400], from state [COMPLETED] to [TERMINATED] 2017-08-14 18:12:50:287 MESSAGE Client internal REGISTER transaction [0x170362400] terminated 2017-08-14 18:12:50:287 MESSAGE transaction [0x170362400]: ending transaction background task with id=[8]. 2017-08-14 18:12:50:288 MESSAGE channel [0x1027ac000]: ending recv background task with id=[a]. 2017-08-14 18:12:50:306 MESSAGE Background task belle-sip recv channel started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:306 MESSAGE channel [0x1027ac000]: starting recv background task with id=[b]. 2017-08-14 18:12:50:307 MESSAGE channel [0x1027ac000]: received [633] new bytes from [TLS://210.63.100.188:5068]: NOTIFY sip:[email protected]:55086;transport=tls SIP/2.0 Via: SIP/2.0/TLS 210.63.100.188:5068;branch=z9hG4bK40fbb4da;rport Max-Forwards: 70 From: "asterisk" sip:[email protected]:5068;tag=as3ca4660c To: sip:[email protected]:55086;transport=tls Contact: sip:[email protected]:5068;transport=TLS Call-ID: [email protected]:5068 CSeq: 102 NOTIFY User-Agent: cs210 Event: message-summary Content-Type: application/simple-message-summary Content-Length: 113

Messages-Waiting: no Message-Account: sip:[email protected]:5068;transport=TLS Voice-Message: 0/0 (0/0)

2017-08-14 18:12:50:312 MESSAGE channel [0x1027ac000] [520] bytes parsed 2017-08-14 18:12:50:312 MESSAGE channel [0x1027ac000] read [113] bytes of body from [210.63.100.188:5068] 2017-08-14 18:12:50:313 MESSAGE Background task belle-sip transaction(0x170121ae0) started. Unknown remaining time since application is not fully in background. 2017-08-14 18:12:50:313 MESSAGE transaction [0x170121ae0]: starting transaction background task with id=[c]. 2017-08-14 18:12:50:313 MESSAGE Changing [server] [NOTIFY] transaction [0x170121ae0], from state [INIT] to [TRYING] 2017-08-14 18:12:50:313 MESSAGE Outgoing subscription terminated by remote [sip:[email protected]:55086;transport=tls] 2017-08-14 18:12:50:313 WARNING ( StatusBarView.m:142 ) Received new NOTIFY from voice mail but could not find 'voice-message' in BODY. Ignoring it. 2017-08-14 18:12:50:313 MESSAGE LinphoneEvent [0x1700f1580] moving to subscription state LinphoneSubscriptionTerminated 2017-08-14 18:12:50:313 MESSAGE Changing [server] [NOTIFY] transaction [0x170121ae0], from state [TRYING] to [COMPLETED] 2017-08-14 18:12:50:314 MESSAGE channel [0x1027ac000]: message sent to [TLS://210.63.100.188:5068], size: [427] bytes SIP/2.0 200 Ok Via: SIP/2.0/TLS 210.63.100.188:5068;branch=z9hG4bK40fbb4da;rport From: "asterisk" sip:[email protected]:5068;tag=as3ca4660c To: sip:[email protected]:55086;transport=tls;tag=P5Xl1EX Call-ID: [email protected]:5068 CSeq: 102 NOTIFY User-Agent: Linphone_iPhone9.4_iOS10.3.3/3.16.4-94-g8937a2ca (belle-sip/1.6.3) Supported: replaces, outbound Content-Length: 0

2017-08-14 18:12:50:314 MESSAGE Destroying op [0x1025c0430] of type [SalOpUnknown] 2017-08-14 18:12:50:314 MESSAGE channel [0x1027ac000]: ending recv background task with id=[b]. 2017-08-14 18:12:50:327 MESSAGE Changing [server] [NOTIFY] transaction [0x170121ae0], from state [COMPLETED] to [TERMINATED] 2017-08-14 18:12:50:327 MESSAGE Server NOTIFY transaction [0x170121ae0] terminated 2017-08-14 18:12:50:327 MESSAGE Unhandled transaction terminated [0x170121ae0] 2017-08-14 18:12:50:327 MESSAGE transaction [0x170121ae0]: ending transaction background task with id=[c]. 2017-08-14 18:12:50:328 MESSAGE Transaction [0x170121ae0] deleted 2017-08-14 18:12:51:009 MESSAGE Friends list [0x170161980] subscription update skipped since subscriptions not enabled yet 2017-08-14 18:12:55:007 MESSAGE Releasing inactive tone player. 2017-08-14 18:12:55:009 MESSAGE ms_filter_unlink: MSFilePlayer:0x1701215e0,0-->MSDtmfGen:0x170121680,0 2017-08-14 18:12:55:009 MESSAGE ms_filter_unlink: MSDtmfGen:0x170121680,0-->MSResample:0x1701217c0,0 2017-08-14 18:12:55:010 MESSAGE ms_filter_unlink: MSResample:0x1701217c0,0-->MSAQWrite:0x170121720,0 2017-08-14 18:12:55:020 MESSAGE Ring MSTicker thread exiting 2017-08-14 18:13:19:051 MESSAGE (honeAppDelegate.m:543 ) PushKit : incoming voip notfication: { aps = { alert = { "loc-args" = ( M2906, "08/14 18:13" ); "loc-key" = "Missed call"; }; badge = 1; sound = "default.mp3"; }; } 2017-08-14 18:13:19:051 MESSAGE (LinphoneManager.m:1777) Cancelling old network reachability 2017-08-14 18:13:19:060 MESSAGE (LinphoneManager.m:1689) Network connection flags: kSCNetworkReachabilityFlagsTransientConnection, kSCNetworkReachabilityFlagsReachable, kSCNetworkReachabilityFlagsIsWWAN, 2017-08-14 18:13:19:066 MESSAGE (honeAppDelegate.m:484 ) Notification { aps = { alert = { "loc-args" = ( M2906, "08/14 18:13" ); "loc-key" = "Missed call"; }; badge = 1; sound = "default.mp3"; }; } processed

ivylee1108 avatar Aug 14 '17 10:08 ivylee1108

Hello,

Does the app register on first push reception ?

ghost avatar Aug 14 '17 12:08 ghost

@ReisBenjamin The registration state on first push reception is LinphoneRegistrationProgress

ivylee1108 avatar Aug 15 '17 05:08 ivylee1108

Okay,

The push notification is only used to wake the device up. Once it's done the app has to register in order to get the incoming call or message. As long as the app is not registered, it can't receive anything so you need to wait for LinphoneRegistrationSuccess. The second push is probably received once the app has registered.

ghost avatar Aug 16 '17 07:08 ghost

Hello @ivylee1108, The same issue produced in my project earlier.

If Application is on running state - call work / device wake up if Application is on background state - call work / device wake up if application is on sleep or inactive state - call not working / device dose not wake up.

After handel completion handler in below method call worked and follow below steps.

//Add in LinphoneAppDelegate.h @property (nonatomic, copy) void (^bgCompletionHandler)(void);

  • (void) removeBgCompletionHandler;

//Add in LinphoneAppDelegate.m

  • (void) removeBgCompletionHandler { if ([self bgCompletionHandler]) { self bgCompletionHandler; } [self setBgCompletionHandler:nil]; }

  • (void)pushRegistry:(PKPushRegistry *)registry didReceiveIncomingPushWithPayload:(PKPushPayload *)payload forType:(PKPushType)type withCompletionHandler:(void (^)(void))completion { //add on starting [self setBgCompletionHandler:completion];

//Rest of other code //Remove completion handeler // dispatch_async(dispatch_get_main_queue(), ^{completion();}); }

  • (void)processRemoteNotification:(NSDictionary *)userInfo { //Remove if aps is NIL if (aps != nil) { //Rest of other code //Remove if loc_key is NIL if (loc_key != nil) { //Rest of other code

                            if{
                                   //Rest of other code
                               }
                              else  if ([callId  isEqual: @""])
                               {
                                      //Remove if CALLID is Blank 
                                      [self removeBgCompletionHandler];
                                      LOGE(@"PushNotification: does not have call-id yet, fix it !");
                                }
             }else{
                           [self removeBgCompletionHandler];
             }
     }
    

}else{ [self removeBgCompletionHandler]; }

just try it its work for me.

for more information please visit this link :- https://stackoverflow.com/questions/47369658/voip-pushkit-and-app-wake-up?rq=1

Thanks.

RONAKSANKHALA avatar Apr 20 '18 04:04 RONAKSANKHALA

@ivylee1108 Hey, did you succeed with the issue? We have the same behaviour on our app on iOS. The second call is always succeed but first fails. We got LinphoneRegistrationOk and core is created and post for registration has been successfully sent.

victorbarskov avatar Feb 05 '19 12:02 victorbarskov

Hello,

I will resolve this issue with VoIP silent push notification. if you need help then mail me: [email protected], add subject: linphone issue

Thanks

Trushangpatel avatar May 31 '19 07:05 Trushangpatel

just send this for first push to wake up device then follow it with your asterisk sip traffic

$body['aps'] = array( 'content-available' => 1 );

if you're really stuck then modify then LinphoneAppDelegate.m around line 650 or so

  • (void)processPush:(NSDictionary *)userInfo { LOGI(@"[PushKit] Notification [%p] received with pay load : %@", userInfo, userInfo.description);

#pragma mark - Force Register on push receive by bouncing the network check. LinphoneManager.instance.connectivity = none; // Force connectivity to be discovered again [LinphoneManager.instance setupNetworkReachabilityCallback];

[self configureUINotification];
[LinphoneManager.instance setupNetworkReachabilityCallback];
//to avoid IOS to suspend the app before being able to launch long running task
[self processRemoteNotification:userInfo];

}

======= by adding

LinphoneManager.instance.connectivity = none; // Force connectivity to be discovered again
[LinphoneManager.instance setupNetworkReachabilityCallback];

it will bounce your registration on any incoming push notification empty or not, with loc-key or not.

S0U1SB4N3 avatar Jan 22 '20 01:01 S0U1SB4N3

just send this for first push to wake up device then follow it with your asterisk sip traffic

$body['aps'] = array( 'content-available' => 1 );

if you're really stuck then modify then LinphoneAppDelegate.m around line 650 or so

  • (void)processPush:(NSDictionary *)userInfo { LOGI(@"[PushKit] Notification [%p] received with pay load : %@", userInfo, userInfo.description);

#pragma mark - Force Register on push receive by bouncing the network check. LinphoneManager.instance.connectivity = none; // Force connectivity to be discovered again [LinphoneManager.instance setupNetworkReachabilityCallback];

[self configureUINotification];
[LinphoneManager.instance setupNetworkReachabilityCallback];
//to avoid IOS to suspend the app before being able to launch long running task
[self processRemoteNotification:userInfo];

}

======= by adding

LinphoneManager.instance.connectivity = none; // Force connectivity to be discovered again
[LinphoneManager.instance setupNetworkReachabilityCallback];

it will bounce your registration on any incoming push notification empty or not, with loc-key or not.

Hi, How to apply this to latest code base? setupNetworkReachabilityCallback is not found.

leelai avatar Jul 26 '21 07:07 leelai