]>
git.proxmox.com Git - ceph.git/blob - ceph/src/rocksdb/db/experimental.cc
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).
6 #include "rocksdb/experimental.h"
8 #include "db/db_impl/db_impl.h"
10 namespace ROCKSDB_NAMESPACE
{
11 namespace experimental
{
15 Status
SuggestCompactRange(DB
* db
, ColumnFamilyHandle
* column_family
,
16 const Slice
* begin
, const Slice
* end
) {
18 return Status::InvalidArgument("DB is empty");
21 return db
->SuggestCompactRange(column_family
, begin
, end
);
24 Status
PromoteL0(DB
* db
, ColumnFamilyHandle
* column_family
, int target_level
) {
26 return Status::InvalidArgument("Didn't recognize DB object");
28 return db
->PromoteL0(column_family
, target_level
);
33 Status
SuggestCompactRange(DB
* /*db*/, ColumnFamilyHandle
* /*column_family*/,
34 const Slice
* /*begin*/, const Slice
* /*end*/) {
35 return Status::NotSupported("Not supported in RocksDB LITE");
38 Status
PromoteL0(DB
* /*db*/, ColumnFamilyHandle
* /*column_family*/,
39 int /*target_level*/) {
40 return Status::NotSupported("Not supported in RocksDB LITE");
43 #endif // ROCKSDB_LITE
45 Status
SuggestCompactRange(DB
* db
, const Slice
* begin
, const Slice
* end
) {
46 return SuggestCompactRange(db
, db
->DefaultColumnFamily(), begin
, end
);
49 } // namespace experimental
50 } // namespace ROCKSDB_NAMESPACE