|
8 | 8 |
|
9 | 9 | // The build script may replace these values with real values based
|
10 | 10 | // on whether or not GIT is available and the platform settings
|
11 |
| -static const std::string rocksdb_build_git_sha = "ae8fb3e5000e46d8d4c9dbf3a36019c0aaceebff"; |
12 |
| -static const std::string rocksdb_build_git_tag = "rocksdb_build_git_tag:v9.10.0"; |
| 11 | +static const std::string rocksdb_build_git_sha = "68b2d941be2d273067aeb7e14ccd090d1512c426"; |
| 12 | +static const std::string rocksdb_build_git_tag = "rocksdb_build_git_tag:v9.11.1"; |
13 | 13 | #define HAS_GIT_CHANGES 0
|
14 | 14 | #if HAS_GIT_CHANGES == 0
|
15 | 15 | // If HAS_GIT_CHANGES is 0, the GIT date is used.
|
16 | 16 | // Use the time the branch/tag was last modified
|
17 |
| -static const std::string rocksdb_build_date = "rocksdb_build_date:2024-12-16 12:45:14"; |
| 17 | +static const std::string rocksdb_build_date = "rocksdb_build_date:2025-03-05 22:15:17"; |
18 | 18 | #else
|
19 | 19 | // If HAS_GIT_CHANGES is > 0, the branch/tag has modifications.
|
20 | 20 | // Use the time the build was created.
|
21 |
| -static const std::string rocksdb_build_date = "rocksdb_build_date:2024-12-16 12:45:14"; |
| 21 | +static const std::string rocksdb_build_date = "rocksdb_build_date:2025-03-05 22:15:17"; |
22 | 22 | #endif
|
23 | 23 |
|
24 | 24 | std::unordered_map<std::string, ROCKSDB_NAMESPACE::RegistrarFunc> ROCKSDB_NAMESPACE::ObjectRegistry::builtins_ = {};
|
25 | 25 |
|
26 |
| -extern "C" bool RocksDbIOUringEnable() { |
| 26 | +extern "C" bool RocksDbIOUringEnable() |
| 27 | +{ |
27 | 28 | return true;
|
28 | 29 | }
|
29 | 30 |
|
30 |
| -namespace ROCKSDB_NAMESPACE { |
31 |
| -static void AddProperty(std::unordered_map<std::string, std::string> *props, const std::string& name) { |
32 |
| - size_t colon = name.find(":"); |
33 |
| - if (colon != std::string::npos && colon > 0 && colon < name.length() - 1) { |
34 |
| - // If we found a "@:", then this property was a build-time substitution that failed. Skip it |
35 |
| - size_t at = name.find("@", colon); |
36 |
| - if (at != colon + 1) { |
37 |
| - // Everything before the colon is the name, after is the value |
38 |
| - (*props)[name.substr(0, colon)] = name.substr(colon + 1); |
| 31 | +namespace ROCKSDB_NAMESPACE |
| 32 | +{ |
| 33 | + static void AddProperty(std::unordered_map<std::string, std::string> *props, const std::string &name) |
| 34 | + { |
| 35 | + size_t colon = name.find(":"); |
| 36 | + if (colon != std::string::npos && colon > 0 && colon < name.length() - 1) |
| 37 | + { |
| 38 | + // If we found a "@:", then this property was a build-time substitution that failed. Skip it |
| 39 | + size_t at = name.find("@", colon); |
| 40 | + if (at != colon + 1) |
| 41 | + { |
| 42 | + // Everything before the colon is the name, after is the value |
| 43 | + (*props)[name.substr(0, colon)] = name.substr(colon + 1); |
| 44 | + } |
39 | 45 | }
|
40 | 46 | }
|
41 |
| -} |
42 | 47 |
|
43 |
| -static std::unordered_map<std::string, std::string>* LoadPropertiesSet() { |
44 |
| - auto * properties = new std::unordered_map<std::string, std::string>(); |
45 |
| - AddProperty(properties, rocksdb_build_git_sha); |
46 |
| - AddProperty(properties, rocksdb_build_git_tag); |
47 |
| - AddProperty(properties, rocksdb_build_date); |
48 |
| - return properties; |
49 |
| -} |
| 48 | + static std::unordered_map<std::string, std::string> *LoadPropertiesSet() |
| 49 | + { |
| 50 | + auto *properties = new std::unordered_map<std::string, std::string>(); |
| 51 | + AddProperty(properties, rocksdb_build_git_sha); |
| 52 | + AddProperty(properties, rocksdb_build_git_tag); |
| 53 | + AddProperty(properties, rocksdb_build_date); |
| 54 | + return properties; |
| 55 | + } |
50 | 56 |
|
51 |
| -const std::unordered_map<std::string, std::string>& GetRocksBuildProperties() { |
52 |
| - static std::unique_ptr<std::unordered_map<std::string, std::string>> props(LoadPropertiesSet()); |
53 |
| - return *props; |
54 |
| -} |
| 57 | + const std::unordered_map<std::string, std::string> &GetRocksBuildProperties() |
| 58 | + { |
| 59 | + static std::unique_ptr<std::unordered_map<std::string, std::string>> props(LoadPropertiesSet()); |
| 60 | + return *props; |
| 61 | + } |
55 | 62 |
|
56 |
| -std::string GetRocksVersionAsString(bool with_patch) { |
57 |
| - std::string version = std::to_string(ROCKSDB_MAJOR) + "." + std::to_string(ROCKSDB_MINOR); |
58 |
| - if (with_patch) { |
59 |
| - return version + "." + std::to_string(ROCKSDB_PATCH); |
60 |
| - } else { |
61 |
| - return version; |
62 |
| - } |
63 |
| -} |
| 63 | + std::string GetRocksVersionAsString(bool with_patch) |
| 64 | + { |
| 65 | + std::string version = std::to_string(ROCKSDB_MAJOR) + "." + std::to_string(ROCKSDB_MINOR); |
| 66 | + if (with_patch) |
| 67 | + { |
| 68 | + return version + "." + std::to_string(ROCKSDB_PATCH); |
| 69 | + } |
| 70 | + else |
| 71 | + { |
| 72 | + return version; |
| 73 | + } |
| 74 | + } |
64 | 75 |
|
65 |
| -std::string GetRocksBuildInfoAsString(const std::string& program, bool verbose) { |
66 |
| - std::string info = program + " (RocksDB) " + GetRocksVersionAsString(true); |
67 |
| - if (verbose) { |
68 |
| - for (const auto& it : GetRocksBuildProperties()) { |
69 |
| - info.append("\n "); |
70 |
| - info.append(it.first); |
71 |
| - info.append(": "); |
72 |
| - info.append(it.second); |
| 76 | + std::string GetRocksBuildInfoAsString(const std::string &program, bool verbose) |
| 77 | + { |
| 78 | + std::string info = program + " (RocksDB) " + GetRocksVersionAsString(true); |
| 79 | + if (verbose) |
| 80 | + { |
| 81 | + for (const auto &it : GetRocksBuildProperties()) |
| 82 | + { |
| 83 | + info.append("\n "); |
| 84 | + info.append(it.first); |
| 85 | + info.append(": "); |
| 86 | + info.append(it.second); |
| 87 | + } |
73 | 88 | }
|
| 89 | + return info; |
74 | 90 | }
|
75 |
| - return info; |
76 |
| -} |
77 | 91 | } // namespace ROCKSDB_NAMESPACE
|
0 commit comments