- 필수 기능
- 시작하기
- Glossary
- 표준 속성
- Guides
- Agent
- 통합
- 개방형텔레메트리
- 개발자
- Administrator's Guide
- API
- Datadog Mobile App
- CoScreen
- Cloudcraft
- 앱 내
- 서비스 관리
- 인프라스트럭처
- 애플리케이션 성능
- APM
- Continuous Profiler
- 스팬 시각화
- 데이터 스트림 모니터링
- 데이터 작업 모니터링
- 디지털 경험
- 소프트웨어 제공
- 보안
- AI Observability
- 로그 관리
- 관리
If you experience unexpected behavior with Datadog RUM, use this guide to resolve issues quickly. If you continue to have trouble, contact Datadog Support for further assistance.
After you configure Datadog SDK and run the app for the first time, check your debugger console in Xcode. The SDK implements several consistency checks and outputs relevant warnings if something is misconfigured.
When writing your application, you can enable development logs by setting the verbosityLevel
value. Relevant messages from the SDK with a priority equal to or higher than the provided level are output to the debugger console in Xcode:
Datadog.verbosityLevel = .debug
You should then see an output similar to the below, indicating that a batch of RUM data was properly uploaded:
[DATADOG SDK] 🐶 → 17:23:09.849 [DEBUG] ⏳ (rum) Uploading batch...
[DATADOG SDK] 🐶 → 17:23:10.972 [DEBUG] → (rum) accepted, won't be retransmitted: success
Recommendation: Use Datadog.verbosityLevel
in the DEBUG
configuration, and unset it in RELEASE
.
DDURLSessionDelegate
with your own session delegateIf you want to automatically track network requests with DDURLSessionDelegate
but your app already implements its own session delegate, you can use either inheritance or composition patterns and forward calls to DDURLSessionDelegate
.
When using an inheritance pattern, use DDURLSessionDelegate
as a base class for your custom delegate and make sure to call the super
implementation from your overridden methods. For example:
class YourCustomDelegateURLSessionDelegate: DDURLSessionDelegate {
override func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) {
super.urlSession(session, task: task, didCompleteWithError: error) // forward to Datadog delegate
/* your custom logic */
}
}
When using a composition pattern, leverage Datadog’s __URLSessionDelegateProviding
protocol to keep an internal instance of DDURLSessionDelegate
and forward calls to ddURLSessionDelegate
. For example:
private class YourCustomDelegateURLSessionDelegate: NSObject, URLSessionTaskDelegate, URLSessionDataDelegate, __URLSessionDelegateProviding {
// MARK: - __URLSessionDelegateProviding conformance
let ddURLSessionDelegate = DDURLSessionDelegate()
// MARK: - __URLSessionDelegateProviding handling
func urlSession(_ session: URLSession, task: URLSessionTask, didFinishCollecting metrics: URLSessionTaskMetrics) {
ddURLSessionDelegate.urlSession(session, task: task, didFinishCollecting: metrics) // forward to Datadog delegate
/* your custom logic */
}
func urlSession(_ session: URLSession, task: URLSessionTask, didCompleteWithError error: Error?) {
ddURLSessionDelegate.urlSession(session, task: task, didCompleteWithError: error) // forward to Datadog delegate
/* your custom logic */
}
func urlSession(_ session: URLSession, dataTask: URLSessionDataTask, didReceive data: Data) {
ddURLSessionDelegate.urlSession(session, dataTask: dataTask, didReceive: data) // forward to Datadog delegate
/* your custom logic */
}
}
Note: If using composition, ddURLSessionDelegate
must receive all necessary calls listed in __URLSessionDelegateProviding
protocol comments. Your delegate needs to:
URLSessionTaskDelegate
and forward:URLSessionDataDelegate
and forward:A warning appears when deobfuscation fails for a stack trace. If the stack trace is not deobfuscated to begin with, you can ignore this warning. Otherwise, use the RUM Debug Symbols page to view all your uploaded dSYMs. See Investigate Obfuscated Stack Traces with RUM Debug Symbols.
추가 유용한 문서, 링크 및 기사: