MONGOC_APM_COM...CTION_ID_INT64(3)

πŸ’… MONGOC_APM_COM...CTION_ID_INT64(3) ✨

okay bestie, welcome to the libmongoc manual β€” yes we're literally hanging out in a page whose name got truncated mid-sentence, and honestly? iconic behavior. anyway this one's short and sweet, let's go 🫢


✨ SYNOPSIS ✨

int64_t
mongoc_apm_command_failed_get_server_connection_id_int64 (
  const mongoc_apm_command_failed_t *event);

Returns this event's context. πŸŽ€

Returns the server connection ID for the command. The server connection ID is distinct from the server ID (that's mongoc_apm_command_failed_get_server_id(), different function, don't mix them up bestie 😭) and it's returned by the hello or legacy hello response as "connectionId" from the server on 4.2+. periodt. πŸ’…


🌸 PARAMETERS 🌸

  • event β€” a mongoc_apm_command_failed_t. that's the vibe check input, go off πŸ‘‘

πŸ¦‹ RETURNS πŸ¦‹

The server connection ID as a positive integer or -1 if it's not available. so like, if you get -1, it's not giving anything, it's just not there, no cap πŸ™ˆ

SEE ALSO: Introduction to Application Performance Monitoring β€” go read it, it's the lore ✨

πŸ‘‘ AUTHOR πŸ‘‘

MongoDB, Inc β€” the main characters fr fr 🫢


2009-present, MongoDB, Inc.


and that's the whole page, bestie! 🌈 this gorgeous little artifact is from version 2.5.6, dated Oct 09, 2025, brought to you by the fine folks at MongoDB, Inc. mwah πŸ’‹ slay, and remember: connection ID β‰  server ID, iykyk πŸ§šβ€β™€οΈπŸ’œ

πŸ“¦ where this page comes from