MONGOC_APM_COM...ED_GET_COMMAND(3)

✨ mongoc_apm_command_started_get_command() ✨

okay bestie so this is from libmongoc, section 3 of the manual β€” yes, the MongoDB C driver docs, we love a deep cut 🫢


🌸 SYNOPSIS 🌸

const bson_t *
mongoc_apm_command_started_get_command (
   const mongoc_apm_command_started_t *event);

So what does this icon do? It returns this event's command. That's it. That's the whole vibe. πŸ’…

But β€” and this is the important part, do NOT skip it β€” the data is only valid in the scope of the callback that receives this event. So if you're gonna touch it after the callback returns? You gotta copy it first. No cap, no shortcuts, just copy it. 😭


πŸŽ€ PARAMETERS πŸŽ€

  • event β€” a mongoc_apm_command_started_t. that's the whole parameter list. one (1) event. she's low maintenance. πŸ’–

πŸ¦‹ RETURNS πŸ¦‹

A bson_t β€” and please, do not modify it and do not free it. It is not yours to touch, it's giving borrowed-from-the-library energy. Look respectfully. 🌈

πŸ‘€ SEE ALSO:

  • Introduction to Application Performance Monitoring

(go read it, it's the context you need, iykyk 🧚)


πŸ‘‘ AUTHOR πŸ‘‘

MongoDB, Inc β€” icons only πŸ’œ


2009-present, MongoDB, Inc. β€” protect that copyright, bestie πŸŽ€


and that's the whole page, mwah πŸ’‹ β€” this was version 2.5.6, dated Oct 09, 202… (the footer got a lil cut off bestie, but that's literally what it says), straight out of the libmongoc MONGOC_APM_COM...ED_GET_COMMAND(3) page. go write some APM callbacks, you're gonna slay πŸ”₯πŸ¦‹βœ¨

πŸ“¦ where this page comes from