MCPcopy Create free account
hub / github.com/apache/brpc / getBucketToCollectionManifest

Method getBucketToCollectionManifest

src/brpc/couchbase.cpp:71–85  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69}
70
71bool brpc::CouchbaseManifestManager::getBucketToCollectionManifest(
72 std::string server, std::string bucket,
73 CouchbaseManifestManager::CollectionManifest* manifest) {
74 SharedLock read_lock(rw_bucket_to_collection_manifest_mutex_);
75 auto it1 = bucket_to_collection_manifest_.find(server);
76 if (it1 == bucket_to_collection_manifest_.end()) {
77 return false;
78 }
79 auto it2 = it1->second.find(bucket);
80 if (it2 == it1->second.end()) {
81 return false;
82 }
83 *manifest = it2->second;
84 return true;
85}
86
87bool brpc::CouchbaseManifestManager::getManifestToCollectionId(
88 CouchbaseManifestManager::CollectionManifest* manifest, std::string scope,

Callers 3

selectBucketMethod · 0.80

Calls 2

findMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected