MCPcopy Create free account
hub / github.com/FoundationDB/fdb-document-layer / call

Method call

src/ExtCmd.actor.cpp:314–332  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

312struct IsMasterCmd {
313 static const char* name;
314 static Future<Reference<ExtMsgReply>> call(Reference<ExtConnection> nmc,
315 Reference<ExtMsgQuery> query,
316 Reference<ExtMsgReply> reply) {
317 reply->addDocument(BSON(
318 // clang-format off
319 "ismaster" << true <<
320 "maxBsonObjectSize" << 16777216 <<
321 "maxMessageSizeBytes" << 48000000 <<
322 // FIXME: BM: Just like other fields, going with defaults. We should revisit these numbers.
323 "maxWriteBatchSize" << 1000 <<
324 "localTime" << bson::Date_t(timer() * 1000) <<
325 "minWireVersion" << EXT_MIN_WIRE_VERSION <<
326 "maxWireVersion" << EXT_MAX_WIRE_VERSION <<
327 "ok" << 1.0
328 // clang-format on
329 ));
330
331 return reply;
332 }
333};
334REGISTER_CMD(IsMasterCmd, "ismaster");
335

Callers

nothing calls this directly

Calls 1

addDocumentMethod · 0.80

Tested by

no test coverage detected