MCPcopy Create free account
hub / github.com/apple/foundationdb / getRange

Function getRange

fdbclient/PaxosConfigTransaction.actor.cpp:380–391  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

378 Future<Optional<Value>> get(Key const& key) { return get(this, key); }
379
380 Future<RangeResult> getRange(KeyRangeRef keys) {
381 if (keys == configClassKeys) {
382 return getConfigClasses(this);
383 } else if (keys == globalConfigKnobKeys) {
384 return getKnobs(this, {});
385 } else if (configKnobKeys.contains(keys) && keys.singleKeyRange()) {
386 const auto configClass = keys.begin.removePrefix(configKnobKeys.begin);
387 return getKnobs(this, configClass);
388 } else {
389 throw invalid_config_db_range_read();
390 }
391 }
392
393 Future<Void> onError(Error const& e) { return onError(this, e); }
394

Callers

nothing calls this directly

Calls 4

getConfigClassesFunction · 0.85
singleKeyRangeMethod · 0.80
containsMethod · 0.45
removePrefixMethod · 0.45

Tested by

no test coverage detected