MCPcopy Create free account
hub / github.com/LadybugDB/ladybug / getCreateIndexWalThreshold

Function getCreateIndexWalThreshold

src/processor/operator/ddl/create_index.cpp:25–36  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

23static constexpr uint64_t DEFAULT_CREATE_INDEX_WAL_THRESHOLD = 256ull * 1024 * 1024;
24
25static uint64_t getCreateIndexWalThreshold() {
26 const auto* threshold = std::getenv("LBUG_CREATE_INDEX_WAL_THRESHOLD"); // NOLINT(*-mt-unsafe)
27 if (threshold == nullptr || threshold[0] == '\0') {
28 return DEFAULT_CREATE_INDEX_WAL_THRESHOLD;
29 }
30 char* end = nullptr;
31 const auto parsed = std::strtoull(threshold, &end, 10);
32 if (end == threshold || *end != '\0') {
33 return DEFAULT_CREATE_INDEX_WAL_THRESHOLD;
34 }
35 return parsed;
36}
37
38static std::string getExistingIndexName(Catalog* catalog, transaction::Transaction* transaction,
39 common::table_id_t tableID, common::property_id_t propertyID) {

Callers 1

executeInternalMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected