注册

环信SDK 3.1.4打包混淆后,无法登录,日志提示:getDnsListFromServer code: 408 response : can't catch exceptions

日志内容:
 [2016/7/28 21:54:2:344]: EMChatClientImpl::init()
[2016/7/28 21:54:2:345]: EMConfigManager::init() 
[2016/7/28 21:54:2:345]: No config file, do nothing
[2016/7/28 21:54:2:345]: addConnectionListener
[2016/7/28 21:54:2:345]: addConnectionListener
[2016/7/28 21:54:2:345]: addConnectionListener
[2016/7/28 21:54:2:346]: >>>>>>eice_init
[2016/7/28 21:54:2:346]: >>>>>>eice_init complete
[2016/7/28 21:54:2:347]: addConnectionListener
[2016/7/28 21:54:2:350]: registerContactListener
[2016/7/28 21:54:2:353]: restBaseUrl()
[2016/7/28 21:54:2:354]: EMDNSManager::getCurrentHost: type: 2
[2016/7/28 21:54:2:354]: EMSessionManager::checkDNS()
[2016/7/28 21:54:2:354]: valid_time: 
[2016/7/28 21:54:2:354]: no saved dns list, download it
[2016/7/28 21:54:2:355]: getDnsListFromServer()
[2016/7/28 21:54:2:355]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 21:54:2:358]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:2:359]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:2:359]: 1 time retry
[2016/7/28 21:54:2:360]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:2:361]: [EMARHttpAPI] httpExecute
[2016/7/28 21:54:2:362]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:2:363]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:2:364]: 2 time retry
[2016/7/28 21:54:2:364]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:2:364]: checkDNS finished
[2016/7/28 21:54:2:364]: EMDNSManager::getHost: type: 2
[2016/7/28 21:54:2:364]: restAddress is empty
[2016/7/28 21:54:2:374]: [actived] "gps" location provider requires ACCESS_FINE_LOCATION permission.
[2016/7/28 21:54:2:388]: [HttpClientManager] try send request, request url: http:///luckysonics/x318/devices with number: 0
[2016/7/28 21:54:2:389]: EMDNSManager::getNextAvailableHost: type: 2
[2016/7/28 21:54:2:389]: EMSessionManager::checkDNS()
[2016/7/28 21:54:2:389]: valid_time: 
[2016/7/28 21:54:2:389]: no saved dns list, download it
[2016/7/28 21:54:2:389]: getDnsListFromServer()
[2016/7/28 21:54:2:389]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 21:54:2:390]: [EMARHttpAPI] httpExecute
[2016/7/28 21:54:2:390]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:2:391]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:2:391]: 1 time retry
[2016/7/28 21:54:2:391]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:2:392]: [EMARHttpAPI] httpExecute
[2016/7/28 21:54:2:393]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:2:394]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:2:395]: 2 time retry
[2016/7/28 21:54:2:395]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:2:395]: checkDNS finished
[2016/7/28 21:54:2:395]: restBaseUrl()
[2016/7/28 21:54:2:395]: EMDNSManager::getCurrentHost: type: 2
[2016/7/28 21:54:2:396]: EMSessionManager::checkDNS()
[2016/7/28 21:54:2:396]: valid_time: 
[2016/7/28 21:54:2:396]: no saved dns list, download it
[2016/7/28 21:54:2:396]: getDnsListFromServer()
[2016/7/28 21:54:2:397]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 21:54:2:400]: [EMARHttpAPI] httpExecute
[2016/7/28 21:54:2:401]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:2:403]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:2:404]: 1 time retry
[2016/7/28 21:54:2:404]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:2:405]: [EMARHttpAPI] httpExecute
[2016/7/28 21:54:2:405]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:2:406]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:2:406]: 2 time retry
[2016/7/28 21:54:2:406]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:2:407]: checkDNS finished
[2016/7/28 21:54:2:407]: EMDNSManager::getHost: type: 2
[2016/7/28 21:54:2:407]: restAddress is empty
[2016/7/28 21:54:41:963]: [EMClient] emchat manager login in process:29899
[2016/7/28 21:54:42:56]: EMSessionManager::login(): z_s_c
[2016/7/28 21:54:42:56]: getDnsListFromServer()
[2016/7/28 21:54:42:56]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 21:54:42:57]: [EMARHttpAPI] httpExecute
[2016/7/28 21:54:42:57]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:42:57]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:42:57]: 1 time retry
[2016/7/28 21:54:42:57]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:42:58]: [EMARHttpAPI] httpExecute
[2016/7/28 21:54:42:58]: [EMARHttpAPI] Stub!
[2016/7/28 21:54:42:58]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 21:54:42:58]: 2 time retry
[2016/7/28 21:54:42:58]: getDnsListFromServer code: 408 response: 
[2016/7/28 21:54:42:58]: getDnsListFromServer failed
[2016/7/28 21:54:42:59]: [EMClient] do stop service
[2016/7/28 22:15:54:791]: EMChatClientImpl::init()
[2016/7/28 22:15:54:792]: EMConfigManager::init() 
[2016/7/28 22:15:54:792]: No config file, do nothing
[2016/7/28 22:15:54:792]: addConnectionListener
[2016/7/28 22:15:54:792]: addConnectionListener
[2016/7/28 22:15:54:792]: addConnectionListener
[2016/7/28 22:15:54:793]: >>>>>>eice_init
[2016/7/28 22:15:54:794]: >>>>>>eice_init complete
[2016/7/28 22:15:54:794]: addConnectionListener
[2016/7/28 22:15:54:798]: registerContactListener
[2016/7/28 22:15:54:812]: restBaseUrl()
[2016/7/28 22:15:54:815]: EMDNSManager::getCurrentHost: type: 2
[2016/7/28 22:15:54:816]: EMSessionManager::checkDNS()
[2016/7/28 22:15:54:818]: valid_time: 
[2016/7/28 22:15:54:818]: no saved dns list, download it
[2016/7/28 22:15:54:819]: getDnsListFromServer()
[2016/7/28 22:15:54:819]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 22:15:54:823]: [EMARHttpAPI] httpExecute
[2016/7/28 22:15:54:827]: [EMARHttpAPI] Stub!
[2016/7/28 22:15:54:828]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 22:15:54:830]: 1 time retry
[2016/7/28 22:15:54:831]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:15:54:834]: [EMARHttpAPI] httpExecute
[2016/7/28 22:15:54:836]: [EMARHttpAPI] Stub!
[2016/7/28 22:15:54:838]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 22:15:54:841]: 2 time retry
[2016/7/28 22:15:54:841]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:15:54:842]: checkDNS finished
[2016/7/28 22:15:54:844]: EMDNSManager::getHost: type: 2
[2016/7/28 22:15:54:844]: restAddress is empty
[2016/7/28 22:15:54:908]: [actived] "gps" location provider requires ACCESS_FINE_LOCATION permission.
[2016/7/28 22:15:54:924]: [HttpClientManager] try send request, request url: http:///luckysonics/x318/devices with number: 0
[2016/7/28 22:15:54:926]: EMDNSManager::getNextAvailableHost: type: 2
[2016/7/28 22:15:54:927]: EMSessionManager::checkDNS()
[2016/7/28 22:15:54:928]: valid_time: 
[2016/7/28 22:15:54:928]: no saved dns list, download it
[2016/7/28 22:15:54:929]: getDnsListFromServer()
[2016/7/28 22:15:54:929]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 22:15:54:930]: [EMARHttpAPI] httpExecute
[2016/7/28 22:15:54:931]: [EMARHttpAPI] Stub!
[2016/7/28 22:15:54:932]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 22:15:54:934]: 1 time retry
[2016/7/28 22:15:54:934]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:15:54:935]: [EMARHttpAPI] httpExecute
[2016/7/28 22:15:54:936]: [EMARHttpAPI] Stub!
[2016/7/28 22:15:54:938]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 22:15:54:940]: 2 time retry
[2016/7/28 22:15:54:941]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:15:54:941]: checkDNS finished
[2016/7/28 22:15:54:942]: restBaseUrl()
[2016/7/28 22:15:54:942]: EMDNSManager::getCurrentHost: type: 2
[2016/7/28 22:15:54:943]: EMSessionManager::checkDNS()
[2016/7/28 22:15:54:943]: valid_time: 
[2016/7/28 22:15:54:944]: no saved dns list, download it
[2016/7/28 22:15:54:944]: getDnsListFromServer()
[2016/7/28 22:15:54:944]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 22:15:54:945]: [EMARHttpAPI] httpExecute
[2016/7/28 22:15:54:946]: [EMARHttpAPI] Stub!
[2016/7/28 22:15:54:947]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 22:15:54:950]: 1 time retry
[2016/7/28 22:15:54:951]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:15:54:952]: [EMARHttpAPI] httpExecute
[2016/7/28 22:15:54:952]: [EMARHttpAPI] Stub!
[2016/7/28 22:15:54:957]: [EMARHttpAPI] can't catch exceptions
[2016/7/28 22:15:54:957]: 2 time retry
[2016/7/28 22:15:54:958]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:15:54:958]: checkDNS finished
[2016/7/28 22:15:54:960]: EMDNSManager::getHost: type: 2
[2016/7/28 22:15:54:961]: restAddress is empty
[2016/7/28 22:27:24:829]: EMChatClientImpl::init()
[2016/7/28 22:27:24:830]: EMConfigManager::init() 
[2016/7/28 22:27:24:830]: No config file, do nothing
[2016/7/28 22:27:24:830]: addConnectionListener
[2016/7/28 22:27:24:830]: addConnectionListener
[2016/7/28 22:27:24:830]: addConnectionListener
[2016/7/28 22:27:24:831]: >>>>>>eice_init
[2016/7/28 22:27:24:831]: >>>>>>eice_init complete
[2016/7/28 22:27:24:831]: addConnectionListener
[2016/7/28 22:27:24:838]: registerContactListener
[2016/7/28 22:27:24:843]: restBaseUrl()
[2016/7/28 22:27:24:843]: EMDNSManager::getCurrentHost: type: 2
[2016/7/28 22:27:24:844]: EMSessionManager::checkDNS()
[2016/7/28 22:27:24:844]: valid_time: 
[2016/7/28 22:27:24:844]: no saved dns list, download it
[2016/7/28 22:27:24:844]: getDnsListFromServer()
[2016/7/28 22:27:24:844]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 22:27:24:846]: 1 time retry
[2016/7/28 22:27:24:846]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:27:24:847]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:27:24:847]: restAddress is empty
[2016/7/28 22:27:24:863]: no saved dns list, download it
[2016/7/28 22:27:24:864]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 22:27:24:866]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:27:24:875]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:27:24:876]: no saved dns list, download it
[2016/7/28 22:27:24:876]: buildUrl(): http://rs.easemob.com/easemob/server.json?sdk_version=3.1.4&app_key=luckysonics%23x318&file_version=1
[2016/7/28 22:27:24:877]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:27:24:877]: getDnsListFromServer code: 408 response: 
[2016/7/28 22:27:24:878]: restAddress is empty
已邀请:
解决了

-keep class com.hyphenate.** {*;} 
-keep class internal.org.apache.http.entity.mine.** {*;}
-keep class android.net.** {*;} 
-keep class com.android.internal.http.multipart.** {*;}
-keep class org.apache.** {*;}
 
参考demo的打包混淆的文档加上看看

要回复问题请先登录注册