Understand the SentryCrash architecture and components
mainSentryCrash is the core crash detection and reporting engine for the Sentry Cocoa SDK. It is a specialized subsystem written primarily in C, with Objective-C, C++, and Swift wrappers.
Key architectural components include:
- Monitors: Detect various crash types including Mach kernel exceptions, POSIX signals, Objective-C exceptions, and C++ exceptions.
- Recording: Handles the core logic of capturing crash details, writing reports to disk, and managing report storage/retrieval.
- Tools: A large collection of low-level utilities for CPU context handling (arm, x86, etc.), stack unwinding, Mach kernel interfaces, and JSON encoding.
- Reporting: Provides mechanisms for filtering crash reports.
- Installations: Manages the lifecycle of the crash handler and report delivery.