]> git.proxmox.com Git - ceph.git/blob - ceph/src/rocksdb/util/file_util.h
bump version to 15.2.11-pve1
[ceph.git] / ceph / src / rocksdb / util / file_util.h
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 #pragma once
7 #include <string>
8
9 #include "options/db_options.h"
10 #include "rocksdb/env.h"
11 #include "rocksdb/status.h"
12 #include "rocksdb/types.h"
13 #include "util/filename.h"
14
15 namespace rocksdb {
16 // use_fsync maps to options.use_fsync, which determines the way that
17 // the file is synced after copying.
18 extern Status CopyFile(Env* env, const std::string& source,
19 const std::string& destination, uint64_t size,
20 bool use_fsync);
21
22 extern Status CreateFile(Env* env, const std::string& destination,
23 const std::string& contents, bool use_fsync);
24
25 extern Status DeleteDBFile(const ImmutableDBOptions* db_options,
26 const std::string& fname,
27 const std::string& path_to_sync,
28 const bool force_bg = false);
29
30 } // namespace rocksdb