#include <Tracer.hpp>
Public Member Functions | |
| Tracer (std::shared_ptr< std::atomic_flag > checkFlag, std::string serverPath="", std::string serverProxy="", const std::string &crashpadHandlerPath="", const std::string &reportPath="", std::vector< base::FilePath > attachments={}) | |
| Tracer (const Tracer &)=delete | |
| Copy constructor. | |
| Tracer (Tracer &&)=delete | |
| Move constructor. | |
| Tracer & | operator= (Tracer)=delete |
| Copy assignment operator. | |
| Tracer & | operator= (Tracer &&)=delete |
| Move assignment operator. | |
| ~Tracer () | |
Static Public Member Functions | |
| static bool | isRunning () |
Private Member Functions | |
| void | startHandler () |
| void | threadFunc (const std::stop_token &stopToken) const noexcept |
Static Private Member Functions | |
| static bool | checkPidIsRunning (pid_t processId) |
| static bool | checkSocketIsRunning (int sockId) |
| static std::string | getSelfExecutableDir () |
| static void | dumpSharedLibraryInfo (const std::string &filePath) |
Private Attributes | |
| std::shared_ptr< std::atomic_flag > | _checkFlag |
| std::string | _serverPath |
| std::string | _serverProxy |
| std::string | _handlerPath |
| std::map< std::string, std::string > | _annotations |
| std::vector< base::FilePath > | _attachments |
| std::string | _reportPath |
| std::unique_ptr< crashpad::CrashpadClient > | _clientHandler |
| std::unique_ptr< std::jthread > | _thread |
Tracer class to handle operations of Crashpad
Definition at line 10 of file Tracer.hpp.
|
explicit |
Construct a new Tracer object
| [in] | checkFlag | Flag to check if the process is running |
| [in] | serverPath | Remote server address |
| [in] | serverProxy | Remote server proxy |
| [in] | reportPath | Path to where dump minidump files |
| [in] | crashpadHandlerPath | Path to crashpad_handler executable |
| [in] | attachments | Attachments to add to the minidump |
Definition at line 171 of file Tracer.cpp.


|
delete |
Copy constructor.

|
delete |
Move constructor.

|
default |
Destroy the Tracer object
|
staticprivate |
Check if the given process ID is running
| [in] | processId | The process ID to check |
Definition at line 88 of file Tracer.cpp.

|
staticprivate |
Check if the given socket ID is running
| [in] | sockId | The socket ID to check |
Definition at line 90 of file Tracer.cpp.

|
staticprivate |
Dump shared library information to a file
| [in] | filePath | File path to dump the information |
Definition at line 131 of file Tracer.cpp.

|
inlinestaticprivate |
Get the executable directory of the current application
Definition at line 100 of file Tracer.cpp.

|
staticnodiscard |
Check if the crashpad_handler process is running
Definition at line 110 of file Tracer.cpp.


Move assignment operator.

Copy assignment operator.

|
private |
Start the crashpad handler process
Definition at line 23 of file Tracer.cpp.


|
privatenoexcept |
Thread function to check and restart the crashpad handler process
| [in] | stopToken | jthread stop token |
Definition at line 57 of file Tracer.cpp.


|
private |
Definition at line 17 of file Tracer.hpp.
|
private |
Definition at line 18 of file Tracer.hpp.
|
private |
Definition at line 12 of file Tracer.hpp.
|
private |
Definition at line 20 of file Tracer.hpp.
|
private |
Definition at line 16 of file Tracer.hpp.
|
private |
Definition at line 19 of file Tracer.hpp.
|
private |
Definition at line 14 of file Tracer.hpp.
|
private |
Definition at line 15 of file Tracer.hpp.
|
private |
Definition at line 22 of file Tracer.hpp.