MONGOC_CLIENT_...ION_GET_CLIENT(3)

πŸŽ€ MONGOC_CLIENT_SESSION_GET_CLIENT(3) πŸŽ€

okay bestie, welcome to libmongoc β€” the C driver for MongoDB, and this lil page is all about one tiny function that hands you back the client a session came from. group chat energy: it's giving "who's your mom", but for sessions πŸ’…


✨ SYNOPSIS ✨

mongoc_client_t *
mongoc_client_session_get_client (const mongoc_client_session_t *session);

literally that's the whole thing. she's short, she's sweet, she's iconic.

So what does she do? 🌸 She returns the mongoc_client_t from which this session was created. That's it. That's the vibe. And if you wanna know how sessions come into existence in the first place, go peek at mongoc_client_start_session() β€” that's the origin story 🫢


🌈 PARAMETERS 🌈

  • session β€” a mongoc_client_session_t. that's the session you're asking about, bestie, no cap πŸ’–

⭐ RETURNS ⭐

A mongoc_client_t β€” and listen, this is the important part: that client should not be freed. πŸ™ˆ

fr fr, do NOT free it, do NOT destroy it, don't even look at it funny. It's not yours to clean up. She's borrowed, not bought πŸ’€

πŸ‘‘ AUTHOR πŸ‘‘

MongoDB, Inc β€” the main characters ✨


2009-present, MongoDB, Inc. β€” periodt, all rights reserved energy πŸŽ€


and that's the whole page, bestie! cute lil sign-off: this was libmongoc version 2.5.6, dated Oct 09, 2024 β€” go forth and not free that client πŸ’…πŸ¦‹

πŸ“¦ where this page comes from