【发布时间】:2015-07-27 21:29:09
【问题描述】:
我想在我的应用程序中知道 NewRelic 何时尝试发送数据并且由于任何原因失败,例如,当没有互联网连接时它会收到错误
NRMAHarvesterConnection.m:101 -[NRMAHarvesterConnection send:]
Failed to retrieve collector response: Error Domain=NSURLErrorDomain Code=-1009 "The Internet connection appears to be offline." UserInfo=0x7fa044e1a360 {NSUnderlyingError=0x7fa044e26a10 "The Internet connection appears to be offline.", NSErrorFailingURLStringKey=https://mobile-collector.newrelic.com/mobile/v2/data, NSErrorFailingURLKey=https://mobile-collector.newrelic.com/mobile/v2/data, _kCFStreamErrorDomainKey=12, _kCFStreamErrorCodeKey=8, NSLocalizedDescription=The Internet connection appears to be offline.}
NewRelic 会将此错误打印到控制台,因此它一定是检测到此类错误。
我想知道这种错误何时发生以及错误是什么,以便我可以记录它
【问题讨论】: