/src/rocksdb/db/blob/blob_fetcher.cc
Line | Count | Source |
1 | | // Copyright (c) 2011-present, Facebook, Inc. All rights reserved. |
2 | | // This source code is licensed under both the GPLv2 (found in the |
3 | | // COPYING file in the root directory) and Apache 2.0 License |
4 | | // (found in the LICENSE.Apache file in the root directory). |
5 | | |
6 | | #include "db/blob/blob_fetcher.h" |
7 | | |
8 | | #include "db/version_set.h" |
9 | | |
10 | | namespace ROCKSDB_NAMESPACE { |
11 | | |
12 | | Status BlobFetcher::FetchBlob(const Slice& user_key, |
13 | | const Slice& blob_index_slice, |
14 | | FilePrefetchBuffer* prefetch_buffer, |
15 | | PinnableSlice* blob_value, |
16 | 0 | uint64_t* bytes_read) const { |
17 | 0 | assert(version_); |
18 | |
|
19 | 0 | return version_->GetBlob(read_options_, user_key, blob_index_slice, |
20 | 0 | prefetch_buffer, blob_value, bytes_read); |
21 | 0 | } |
22 | | |
23 | | Status BlobFetcher::FetchBlob(const Slice& user_key, |
24 | | const BlobIndex& blob_index, |
25 | | FilePrefetchBuffer* prefetch_buffer, |
26 | | PinnableSlice* blob_value, |
27 | 0 | uint64_t* bytes_read) const { |
28 | 0 | assert(version_); |
29 | |
|
30 | 0 | return version_->GetBlob(read_options_, user_key, blob_index, prefetch_buffer, |
31 | 0 | blob_value, bytes_read); |
32 | 0 | } |
33 | | |
34 | | } // namespace ROCKSDB_NAMESPACE |