#include <appdynamics.h>
Public Member Functions | |
| ExitCall (BT &bt, const char *backend) | |
| ExitCall (BT &bt, const std::string &backend) | |
| ExitCall (appd_exitcall_handle exitcall) | |
| ~ExitCall () | |
| void | store (const char *guid) |
| void | store (const std::string &guid) |
| const std::string & | get_correlation_header () |
| int | set_details (const char *details) |
| int | set_details (const std::string &details) |
| virtual void | add_error (enum appd_error_level level, const char *message, bool mark_bt_as_error=true) |
Public Member Functions inherited from appd::sdk::HandleWrapper< appd_exitcall_handle > | |
| HandleWrapper () | |
| HandleWrapper (appd_exitcall_handle handle) | |
| virtual | ~HandleWrapper ()=default |
| appd_exitcall_handle | handle () |
| const appd_exitcall_handle | handle () const |
| void | add_error (enum appd_error_level level, const std::string &message, bool mark_bt_as_error=true) |
Protected Member Functions | |
| void | init (BT &bt, const char *backend) |
Private Member Functions | |
| ExitCall () | |
Private Attributes | |
| bool | m_loaded_correlation_header |
| std::string | correlation_header |
Additional Inherited Members | |
Protected Attributes inherited from appd::sdk::HandleWrapper< appd_exitcall_handle > | |
| appd_exitcall_handle | m_handle |
| bool | m_borrowed_handle |
Represents an AppDynamics exit call as part of a business transaction.
As with appd::sdk::BT, this class allows automatically ending an exit call when it goes out of scope:
{
appd::sdk::BT bt("compute");
{
appd::sdk::ExitCall db_call(bt, "primary-db");
auto db = get_db_connection();
db_call.set_details(query);
db.execute(query, params);
} // exit call ends automatically
// ... more that happens as part of the BT ...
}
For managing an exit call with a more complex lifetime, you are encouraged to look at a std::unique_ptr<appd::sdk::ExitCall> or std::shared_ptr<appd::sdk::ExitCall>.
You cannot copy an ExitCall.
|
inline |
|
inline |
|
inline |
Construct an object wrapping the given exit call handle.
The handle is not owned by this object: the destructor will not call appd_exitcall_end on the given handle.
| exitcall | An exit call handle as returned by appd_exitcall_begin or appd_exitcall_get. |
|
inline |
|
private |
|
inlinevirtual |
Calls appd_exitcall_add_error on this exit call with the given error information.
Implements appd::sdk::HandleWrapper< appd_exitcall_handle >.
|
inline |
Calls appd_exitcall_get_correlation_header on this exit call.
|
inlineprotected |
|
inline |
Calls appd_exitcall_set_details on this exit call with the given information.
|
inline |
Calls appd_exitcall_set_details on this exit call with the given information.
|
inline |
Calls appd_exitcall_store on this exit call with the given GUID.
|
inline |
Calls appd_exitcall_store on this exit call with the given GUID.
|
private |
|
private |