MONGOC_CURSOR_GET_HINT(3)
π MONGOC_CURSOR_GET_HINT(3) π
okay bestie, so this one's a libmongoc page and I need you to brace yourself because it starts with the saddest news π
β οΈ WARNING: deprecated since version1.28.0β usemongoc_cursor_get_server_id()instead. like, she's retired. she served her time. use the other one, fr fr.
β¨ SYNOPSIS β¨
uint32_t
mongoc_cursor_get_hint (const mongoc_cursor_t *cursor);
π PARAMETERS π
cursorβ amongoc_cursor_t. that's it, that's the whole list, she's low maintenance π
πΈ DESCRIPTION πΈ
okay so what does she do? she hands you back the opaque id of the server used for the operation. the whole point. the tea. π«
and listen, about the name β the function is called hint because that's the old term, kept around for backward compatibility only. the way that we've fully rebranded and now call this number a "server id" π so if you're out here wondering why it says hint, it's giving legacy, iykyk.
here's the important bit though: this number is zero until the driver actually uses a server β either when it's executing the find operation, or when mongoc_cursor_set_server_id() gets called. so if you call this thing too early and get a 0, that's not a bug bestie, that's just her not having picked a server yet π
π AUTHOR π
MongoDB, Inc β the icons themselves β¨
π COPYRIGHT π
2009-present, MongoDB, Inc. β iconic behavior, honestly π
and that's the whole page!! mwah, go call mongoc_cursor_get_server_id() instead, okay?? π
version 1.30.13 Β· dated Oct 09, 2026 Β· MONGOC_CURSOR_GET_HINT(3) β slay, bye π¦ππ
π¦ where this page comes from
- fedora 43: mongo-c-driver-devel 1.30.13-1.fc43 Β· Apache-2.0 AND ISC AND MIT AND Zlib
- fedora 43: mongo-c-driver-devel 1.30.13-1.fc43 Β· Apache-2.0 AND ISC AND MIT AND Zlib
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms