You need to enable JavaScript to run this app.
文档中心
应用性能监控全链路版

应用性能监控全链路版

复制全文
下载 pdf
iOS 端监控
如何丢弃“疑似 OOM”日志
复制全文
下载 pdf
如何丢弃“疑似 OOM”日志
SDK 版本要求​
RangersAPM >= 5.2.12​
上报配置​
参考SDK上报配置修改下图所示配置项,配置为“是”​​​
SDK 回调​
通过添加 SDK 回调可以在发生疑似 OOM 时获取到 SDK 捕获的记录,此回调仅当在 SDK 上报配置中配置「是否仅上报确定的 OOM 崩溃」为“是”时才会执行,可以通过此回调获取到没有上报的疑似 OOM崩溃日志,根据需要通过埋点、日志等其他方式进行统计​
​
/**​
设置疑似 OOM 崩溃回调。当 SDK 排除 watchdog、普通 crash 等原因后判断为可能的 OOM 时触发。​
注意:​
1. 请在初始化 APM 之前(即 +[RangersAPM startWithConfig:] 调用之前)设置,以保证首启即可生效。​
2. 回调可能在非主线程触发,请避免在其中执行耗时或需主线程的操作。​
3. 若仅上报“确定的 OOM”(APMPlus 控制台配置),疑似 OOM 将仅通过该回调返回而不进行上传。​
​
Set the callback for suspected OOM crash. It fires when the SDK considers a possible OOM after excluding watchdog and regular crashes.​
Notice:​
1. Set this before initializing APM (before calling +[RangersAPM startWithConfig:]) to take effect from the first launch.​
2. The callback may be invoked off the main thread; avoid heavy work or main-thread-dependent operations inside it.​
3. If only “certain OOMs” are uploaded (APMPlus console configuration), non-certain OOMs will be returned via this callback without uploading.​
*/​
+ (void)setMaybeOOMCrashCallback:(RangersAPMOOMCrashCallback)callback;​
​
​
最近更新时间:2025.12.10 17:15:33
这个页面对您有帮助吗?
有用
有用
无用
无用