carta
mongoc_structured_log_entry_t(3)

mongoc_structured_log_entry_t3

Functions

mongoc_structured_log_entry_get_component()

Synopsis

mongoc_structured_log_component_t
mongoc_structured_log_entry_get_component (const mongoc_structured_log_entry_t *entry);

Parameters

•

entry: A mongoc_structured_log_entry_t pointer.

Returns

The mongoc_structured_log_component_t associated with this log entry.

SEE ALSO:

Structured Logging

mongoc_structured_log_entry_get_level()

Synopsis

mongoc_structured_log_level_t
mongoc_structured_log_entry_get_level (const mongoc_structured_log_entry_t *entry);

Parameters

•

entry: A mongoc_structured_log_entry_t pointer.

Returns

The mongoc_structured_log_level_t associated with this log entry.

SEE ALSO:

Structured Logging

mongoc_structured_log_entry_get_message_string()

Synopsis

const char *
mongoc_structured_log_entry_get_message_string (const mongoc_structured_log_entry_t *entry);

Parameters

•

entry: A mongoc_structured_log_entry_t pointer.

Returns

A string, guaranteed to be valid only during the lifetime of the structured log handler. It should not be freed or modified.

Identical to the value of the message key in the document returned by mongoc_structured_log_entry_message_as_bson().

This is not a complete string representation of the structured log, but rather a standardized identifier for a particular log event.

SEE ALSO:

Structured Logging

mongoc_structured_log_entry_message_as_bson()

Synopsis

bson_t *
mongoc_structured_log_entry_message_as_bson (const mongoc_structured_log_entry_t *entry);

Make a new copy, as a bson_t, of the log entry's standardized BSON representation. When possible, a log handler should avoid serializing log messages that will be discarded. Each call allocates an independent copy of the message that must be freed.

Parameters

•

entry: A mongoc_structured_log_entry_t pointer.

Returns

A new allocated bson_t that must be freed with a call to bson_destroy().

SEE ALSO:

Structured Logging

SEE ALSO:

Structured Logging

Author

MongoDB, Inc

From libmongoc-doc 1.30.4-1+deb13u3 in Debian 13 (Trixie). Parsed by carta from the page's man source.