From 8617fbf041a7e9f1d2addaf0d0917b03ce238dc2 Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 22:54:48 -0400 Subject: [PATCH 1/9] Move common/ domain: types, constants, config, logger, clock, concurrency, debug_utils, utils, value_type - git mv headers to include/common/ and sources to src/common/ - Update all #include directives across include/, src/, tests/, bench/ - Add per-directory src/common/CMakeLists.txt with target_sources() - Refactor root CMakeLists.txt to use add_subdirectory(src/common) Made-with: Cursor --- CMakeLists.txt | 5 ++--- bench/tundra_runner.cpp | 2 +- include/array_arena.hpp | 2 +- include/array_ref.hpp | 4 ++-- include/arrow_utils.hpp | 2 +- include/{ => common}/clock.hpp | 0 include/{ => common}/concurrency.hpp | 0 include/{ => common}/config.hpp | 0 include/{ => common}/constants.hpp | 0 include/{ => common}/debug_utils.hpp | 0 include/{ => common}/logger.hpp | 0 include/{ => common}/types.hpp | 0 include/{ => common}/utils.hpp | 6 +++--- include/{ => common}/value_type.hpp | 0 include/core.hpp | 6 +++--- include/edge.hpp | 4 ++-- include/edge_store.hpp | 4 ++-- include/edge_view.hpp | 2 +- include/field_update.hpp | 2 +- include/free_list_arena.hpp | 2 +- include/map_arena.hpp | 4 ++-- include/map_ref.hpp | 4 ++-- include/metadata.hpp | 4 ++-- include/node.hpp | 6 +++--- include/node_arena.hpp | 4 ++-- include/node_view.hpp | 2 +- include/query.hpp | 2 +- include/row.hpp | 6 +++--- include/schema.hpp | 4 ++-- include/schema_layout.hpp | 2 +- include/shard.hpp | 2 +- include/storage.hpp | 2 +- include/string_arena.hpp | 2 +- include/string_ref.hpp | 2 +- include/type_descriptor.hpp | 2 +- src/arrow_utils.cpp | 2 +- src/common/CMakeLists.txt | 6 ++++++ src/{ => common}/clock.cpp | 2 +- src/{ => common}/types.cpp | 2 +- src/{ => common}/utils.cpp | 2 +- src/core.cpp | 4 ++-- src/edge_store.cpp | 4 ++-- src/join.cpp | 4 ++-- src/metadata.cpp | 4 ++-- src/query.cpp | 2 +- src/query_execution.cpp | 6 +++--- src/row.cpp | 2 +- src/shard.cpp | 4 ++-- src/snapshot_manager.cpp | 4 ++-- src/storage.cpp | 4 ++-- src/tundra_shell.cpp | 8 ++++---- tests/array_query_test.cpp | 4 ++-- tests/benchmark_test.cpp | 4 ++-- tests/concurrency_test.cpp | 2 +- tests/concurrent_set_stress_test.cpp | 2 +- tests/database_test.cpp | 2 +- tests/join_test.cpp | 4 ++-- tests/map_arena_test.cpp | 4 ++-- tests/node_arena_test.cpp | 2 +- tests/node_test.cpp | 4 ++-- tests/sharding_test.cpp | 2 +- tests/snapshot_test.cpp | 2 +- tests/string_ref_concurrent_test.cpp | 2 +- tests/temporal_query_test.cpp | 4 ++-- tests/type_conversion_test.cpp | 2 +- tests/type_system_test.cpp | 2 +- tests/update_query_join_test.cpp | 2 +- tests/update_query_test.cpp | 2 +- tests/where_expression_test.cpp | 4 ++-- tests/where_pushdown_join_test.cpp | 4 ++-- 70 files changed, 104 insertions(+), 99 deletions(-) rename include/{ => common}/clock.hpp (100%) rename include/{ => common}/concurrency.hpp (100%) rename include/{ => common}/config.hpp (100%) rename include/{ => common}/constants.hpp (100%) rename include/{ => common}/debug_utils.hpp (100%) rename include/{ => common}/logger.hpp (100%) rename include/{ => common}/types.hpp (100%) rename include/{ => common}/utils.hpp (99%) rename include/{ => common}/value_type.hpp (100%) create mode 100644 src/common/CMakeLists.txt rename src/{ => common}/clock.cpp (90%) rename src/{ => common}/types.cpp (96%) rename src/{ => common}/utils.cpp (98%) diff --git a/CMakeLists.txt b/CMakeLists.txt index a3f49b4..eeaac0a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -245,13 +245,12 @@ add_library(core src/snapshot_manager.cpp src/edge_store.cpp src/table_info.cpp - src/utils.cpp src/schema.cpp src/arrow_utils.cpp - src/types.cpp - src/clock.cpp ) +add_subdirectory(src/common) + target_include_directories(core PUBLIC $ diff --git a/bench/tundra_runner.cpp b/bench/tundra_runner.cpp index bb2a495..d237442 100644 --- a/bench/tundra_runner.cpp +++ b/bench/tundra_runner.cpp @@ -8,7 +8,7 @@ #include "../include/core.hpp" #include "../include/query.hpp" -#include "../include/types.hpp" +#include "common/types.hpp" using namespace tundradb; diff --git a/include/array_arena.hpp b/include/array_arena.hpp index 7bd1330..5c42437 100644 --- a/include/array_arena.hpp +++ b/include/array_arena.hpp @@ -12,7 +12,7 @@ #include "array_ref.hpp" #include "free_list_arena.hpp" #include "string_ref.hpp" -#include "value_type.hpp" +#include "common/value_type.hpp" namespace tundradb { diff --git a/include/array_ref.hpp b/include/array_ref.hpp index 1c2e9dd..6b64899 100644 --- a/include/array_ref.hpp +++ b/include/array_ref.hpp @@ -7,8 +7,8 @@ #include #include -#include "constants.hpp" -#include "value_type.hpp" +#include "common/constants.hpp" +#include "common/value_type.hpp" namespace tundradb { diff --git a/include/arrow_utils.hpp b/include/arrow_utils.hpp index 50c2470..684a75b 100644 --- a/include/arrow_utils.hpp +++ b/include/arrow_utils.hpp @@ -11,7 +11,7 @@ #include #include -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/clock.hpp b/include/common/clock.hpp similarity index 100% rename from include/clock.hpp rename to include/common/clock.hpp diff --git a/include/concurrency.hpp b/include/common/concurrency.hpp similarity index 100% rename from include/concurrency.hpp rename to include/common/concurrency.hpp diff --git a/include/config.hpp b/include/common/config.hpp similarity index 100% rename from include/config.hpp rename to include/common/config.hpp diff --git a/include/constants.hpp b/include/common/constants.hpp similarity index 100% rename from include/constants.hpp rename to include/common/constants.hpp diff --git a/include/debug_utils.hpp b/include/common/debug_utils.hpp similarity index 100% rename from include/debug_utils.hpp rename to include/common/debug_utils.hpp diff --git a/include/logger.hpp b/include/common/logger.hpp similarity index 100% rename from include/logger.hpp rename to include/common/logger.hpp diff --git a/include/types.hpp b/include/common/types.hpp similarity index 100% rename from include/types.hpp rename to include/common/types.hpp diff --git a/include/utils.hpp b/include/common/utils.hpp similarity index 99% rename from include/utils.hpp rename to include/common/utils.hpp index 2a8f9ea..e973ca4 100644 --- a/include/utils.hpp +++ b/include/common/utils.hpp @@ -16,11 +16,11 @@ #include #include "arrow_utils.hpp" -#include "constants.hpp" -#include "logger.hpp" +#include "common/constants.hpp" +#include "common/logger.hpp" #include "node.hpp" #include "query.hpp" -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/value_type.hpp b/include/common/value_type.hpp similarity index 100% rename from include/value_type.hpp rename to include/common/value_type.hpp diff --git a/include/core.hpp b/include/core.hpp index 3ccf2f2..ca30e0d 100644 --- a/include/core.hpp +++ b/include/core.hpp @@ -10,10 +10,10 @@ #include #include "arrow_utils.hpp" -#include "config.hpp" +#include "common/config.hpp" #include "edge_store.hpp" #include "field_update.hpp" -#include "logger.hpp" +#include "common/logger.hpp" #include "metadata.hpp" #include "node.hpp" #include "query.hpp" @@ -22,7 +22,7 @@ #include "shard.hpp" #include "snapshot_manager.hpp" #include "storage.hpp" -#include "utils.hpp" +#include "common/utils.hpp" namespace tundradb { diff --git a/include/edge.hpp b/include/edge.hpp index 425455f..b522b5f 100644 --- a/include/edge.hpp +++ b/include/edge.hpp @@ -7,13 +7,13 @@ #include #include -#include "constants.hpp" +#include "common/constants.hpp" #include "edge_view.hpp" #include "node_arena.hpp" #include "schema.hpp" #include "schema_layout.hpp" #include "temporal_context.hpp" -#include "types.hpp" +#include "common/types.hpp" #include "update_type.hpp" namespace tundradb { diff --git a/include/edge_store.hpp b/include/edge_store.hpp index 96a8b24..a0f00c6 100644 --- a/include/edge_store.hpp +++ b/include/edge_store.hpp @@ -11,12 +11,12 @@ #include #include -#include "concurrency.hpp" +#include "common/concurrency.hpp" #include "edge.hpp" #include "node_arena.hpp" #include "schema.hpp" #include "schema_layout.hpp" -#include "utils.hpp" +#include "common/utils.hpp" namespace tundradb { diff --git a/include/edge_view.hpp b/include/edge_view.hpp index e21b824..4b8312c 100644 --- a/include/edge_view.hpp +++ b/include/edge_view.hpp @@ -7,7 +7,7 @@ #include "node_arena.hpp" #include "schema.hpp" -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/field_update.hpp b/include/field_update.hpp index bc13092..03ff966 100644 --- a/include/field_update.hpp +++ b/include/field_update.hpp @@ -7,7 +7,7 @@ #include #include "schema.hpp" -#include "types.hpp" +#include "common/types.hpp" #include "update_type.hpp" namespace tundradb { diff --git a/include/free_list_arena.hpp b/include/free_list_arena.hpp index f13af70..1048e73 100644 --- a/include/free_list_arena.hpp +++ b/include/free_list_arena.hpp @@ -10,7 +10,7 @@ #include #include -#include "logger.hpp" +#include "common/logger.hpp" #include "mem_arena.hpp" #include "mem_utils.hpp" diff --git a/include/map_arena.hpp b/include/map_arena.hpp index dddfccf..0e967a8 100644 --- a/include/map_arena.hpp +++ b/include/map_arena.hpp @@ -13,8 +13,8 @@ #include "free_list_arena.hpp" #include "map_ref.hpp" #include "string_ref.hpp" -#include "types.hpp" -#include "value_type.hpp" +#include "common/types.hpp" +#include "common/value_type.hpp" namespace tundradb { diff --git a/include/map_ref.hpp b/include/map_ref.hpp index d0da34d..084bd2c 100644 --- a/include/map_ref.hpp +++ b/include/map_ref.hpp @@ -7,9 +7,9 @@ #include #include -#include "constants.hpp" +#include "common/constants.hpp" #include "string_ref.hpp" -#include "value_type.hpp" +#include "common/value_type.hpp" namespace tundradb { diff --git a/include/metadata.hpp b/include/metadata.hpp index 3738ec3..b23fb2d 100644 --- a/include/metadata.hpp +++ b/include/metadata.hpp @@ -13,10 +13,10 @@ #include "file_utils.hpp" #include "json.hpp" #include "llvm/ADT/SmallVector.h" -#include "logger.hpp" +#include "common/logger.hpp" #include "schema.hpp" #include "type_descriptor.hpp" -#include "types.hpp" +#include "common/types.hpp" using namespace std::string_literals; diff --git a/include/node.hpp b/include/node.hpp index de31098..d01f934 100644 --- a/include/node.hpp +++ b/include/node.hpp @@ -6,13 +6,13 @@ #include #include -#include "constants.hpp" -#include "logger.hpp" +#include "common/constants.hpp" +#include "common/logger.hpp" #include "node_arena.hpp" #include "node_view.hpp" #include "schema.hpp" #include "temporal_context.hpp" -#include "types.hpp" +#include "common/types.hpp" #include "update_type.hpp" namespace tundradb { diff --git a/include/node_arena.hpp b/include/node_arena.hpp index 19d7f9d..f2e09d1 100644 --- a/include/node_arena.hpp +++ b/include/node_arena.hpp @@ -12,7 +12,7 @@ #include #include "array_arena.hpp" -#include "clock.hpp" +#include "common/clock.hpp" #include "field_update.hpp" #include "free_list_arena.hpp" #include "map_arena.hpp" @@ -20,7 +20,7 @@ #include "memory_arena.hpp" #include "schema_layout.hpp" #include "string_arena.hpp" -#include "types.hpp" +#include "common/types.hpp" #include "update_type.hpp" namespace tundradb { diff --git a/include/node_view.hpp b/include/node_view.hpp index 890ba1d..97b5357 100644 --- a/include/node_view.hpp +++ b/include/node_view.hpp @@ -8,7 +8,7 @@ #include "node_arena.hpp" #include "schema.hpp" #include "temporal_context.hpp" -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/query.hpp b/include/query.hpp index c86aa32..fb0dc16 100644 --- a/include/query.hpp +++ b/include/query.hpp @@ -21,7 +21,7 @@ #include "node.hpp" #include "schema.hpp" #include "temporal_context.hpp" -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/row.hpp b/include/row.hpp index 5a27832..cb481fe 100644 --- a/include/row.hpp +++ b/include/row.hpp @@ -12,12 +12,12 @@ #include #include -#include "constants.hpp" +#include "common/constants.hpp" #include "edge.hpp" -#include "logger.hpp" +#include "common/logger.hpp" #include "node.hpp" #include "query.hpp" -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/schema.hpp b/include/schema.hpp index 5e16d22..084e6b6 100644 --- a/include/schema.hpp +++ b/include/schema.hpp @@ -12,9 +12,9 @@ #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/SmallVector.h" -#include "logger.hpp" +#include "common/logger.hpp" #include "type_descriptor.hpp" -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/schema_layout.hpp b/include/schema_layout.hpp index be8cb0b..af7809a 100644 --- a/include/schema_layout.hpp +++ b/include/schema_layout.hpp @@ -15,7 +15,7 @@ #include "mem_utils.hpp" #include "schema.hpp" #include "type_descriptor.hpp" -#include "types.hpp" +#include "common/types.hpp" namespace tundradb { diff --git a/include/shard.hpp b/include/shard.hpp index f2411ff..b92f998 100644 --- a/include/shard.hpp +++ b/include/shard.hpp @@ -13,7 +13,7 @@ #include #include -#include "config.hpp" +#include "common/config.hpp" #include "field_update.hpp" #include "node.hpp" #include "schema.hpp" diff --git a/include/storage.hpp b/include/storage.hpp index 932c549..7ec4a9d 100644 --- a/include/storage.hpp +++ b/include/storage.hpp @@ -6,7 +6,7 @@ #include #include -#include "config.hpp" +#include "common/config.hpp" #include "edge.hpp" #include "metadata.hpp" diff --git a/include/string_arena.hpp b/include/string_arena.hpp index e144206..0cd95ef 100644 --- a/include/string_arena.hpp +++ b/include/string_arena.hpp @@ -16,7 +16,7 @@ #include "free_list_arena.hpp" #include "memory_arena.hpp" #include "string_ref.hpp" // StringRef class -#include "value_type.hpp" // ValueType enum and helpers +#include "common/value_type.hpp" // ValueType enum and helpers namespace tundradb { diff --git a/include/string_ref.hpp b/include/string_ref.hpp index cd8f7c8..a554ecf 100644 --- a/include/string_ref.hpp +++ b/include/string_ref.hpp @@ -7,7 +7,7 @@ #include #include -#include "constants.hpp" +#include "common/constants.hpp" namespace tundradb { diff --git a/include/type_descriptor.hpp b/include/type_descriptor.hpp index abe79a4..2ef050a 100644 --- a/include/type_descriptor.hpp +++ b/include/type_descriptor.hpp @@ -4,7 +4,7 @@ #include #include -#include "value_type.hpp" +#include "common/value_type.hpp" namespace tundradb { diff --git a/src/arrow_utils.cpp b/src/arrow_utils.cpp index d6b32e3..69db47a 100644 --- a/src/arrow_utils.cpp +++ b/src/arrow_utils.cpp @@ -14,7 +14,7 @@ #include #include "arrow_map_union_types.hpp" -#include "logger.hpp" +#include "common/logger.hpp" #include "node.hpp" #include "query.hpp" #include "schema.hpp" diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt new file mode 100644 index 0000000..bcc110b --- /dev/null +++ b/src/common/CMakeLists.txt @@ -0,0 +1,6 @@ +target_sources(core + PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/clock.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/types.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/utils.cpp +) diff --git a/src/clock.cpp b/src/common/clock.cpp similarity index 90% rename from src/clock.cpp rename to src/common/clock.cpp index 0f4d9cc..7df68fa 100644 --- a/src/clock.cpp +++ b/src/common/clock.cpp @@ -1,4 +1,4 @@ -#include "clock.hpp" +#include "common/clock.hpp" namespace tundradb { diff --git a/src/types.cpp b/src/common/types.cpp similarity index 96% rename from src/types.cpp rename to src/common/types.cpp index 116dead..3951074 100644 --- a/src/types.cpp +++ b/src/common/types.cpp @@ -1,4 +1,4 @@ -#include "types.hpp" +#include "common/types.hpp" #include "string_arena.hpp" diff --git a/src/utils.cpp b/src/common/utils.cpp similarity index 98% rename from src/utils.cpp rename to src/common/utils.cpp index 17a283e..f57cd34 100644 --- a/src/utils.cpp +++ b/src/common/utils.cpp @@ -1,4 +1,4 @@ -#include "utils.hpp" +#include "common/utils.hpp" #include diff --git a/src/core.cpp b/src/core.cpp index 1d8f3e5..006a074 100644 --- a/src/core.cpp +++ b/src/core.cpp @@ -22,10 +22,10 @@ #include "arrow_utils.hpp" #include "join.hpp" -#include "logger.hpp" +#include "common/logger.hpp" #include "row.hpp" #include "temporal_context.hpp" -#include "utils.hpp" +#include "common/utils.hpp" namespace fs = std::filesystem; diff --git a/src/edge_store.cpp b/src/edge_store.cpp index 254e6c7..fed3081 100644 --- a/src/edge_store.cpp +++ b/src/edge_store.cpp @@ -3,9 +3,9 @@ #include #include -#include "constants.hpp" +#include "common/constants.hpp" #include "json.hpp" -#include "logger.hpp" +#include "common/logger.hpp" #include "metadata.hpp" namespace tundradb { diff --git a/src/join.cpp b/src/join.cpp index e6fb207..005e193 100644 --- a/src/join.cpp +++ b/src/join.cpp @@ -1,7 +1,7 @@ #include "join.hpp" -#include "logger.hpp" -#include "utils.hpp" +#include "common/logger.hpp" +#include "common/utils.hpp" namespace tundradb { diff --git a/src/metadata.cpp b/src/metadata.cpp index f49cc02..dbb9c00 100644 --- a/src/metadata.cpp +++ b/src/metadata.cpp @@ -7,8 +7,8 @@ #include #include "json.hpp" -#include "logger.hpp" -#include "utils.hpp" +#include "common/logger.hpp" +#include "common/utils.hpp" namespace tundradb { diff --git a/src/query.cpp b/src/query.cpp index 95067bc..3059254 100644 --- a/src/query.cpp +++ b/src/query.cpp @@ -6,7 +6,7 @@ #include #include "edge.hpp" -#include "logger.hpp" +#include "common/logger.hpp" namespace tundradb { diff --git a/src/query_execution.cpp b/src/query_execution.cpp index 5fa1d3e..a09325d 100644 --- a/src/query_execution.cpp +++ b/src/query_execution.cpp @@ -5,10 +5,10 @@ #include "arrow_map_union_types.hpp" #include "arrow_utils.hpp" -#include "constants.hpp" +#include "common/constants.hpp" #include "edge_store.hpp" -#include "logger.hpp" -#include "utils.hpp" +#include "common/logger.hpp" +#include "common/utils.hpp" namespace tundradb { diff --git a/src/row.cpp b/src/row.cpp index df98663..ee1f091 100644 --- a/src/row.cpp +++ b/src/row.cpp @@ -1,6 +1,6 @@ #include "row.hpp" -#include "logger.hpp" +#include "common/logger.hpp" namespace tundradb { diff --git a/src/shard.cpp b/src/shard.cpp index b934ba1..048c2fc 100644 --- a/src/shard.cpp +++ b/src/shard.cpp @@ -1,7 +1,7 @@ #include "shard.hpp" -#include "logger.hpp" -#include "utils.hpp" +#include "common/logger.hpp" +#include "common/utils.hpp" namespace tundradb { diff --git a/src/snapshot_manager.cpp b/src/snapshot_manager.cpp index cdee288..36e986b 100644 --- a/src/snapshot_manager.cpp +++ b/src/snapshot_manager.cpp @@ -1,11 +1,11 @@ #include "snapshot_manager.hpp" #include "edge.hpp" -#include "logger.hpp" +#include "common/logger.hpp" #include "node.hpp" #include "shard.hpp" #include "storage.hpp" -#include "utils.hpp" +#include "common/utils.hpp" namespace tundradb { diff --git a/src/storage.cpp b/src/storage.cpp index b14ea78..964998e 100644 --- a/src/storage.cpp +++ b/src/storage.cpp @@ -20,10 +20,10 @@ #include #include "arrow_utils.hpp" -#include "constants.hpp" +#include "common/constants.hpp" #include "edge_store.hpp" #include "json.hpp" -#include "logger.hpp" +#include "common/logger.hpp" #include "metadata.hpp" #include "node.hpp" #include "shard.hpp" diff --git a/src/tundra_shell.cpp b/src/tundra_shell.cpp index 743250b..111656e 100644 --- a/src/tundra_shell.cpp +++ b/src/tundra_shell.cpp @@ -27,12 +27,12 @@ #include "TundraQLLexer.h" #include "TundraQLParser.h" #include "arrow_map_union_types.hpp" -#include "constants.hpp" +#include "common/constants.hpp" #include "core.hpp" #include "linenoise.h" -#include "logger.hpp" -#include "types.hpp" -#include "utils.hpp" +#include "common/logger.hpp" +#include "common/types.hpp" +#include "common/utils.hpp" // Tee stream class that outputs to both console and file class TeeStream : public std::ostream { diff --git a/tests/array_query_test.cpp b/tests/array_query_test.cpp index 99b4436..6bde469 100644 --- a/tests/array_query_test.cpp +++ b/tests/array_query_test.cpp @@ -4,10 +4,10 @@ #include #include -#include "../include/clock.hpp" +#include "common/clock.hpp" #include "../include/core.hpp" #include "../include/query.hpp" -#include "../include/utils.hpp" +#include "common/utils.hpp" #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/benchmark_test.cpp b/tests/benchmark_test.cpp index 6612148..7c4097a 100644 --- a/tests/benchmark_test.cpp +++ b/tests/benchmark_test.cpp @@ -10,10 +10,10 @@ #include #include "../include/core.hpp" -#include "../include/logger.hpp" +#include "common/logger.hpp" #include "../include/metadata.hpp" #include "../include/query.hpp" -#include "../include/types.hpp" +#include "common/types.hpp" // Helper macro for Arrow operations #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/concurrency_test.cpp b/tests/concurrency_test.cpp index faa941a..cb7ce8a 100644 --- a/tests/concurrency_test.cpp +++ b/tests/concurrency_test.cpp @@ -1,4 +1,4 @@ -#include "concurrency.hpp" +#include "common/concurrency.hpp" #include #include diff --git a/tests/concurrent_set_stress_test.cpp b/tests/concurrent_set_stress_test.cpp index 6823c25..3eb1aa1 100644 --- a/tests/concurrent_set_stress_test.cpp +++ b/tests/concurrent_set_stress_test.cpp @@ -15,7 +15,7 @@ #include #include -#include "concurrency.hpp" +#include "common/concurrency.hpp" using namespace std::string_literals; using namespace tundradb; diff --git a/tests/database_test.cpp b/tests/database_test.cpp index 27144a1..4d66166 100644 --- a/tests/database_test.cpp +++ b/tests/database_test.cpp @@ -7,7 +7,7 @@ #include #include "core.hpp" -#include "logger.hpp" +#include "common/logger.hpp" using namespace tundradb; diff --git a/tests/join_test.cpp b/tests/join_test.cpp index 7f6c17c..6a7af21 100644 --- a/tests/join_test.cpp +++ b/tests/join_test.cpp @@ -5,8 +5,8 @@ #include #include "../include/core.hpp" -#include "../include/debug_utils.hpp" -#include "../include/logger.hpp" +#include "common/debug_utils.hpp" +#include "common/logger.hpp" #include "../include/metadata.hpp" #include "../include/query.hpp" diff --git a/tests/map_arena_test.cpp b/tests/map_arena_test.cpp index 052556e..46ab04d 100644 --- a/tests/map_arena_test.cpp +++ b/tests/map_arena_test.cpp @@ -6,13 +6,13 @@ #include #include "../include/array_arena.hpp" -#include "../include/clock.hpp" +#include "common/clock.hpp" #include "../include/edge.hpp" #include "../include/node.hpp" #include "../include/node_arena.hpp" #include "../include/schema.hpp" #include "../include/schema_layout.hpp" -#include "../include/types.hpp" +#include "common/types.hpp" #include "edge_store.hpp" using namespace tundradb; diff --git a/tests/node_arena_test.cpp b/tests/node_arena_test.cpp index da55b4b..b8186ac 100644 --- a/tests/node_arena_test.cpp +++ b/tests/node_arena_test.cpp @@ -12,7 +12,7 @@ #include "../include/node.hpp" #include "../include/schema.hpp" #include "../include/schema_layout.hpp" -#include "../include/types.hpp" +#include "common/types.hpp" using namespace tundradb; diff --git a/tests/node_test.cpp b/tests/node_test.cpp index b157b54..af497f7 100644 --- a/tests/node_test.cpp +++ b/tests/node_test.cpp @@ -8,9 +8,9 @@ #include #include "../include/field_update.hpp" -#include "../include/logger.hpp" +#include "common/logger.hpp" #include "../include/schema.hpp" -#include "../include/types.hpp" +#include "common/types.hpp" using namespace tundradb; diff --git a/tests/sharding_test.cpp b/tests/sharding_test.cpp index 212caae..0bd03b2 100644 --- a/tests/sharding_test.cpp +++ b/tests/sharding_test.cpp @@ -6,7 +6,7 @@ #include "../include/arrow_utils.hpp" #include "../include/core.hpp" -#include "../include/debug_utils.hpp" +#include "common/debug_utils.hpp" using namespace tundradb; class ShardingTest : public ::testing::Test { diff --git a/tests/snapshot_test.cpp b/tests/snapshot_test.cpp index a491b9d..b4f2537 100644 --- a/tests/snapshot_test.cpp +++ b/tests/snapshot_test.cpp @@ -9,7 +9,7 @@ #include "../include/arrow_map_union_types.hpp" #include "../include/core.hpp" #include "../include/field_update.hpp" -#include "../include/logger.hpp" +#include "common/logger.hpp" using namespace std::string_literals; using namespace tundradb; diff --git a/tests/string_ref_concurrent_test.cpp b/tests/string_ref_concurrent_test.cpp index bd296ec..bb32a4e 100644 --- a/tests/string_ref_concurrent_test.cpp +++ b/tests/string_ref_concurrent_test.cpp @@ -16,7 +16,7 @@ #include "../include/string_arena.hpp" #include "../include/string_ref.hpp" -#include "../include/types.hpp" +#include "common/types.hpp" using namespace tundradb; diff --git a/tests/temporal_query_test.cpp b/tests/temporal_query_test.cpp index 4f43a33..04a501b 100644 --- a/tests/temporal_query_test.cpp +++ b/tests/temporal_query_test.cpp @@ -2,9 +2,9 @@ #include -#include "../include/clock.hpp" +#include "common/clock.hpp" #include "../include/core.hpp" -#include "../include/logger.hpp" +#include "common/logger.hpp" #include "../include/node_arena.hpp" #include "../include/query.hpp" #include "../include/temporal_context.hpp" diff --git a/tests/type_conversion_test.cpp b/tests/type_conversion_test.cpp index 612a52d..0bd3fb0 100644 --- a/tests/type_conversion_test.cpp +++ b/tests/type_conversion_test.cpp @@ -2,7 +2,7 @@ #include #include "../include/schema.hpp" -#include "../include/types.hpp" +#include "common/types.hpp" using namespace tundradb; diff --git a/tests/type_system_test.cpp b/tests/type_system_test.cpp index 011759b..d360705 100644 --- a/tests/type_system_test.cpp +++ b/tests/type_system_test.cpp @@ -3,7 +3,7 @@ #include #include "../include/type_descriptor.hpp" -#include "../include/value_type.hpp" +#include "common/value_type.hpp" using namespace tundradb; diff --git a/tests/update_query_join_test.cpp b/tests/update_query_join_test.cpp index 9682ca6..937aadc 100644 --- a/tests/update_query_join_test.cpp +++ b/tests/update_query_join_test.cpp @@ -8,7 +8,7 @@ #include "../include/core.hpp" #include "../include/query.hpp" -#include "../include/utils.hpp" +#include "common/utils.hpp" #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/update_query_test.cpp b/tests/update_query_test.cpp index 7bdf7db..1f3d7c2 100644 --- a/tests/update_query_test.cpp +++ b/tests/update_query_test.cpp @@ -7,7 +7,7 @@ #include "../include/arrow_map_union_types.hpp" #include "../include/core.hpp" #include "../include/query.hpp" -#include "../include/utils.hpp" +#include "common/utils.hpp" #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/where_expression_test.cpp b/tests/where_expression_test.cpp index 20d8044..7877ec6 100644 --- a/tests/where_expression_test.cpp +++ b/tests/where_expression_test.cpp @@ -8,10 +8,10 @@ #include "../include/arrow_map_union_types.hpp" #include "../include/core.hpp" #include "../include/field_update.hpp" -#include "../include/logger.hpp" +#include "common/logger.hpp" #include "../include/metadata.hpp" #include "../include/query.hpp" -#include "../include/utils.hpp" +#include "common/utils.hpp" // Helper macro for Arrow operations #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/where_pushdown_join_test.cpp b/tests/where_pushdown_join_test.cpp index 64ea111..4a9f8ad 100644 --- a/tests/where_pushdown_join_test.cpp +++ b/tests/where_pushdown_join_test.cpp @@ -10,10 +10,10 @@ #include #include "../include/core.hpp" -#include "../include/logger.hpp" +#include "common/logger.hpp" #include "../include/metadata.hpp" #include "../include/query.hpp" -#include "../include/utils.hpp" +#include "common/utils.hpp" // Helper macro for Arrow operations #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) From a544b848c5fd67b0a5443121fa06aacdff400d0f Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 20:20:54 -0400 Subject: [PATCH 2/9] Move memory/ domain: arenas, refs, schema_layout, mem_utils - git mv 12 headers to include/memory/ - node_arena, map_arena, array_arena, string_arena, memory_arena, free_list_arena, mem_arena, mem_utils, map_ref, array_ref, string_ref, schema_layout - Update all #include directives across include/, src/, tests/ - Header-only domain, no per-directory CMakeLists needed Made-with: Cursor --- include/common/types.hpp | 6 +++--- include/edge.hpp | 4 ++-- include/edge_store.hpp | 4 ++-- include/edge_view.hpp | 2 +- include/{ => memory}/array_arena.hpp | 6 +++--- include/{ => memory}/array_ref.hpp | 0 include/{ => memory}/free_list_arena.hpp | 4 ++-- include/{ => memory}/map_arena.hpp | 8 ++++---- include/{ => memory}/map_ref.hpp | 2 +- include/{ => memory}/mem_arena.hpp | 0 include/{ => memory}/mem_utils.hpp | 0 include/{ => memory}/memory_arena.hpp | 4 ++-- include/{ => memory}/node_arena.hpp | 14 +++++++------- include/{ => memory}/schema_layout.hpp | 6 +++--- include/{ => memory}/string_arena.hpp | 6 +++--- include/{ => memory}/string_ref.hpp | 0 include/node.hpp | 2 +- include/node_view.hpp | 2 +- include/temporal_context.hpp | 2 +- src/common/types.cpp | 2 +- tests/arena_leak_test.cpp | 4 ++-- tests/array_arena_test.cpp | 4 ++-- tests/free_list_arena_test.cpp | 2 +- tests/map_arena_test.cpp | 8 ++++---- tests/memory_arena_test.cpp | 2 +- tests/node_arena_test.cpp | 6 +++--- tests/node_version_test.cpp | 6 +++--- tests/node_view_test.cpp | 4 ++-- tests/string_arena_test.cpp | 2 +- tests/string_ref_concurrent_test.cpp | 4 ++-- tests/temporal_query_test.cpp | 2 +- 31 files changed, 59 insertions(+), 59 deletions(-) rename include/{ => memory}/array_arena.hpp (99%) rename include/{ => memory}/array_ref.hpp (100%) rename include/{ => memory}/free_list_arena.hpp (99%) rename include/{ => memory}/map_arena.hpp (99%) rename include/{ => memory}/map_ref.hpp (99%) rename include/{ => memory}/mem_arena.hpp (100%) rename include/{ => memory}/mem_utils.hpp (100%) rename include/{ => memory}/memory_arena.hpp (98%) rename include/{ => memory}/node_arena.hpp (99%) rename include/{ => memory}/schema_layout.hpp (99%) rename include/{ => memory}/string_arena.hpp (99%) rename include/{ => memory}/string_ref.hpp (100%) diff --git a/include/common/types.hpp b/include/common/types.hpp index d993af2..1fc31bb 100644 --- a/include/common/types.hpp +++ b/include/common/types.hpp @@ -12,9 +12,9 @@ // Arrow includes for type conversion functions #include -#include "array_ref.hpp" -#include "map_ref.hpp" -#include "string_arena.hpp" +#include "memory/array_ref.hpp" +#include "memory/map_ref.hpp" +#include "memory/string_arena.hpp" namespace tundradb { diff --git a/include/edge.hpp b/include/edge.hpp index b522b5f..7cf593e 100644 --- a/include/edge.hpp +++ b/include/edge.hpp @@ -9,9 +9,9 @@ #include "common/constants.hpp" #include "edge_view.hpp" -#include "node_arena.hpp" +#include "memory/node_arena.hpp" #include "schema.hpp" -#include "schema_layout.hpp" +#include "memory/schema_layout.hpp" #include "temporal_context.hpp" #include "common/types.hpp" #include "update_type.hpp" diff --git a/include/edge_store.hpp b/include/edge_store.hpp index a0f00c6..5992671 100644 --- a/include/edge_store.hpp +++ b/include/edge_store.hpp @@ -13,9 +13,9 @@ #include "common/concurrency.hpp" #include "edge.hpp" -#include "node_arena.hpp" +#include "memory/node_arena.hpp" #include "schema.hpp" -#include "schema_layout.hpp" +#include "memory/schema_layout.hpp" #include "common/utils.hpp" namespace tundradb { diff --git a/include/edge_view.hpp b/include/edge_view.hpp index 4b8312c..f4dff68 100644 --- a/include/edge_view.hpp +++ b/include/edge_view.hpp @@ -5,7 +5,7 @@ #include -#include "node_arena.hpp" +#include "memory/node_arena.hpp" #include "schema.hpp" #include "common/types.hpp" diff --git a/include/array_arena.hpp b/include/memory/array_arena.hpp similarity index 99% rename from include/array_arena.hpp rename to include/memory/array_arena.hpp index 5c42437..dde43f9 100644 --- a/include/array_arena.hpp +++ b/include/memory/array_arena.hpp @@ -9,9 +9,9 @@ #include #include -#include "array_ref.hpp" -#include "free_list_arena.hpp" -#include "string_ref.hpp" +#include "memory/array_ref.hpp" +#include "memory/free_list_arena.hpp" +#include "memory/string_ref.hpp" #include "common/value_type.hpp" namespace tundradb { diff --git a/include/array_ref.hpp b/include/memory/array_ref.hpp similarity index 100% rename from include/array_ref.hpp rename to include/memory/array_ref.hpp diff --git a/include/free_list_arena.hpp b/include/memory/free_list_arena.hpp similarity index 99% rename from include/free_list_arena.hpp rename to include/memory/free_list_arena.hpp index 1048e73..548f5d7 100644 --- a/include/free_list_arena.hpp +++ b/include/memory/free_list_arena.hpp @@ -11,8 +11,8 @@ #include #include "common/logger.hpp" -#include "mem_arena.hpp" -#include "mem_utils.hpp" +#include "memory/mem_arena.hpp" +#include "memory/mem_utils.hpp" namespace tundradb { diff --git a/include/map_arena.hpp b/include/memory/map_arena.hpp similarity index 99% rename from include/map_arena.hpp rename to include/memory/map_arena.hpp index 0e967a8..de75c95 100644 --- a/include/map_arena.hpp +++ b/include/memory/map_arena.hpp @@ -9,10 +9,10 @@ #include #include -#include "array_ref.hpp" -#include "free_list_arena.hpp" -#include "map_ref.hpp" -#include "string_ref.hpp" +#include "memory/array_ref.hpp" +#include "memory/free_list_arena.hpp" +#include "memory/map_ref.hpp" +#include "memory/string_ref.hpp" #include "common/types.hpp" #include "common/value_type.hpp" diff --git a/include/map_ref.hpp b/include/memory/map_ref.hpp similarity index 99% rename from include/map_ref.hpp rename to include/memory/map_ref.hpp index 084bd2c..6354acd 100644 --- a/include/map_ref.hpp +++ b/include/memory/map_ref.hpp @@ -8,7 +8,7 @@ #include #include "common/constants.hpp" -#include "string_ref.hpp" +#include "memory/string_ref.hpp" #include "common/value_type.hpp" namespace tundradb { diff --git a/include/mem_arena.hpp b/include/memory/mem_arena.hpp similarity index 100% rename from include/mem_arena.hpp rename to include/memory/mem_arena.hpp diff --git a/include/mem_utils.hpp b/include/memory/mem_utils.hpp similarity index 100% rename from include/mem_utils.hpp rename to include/memory/mem_utils.hpp diff --git a/include/memory_arena.hpp b/include/memory/memory_arena.hpp similarity index 98% rename from include/memory_arena.hpp rename to include/memory/memory_arena.hpp index fe82772..56a12df 100644 --- a/include/memory_arena.hpp +++ b/include/memory/memory_arena.hpp @@ -4,8 +4,8 @@ #include #include -#include "mem_arena.hpp" -#include "mem_utils.hpp" +#include "memory/mem_arena.hpp" +#include "memory/mem_utils.hpp" namespace tundradb { diff --git a/include/node_arena.hpp b/include/memory/node_arena.hpp similarity index 99% rename from include/node_arena.hpp rename to include/memory/node_arena.hpp index f2e09d1..57dec76 100644 --- a/include/node_arena.hpp +++ b/include/memory/node_arena.hpp @@ -11,15 +11,15 @@ #include #include -#include "array_arena.hpp" +#include "memory/array_arena.hpp" #include "common/clock.hpp" #include "field_update.hpp" -#include "free_list_arena.hpp" -#include "map_arena.hpp" -#include "mem_arena.hpp" -#include "memory_arena.hpp" -#include "schema_layout.hpp" -#include "string_arena.hpp" +#include "memory/free_list_arena.hpp" +#include "memory/map_arena.hpp" +#include "memory/mem_arena.hpp" +#include "memory/memory_arena.hpp" +#include "memory/schema_layout.hpp" +#include "memory/string_arena.hpp" #include "common/types.hpp" #include "update_type.hpp" diff --git a/include/schema_layout.hpp b/include/memory/schema_layout.hpp similarity index 99% rename from include/schema_layout.hpp rename to include/memory/schema_layout.hpp index af7809a..14faf14 100644 --- a/include/schema_layout.hpp +++ b/include/memory/schema_layout.hpp @@ -9,10 +9,10 @@ #include #include -#include "array_ref.hpp" +#include "memory/array_ref.hpp" #include "llvm/ADT/StringMap.h" -#include "map_ref.hpp" -#include "mem_utils.hpp" +#include "memory/map_ref.hpp" +#include "memory/mem_utils.hpp" #include "schema.hpp" #include "type_descriptor.hpp" #include "common/types.hpp" diff --git a/include/string_arena.hpp b/include/memory/string_arena.hpp similarity index 99% rename from include/string_arena.hpp rename to include/memory/string_arena.hpp index 0cd95ef..27653d3 100644 --- a/include/string_arena.hpp +++ b/include/memory/string_arena.hpp @@ -13,9 +13,9 @@ #include #include -#include "free_list_arena.hpp" -#include "memory_arena.hpp" -#include "string_ref.hpp" // StringRef class +#include "memory/free_list_arena.hpp" +#include "memory/memory_arena.hpp" +#include "memory/string_ref.hpp" // StringRef class #include "common/value_type.hpp" // ValueType enum and helpers namespace tundradb { diff --git a/include/string_ref.hpp b/include/memory/string_ref.hpp similarity index 100% rename from include/string_ref.hpp rename to include/memory/string_ref.hpp diff --git a/include/node.hpp b/include/node.hpp index d01f934..ba5e665 100644 --- a/include/node.hpp +++ b/include/node.hpp @@ -8,7 +8,7 @@ #include "common/constants.hpp" #include "common/logger.hpp" -#include "node_arena.hpp" +#include "memory/node_arena.hpp" #include "node_view.hpp" #include "schema.hpp" #include "temporal_context.hpp" diff --git a/include/node_view.hpp b/include/node_view.hpp index 97b5357..5a2078e 100644 --- a/include/node_view.hpp +++ b/include/node_view.hpp @@ -5,7 +5,7 @@ #include -#include "node_arena.hpp" +#include "memory/node_arena.hpp" #include "schema.hpp" #include "temporal_context.hpp" #include "common/types.hpp" diff --git a/include/temporal_context.hpp b/include/temporal_context.hpp index 1492cbf..16c2946 100644 --- a/include/temporal_context.hpp +++ b/include/temporal_context.hpp @@ -4,7 +4,7 @@ #include #include -#include "node_arena.hpp" +#include "memory/node_arena.hpp" namespace tundradb { diff --git a/src/common/types.cpp b/src/common/types.cpp index 3951074..63510e4 100644 --- a/src/common/types.cpp +++ b/src/common/types.cpp @@ -1,6 +1,6 @@ #include "common/types.hpp" -#include "string_arena.hpp" +#include "memory/string_arena.hpp" namespace tundradb { diff --git a/tests/arena_leak_test.cpp b/tests/arena_leak_test.cpp index ab4a803..8114bcc 100644 --- a/tests/arena_leak_test.cpp +++ b/tests/arena_leak_test.cpp @@ -18,8 +18,8 @@ #include #include -#include "../include/array_arena.hpp" -#include "../include/string_arena.hpp" +#include "memory/array_arena.hpp" +#include "memory/string_arena.hpp" using namespace tundradb; diff --git a/tests/array_arena_test.cpp b/tests/array_arena_test.cpp index 5f85565..bd10940 100644 --- a/tests/array_arena_test.cpp +++ b/tests/array_arena_test.cpp @@ -1,10 +1,10 @@ -#include "../include/array_arena.hpp" +#include "memory/array_arena.hpp" #include #include -#include "../include/string_arena.hpp" +#include "memory/string_arena.hpp" using namespace tundradb; diff --git a/tests/free_list_arena_test.cpp b/tests/free_list_arena_test.cpp index cb23bf7..5935042 100644 --- a/tests/free_list_arena_test.cpp +++ b/tests/free_list_arena_test.cpp @@ -1,5 +1,5 @@ #define TESTING_ENABLED -#include "../include/free_list_arena.hpp" +#include "memory/free_list_arena.hpp" #include diff --git a/tests/map_arena_test.cpp b/tests/map_arena_test.cpp index 46ab04d..6c80507 100644 --- a/tests/map_arena_test.cpp +++ b/tests/map_arena_test.cpp @@ -1,17 +1,17 @@ -#include "../include/map_arena.hpp" +#include "memory/map_arena.hpp" #include #include #include -#include "../include/array_arena.hpp" +#include "memory/array_arena.hpp" #include "common/clock.hpp" #include "../include/edge.hpp" #include "../include/node.hpp" -#include "../include/node_arena.hpp" +#include "memory/node_arena.hpp" #include "../include/schema.hpp" -#include "../include/schema_layout.hpp" +#include "memory/schema_layout.hpp" #include "common/types.hpp" #include "edge_store.hpp" diff --git a/tests/memory_arena_test.cpp b/tests/memory_arena_test.cpp index 739dc04..4d9903b 100644 --- a/tests/memory_arena_test.cpp +++ b/tests/memory_arena_test.cpp @@ -1,4 +1,4 @@ -#include "../include/memory_arena.hpp" +#include "memory/memory_arena.hpp" #include diff --git a/tests/node_arena_test.cpp b/tests/node_arena_test.cpp index b8186ac..a99d75c 100644 --- a/tests/node_arena_test.cpp +++ b/tests/node_arena_test.cpp @@ -1,4 +1,4 @@ -#include "../include/node_arena.hpp" +#include "memory/node_arena.hpp" #include #include @@ -8,10 +8,10 @@ #include #include "../include/field_update.hpp" -#include "../include/memory_arena.hpp" +#include "memory/memory_arena.hpp" #include "../include/node.hpp" #include "../include/schema.hpp" -#include "../include/schema_layout.hpp" +#include "memory/schema_layout.hpp" #include "common/types.hpp" using namespace tundradb; diff --git a/tests/node_version_test.cpp b/tests/node_version_test.cpp index 58c160f..46efbd9 100644 --- a/tests/node_version_test.cpp +++ b/tests/node_version_test.cpp @@ -3,10 +3,10 @@ #include #include -#include "../include/map_arena.hpp" -#include "../include/node_arena.hpp" +#include "memory/map_arena.hpp" +#include "memory/node_arena.hpp" #include "../include/schema.hpp" -#include "../include/schema_layout.hpp" +#include "memory/schema_layout.hpp" using namespace tundradb; diff --git a/tests/node_view_test.cpp b/tests/node_view_test.cpp index dfe928b..739246c 100644 --- a/tests/node_view_test.cpp +++ b/tests/node_view_test.cpp @@ -6,9 +6,9 @@ #include #include "../include/node.hpp" -#include "../include/node_arena.hpp" +#include "memory/node_arena.hpp" #include "../include/schema.hpp" -#include "../include/schema_layout.hpp" +#include "memory/schema_layout.hpp" #include "../include/temporal_context.hpp" using namespace tundradb; diff --git a/tests/string_arena_test.cpp b/tests/string_arena_test.cpp index 28a9207..7b97da4 100644 --- a/tests/string_arena_test.cpp +++ b/tests/string_arena_test.cpp @@ -1,4 +1,4 @@ -#include "../include/string_arena.hpp" +#include "memory/string_arena.hpp" #include diff --git a/tests/string_ref_concurrent_test.cpp b/tests/string_ref_concurrent_test.cpp index bb32a4e..57af26e 100644 --- a/tests/string_ref_concurrent_test.cpp +++ b/tests/string_ref_concurrent_test.cpp @@ -14,8 +14,8 @@ #include #include -#include "../include/string_arena.hpp" -#include "../include/string_ref.hpp" +#include "memory/string_arena.hpp" +#include "memory/string_ref.hpp" #include "common/types.hpp" using namespace tundradb; diff --git a/tests/temporal_query_test.cpp b/tests/temporal_query_test.cpp index 04a501b..ae72801 100644 --- a/tests/temporal_query_test.cpp +++ b/tests/temporal_query_test.cpp @@ -5,7 +5,7 @@ #include "common/clock.hpp" #include "../include/core.hpp" #include "common/logger.hpp" -#include "../include/node_arena.hpp" +#include "memory/node_arena.hpp" #include "../include/query.hpp" #include "../include/temporal_context.hpp" From 8a3962734d749b736a74fd9242d376870a5a10e0 Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 21:21:50 -0400 Subject: [PATCH 3/9] Move arrow/ domain: utils, map_union_types, table_info MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - git mv arrow_utils.hpp → arrow/utils.hpp, arrow_map_union_types.hpp → arrow/map_union_types.hpp, table_info.hpp → arrow/table_info.hpp - git mv arrow_utils.cpp → src/arrow/utils.cpp, table_info.cpp → src/arrow/table_info.cpp - Add src/arrow/CMakeLists.txt - Update all #include directives Made-with: Cursor --- CMakeLists.txt | 13 ++++++++----- .../map_union_types.hpp} | 0 include/{ => arrow}/table_info.hpp | 0 include/{arrow_utils.hpp => arrow/utils.hpp} | 0 include/common/utils.hpp | 2 +- include/core.hpp | 2 +- include/metadata.hpp | 2 +- src/arrow/CMakeLists.txt | 4 ++++ src/{ => arrow}/table_info.cpp | 2 +- src/{arrow_utils.cpp => arrow/utils.cpp} | 4 ++-- src/core.cpp | 2 +- src/query_execution.cpp | 4 ++-- src/schema.cpp | 4 ++-- src/storage.cpp | 4 ++-- src/tundra_shell.cpp | 2 +- tests/schema_utils_test.cpp | 2 +- tests/sharding_test.cpp | 2 +- tests/snapshot_test.cpp | 2 +- tests/table_info_test.cpp | 2 +- tests/update_query_test.cpp | 2 +- tests/where_expression_test.cpp | 2 +- 21 files changed, 32 insertions(+), 25 deletions(-) rename include/{arrow_map_union_types.hpp => arrow/map_union_types.hpp} (100%) rename include/{ => arrow}/table_info.hpp (100%) rename include/{arrow_utils.hpp => arrow/utils.hpp} (100%) create mode 100644 src/arrow/CMakeLists.txt rename src/{ => arrow}/table_info.cpp (97%) rename src/{arrow_utils.cpp => arrow/utils.cpp} (99%) diff --git a/CMakeLists.txt b/CMakeLists.txt index eeaac0a..4c89c2a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -232,7 +232,14 @@ include_directories( ) # Core library -add_library(core +add_library(core) + +# Per-domain source directories +add_subdirectory(src/common) +add_subdirectory(src/arrow) + +# Sources not yet moved to domain folders +target_sources(core PRIVATE src/core.cpp src/query.cpp src/query_execution.cpp @@ -244,13 +251,9 @@ add_library(core src/snapshot_manager.cpp src/edge_store.cpp - src/table_info.cpp src/schema.cpp - src/arrow_utils.cpp ) -add_subdirectory(src/common) - target_include_directories(core PUBLIC $ diff --git a/include/arrow_map_union_types.hpp b/include/arrow/map_union_types.hpp similarity index 100% rename from include/arrow_map_union_types.hpp rename to include/arrow/map_union_types.hpp diff --git a/include/table_info.hpp b/include/arrow/table_info.hpp similarity index 100% rename from include/table_info.hpp rename to include/arrow/table_info.hpp diff --git a/include/arrow_utils.hpp b/include/arrow/utils.hpp similarity index 100% rename from include/arrow_utils.hpp rename to include/arrow/utils.hpp diff --git a/include/common/utils.hpp b/include/common/utils.hpp index e973ca4..1040efc 100644 --- a/include/common/utils.hpp +++ b/include/common/utils.hpp @@ -15,7 +15,7 @@ #include #include -#include "arrow_utils.hpp" +#include "arrow/utils.hpp" #include "common/constants.hpp" #include "common/logger.hpp" #include "node.hpp" diff --git a/include/core.hpp b/include/core.hpp index ca30e0d..611842f 100644 --- a/include/core.hpp +++ b/include/core.hpp @@ -9,7 +9,7 @@ #include #include -#include "arrow_utils.hpp" +#include "arrow/utils.hpp" #include "common/config.hpp" #include "edge_store.hpp" #include "field_update.hpp" diff --git a/include/metadata.hpp b/include/metadata.hpp index b23fb2d..3dbbe5a 100644 --- a/include/metadata.hpp +++ b/include/metadata.hpp @@ -9,7 +9,7 @@ #include #include -#include "arrow_map_union_types.hpp" +#include "arrow/map_union_types.hpp" #include "file_utils.hpp" #include "json.hpp" #include "llvm/ADT/SmallVector.h" diff --git a/src/arrow/CMakeLists.txt b/src/arrow/CMakeLists.txt new file mode 100644 index 0000000..90c6f89 --- /dev/null +++ b/src/arrow/CMakeLists.txt @@ -0,0 +1,4 @@ +target_sources(core PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/utils.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/table_info.cpp +) diff --git a/src/table_info.cpp b/src/arrow/table_info.cpp similarity index 97% rename from src/table_info.cpp rename to src/arrow/table_info.cpp index 601fafc..2f4607d 100644 --- a/src/table_info.cpp +++ b/src/arrow/table_info.cpp @@ -1,4 +1,4 @@ -#include "table_info.hpp" +#include "arrow/table_info.hpp" #include diff --git a/src/arrow_utils.cpp b/src/arrow/utils.cpp similarity index 99% rename from src/arrow_utils.cpp rename to src/arrow/utils.cpp index 69db47a..3e3ba93 100644 --- a/src/arrow_utils.cpp +++ b/src/arrow/utils.cpp @@ -1,4 +1,4 @@ -#include "arrow_utils.hpp" +#include "arrow/utils.hpp" #include #include @@ -13,7 +13,7 @@ #include #include -#include "arrow_map_union_types.hpp" +#include "arrow/map_union_types.hpp" #include "common/logger.hpp" #include "node.hpp" #include "query.hpp" diff --git a/src/core.cpp b/src/core.cpp index 006a074..3dc6dcc 100644 --- a/src/core.cpp +++ b/src/core.cpp @@ -20,7 +20,7 @@ #include #include -#include "arrow_utils.hpp" +#include "arrow/utils.hpp" #include "join.hpp" #include "common/logger.hpp" #include "row.hpp" diff --git a/src/query_execution.cpp b/src/query_execution.cpp index a09325d..54422fd 100644 --- a/src/query_execution.cpp +++ b/src/query_execution.cpp @@ -3,8 +3,8 @@ #include #include -#include "arrow_map_union_types.hpp" -#include "arrow_utils.hpp" +#include "arrow/map_union_types.hpp" +#include "arrow/utils.hpp" #include "common/constants.hpp" #include "edge_store.hpp" #include "common/logger.hpp" diff --git a/src/schema.cpp b/src/schema.cpp index 552dd66..9898464 100644 --- a/src/schema.cpp +++ b/src/schema.cpp @@ -2,8 +2,8 @@ #include -#include "arrow_map_union_types.hpp" -#include "arrow_utils.hpp" +#include "arrow/map_union_types.hpp" +#include "arrow/utils.hpp" #include "metadata.hpp" namespace tundradb { diff --git a/src/storage.cpp b/src/storage.cpp index 964998e..2f62352 100644 --- a/src/storage.cpp +++ b/src/storage.cpp @@ -19,7 +19,7 @@ #include #include -#include "arrow_utils.hpp" +#include "arrow/utils.hpp" #include "common/constants.hpp" #include "edge_store.hpp" #include "json.hpp" @@ -27,7 +27,7 @@ #include "metadata.hpp" #include "node.hpp" #include "shard.hpp" -#include "table_info.hpp" +#include "arrow/table_info.hpp" namespace tundradb { diff --git a/src/tundra_shell.cpp b/src/tundra_shell.cpp index 111656e..d33e9b8 100644 --- a/src/tundra_shell.cpp +++ b/src/tundra_shell.cpp @@ -26,7 +26,7 @@ #include "TundraQLBaseVisitor.h" #include "TundraQLLexer.h" #include "TundraQLParser.h" -#include "arrow_map_union_types.hpp" +#include "arrow/map_union_types.hpp" #include "common/constants.hpp" #include "core.hpp" #include "linenoise.h" diff --git a/tests/schema_utils_test.cpp b/tests/schema_utils_test.cpp index fd67772..8159c1b 100644 --- a/tests/schema_utils_test.cpp +++ b/tests/schema_utils_test.cpp @@ -3,7 +3,7 @@ #include #include -#include "arrow_utils.hpp" +#include "arrow/utils.hpp" namespace tundradb { diff --git a/tests/sharding_test.cpp b/tests/sharding_test.cpp index 0bd03b2..250c6dc 100644 --- a/tests/sharding_test.cpp +++ b/tests/sharding_test.cpp @@ -4,7 +4,7 @@ #include #include -#include "../include/arrow_utils.hpp" +#include "arrow/utils.hpp" #include "../include/core.hpp" #include "common/debug_utils.hpp" using namespace tundradb; diff --git a/tests/snapshot_test.cpp b/tests/snapshot_test.cpp index b4f2537..f72a83a 100644 --- a/tests/snapshot_test.cpp +++ b/tests/snapshot_test.cpp @@ -6,7 +6,7 @@ #include #include -#include "../include/arrow_map_union_types.hpp" +#include "arrow/map_union_types.hpp" #include "../include/core.hpp" #include "../include/field_update.hpp" #include "common/logger.hpp" diff --git a/tests/table_info_test.cpp b/tests/table_info_test.cpp index 0499123..27ab1e5 100644 --- a/tests/table_info_test.cpp +++ b/tests/table_info_test.cpp @@ -1,4 +1,4 @@ -#include "table_info.hpp" +#include "arrow/table_info.hpp" #include #include diff --git a/tests/update_query_test.cpp b/tests/update_query_test.cpp index 1f3d7c2..a40159f 100644 --- a/tests/update_query_test.cpp +++ b/tests/update_query_test.cpp @@ -4,7 +4,7 @@ #include #include -#include "../include/arrow_map_union_types.hpp" +#include "arrow/map_union_types.hpp" #include "../include/core.hpp" #include "../include/query.hpp" #include "common/utils.hpp" diff --git a/tests/where_expression_test.cpp b/tests/where_expression_test.cpp index 7877ec6..cb1dfae 100644 --- a/tests/where_expression_test.cpp +++ b/tests/where_expression_test.cpp @@ -5,7 +5,7 @@ #include #include -#include "../include/arrow_map_union_types.hpp" +#include "arrow/map_union_types.hpp" #include "../include/core.hpp" #include "../include/field_update.hpp" #include "common/logger.hpp" From 4e7830595bd75bf964aba45ebfbcb7e2b65cbebf Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 21:29:09 -0400 Subject: [PATCH 4/9] =?UTF-8?q?Move=20schema/=20domain:=20schema,=20type?= =?UTF-8?q?=5Fdescriptor,=20schema=5Futils=E2=86=92utils?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - git mv headers to include/schema/, sources to src/schema/ - Rename schema_utils.hpp → utils.hpp (avoid repeating domain in filename) - Add src/schema/CMakeLists.txt - Update all #include directives Made-with: Cursor --- CMakeLists.txt | 2 +- include/core.hpp | 2 +- include/edge.hpp | 2 +- include/edge_store.hpp | 2 +- include/edge_view.hpp | 2 +- include/field_update.hpp | 2 +- include/memory/schema_layout.hpp | 4 ++-- include/metadata.hpp | 4 ++-- include/node.hpp | 2 +- include/node_view.hpp | 2 +- include/query.hpp | 2 +- include/query_execution.hpp | 2 +- include/{ => schema}/schema.hpp | 2 +- include/{ => schema}/type_descriptor.hpp | 0 include/{schema_utils.hpp => schema/utils.hpp} | 0 include/shard.hpp | 2 +- include/snapshot_manager.hpp | 2 +- src/arrow/utils.cpp | 2 +- src/schema/CMakeLists.txt | 3 +++ src/{ => schema}/schema.cpp | 2 +- tests/map_arena_test.cpp | 2 +- tests/node_arena_test.cpp | 2 +- tests/node_test.cpp | 2 +- tests/node_version_test.cpp | 2 +- tests/node_view_test.cpp | 2 +- tests/schema_utils_test.cpp | 2 +- tests/type_conversion_test.cpp | 2 +- tests/type_system_test.cpp | 2 +- 28 files changed, 30 insertions(+), 27 deletions(-) rename include/{ => schema}/schema.hpp (99%) rename include/{ => schema}/type_descriptor.hpp (100%) rename include/{schema_utils.hpp => schema/utils.hpp} (100%) create mode 100644 src/schema/CMakeLists.txt rename src/{ => schema}/schema.cpp (99%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4c89c2a..560e1f8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -237,6 +237,7 @@ add_library(core) # Per-domain source directories add_subdirectory(src/common) add_subdirectory(src/arrow) +add_subdirectory(src/schema) # Sources not yet moved to domain folders target_sources(core PRIVATE @@ -251,7 +252,6 @@ target_sources(core PRIVATE src/snapshot_manager.cpp src/edge_store.cpp - src/schema.cpp ) target_include_directories(core diff --git a/include/core.hpp b/include/core.hpp index 611842f..6bc3466 100644 --- a/include/core.hpp +++ b/include/core.hpp @@ -18,7 +18,7 @@ #include "node.hpp" #include "query.hpp" #include "query_execution.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" #include "shard.hpp" #include "snapshot_manager.hpp" #include "storage.hpp" diff --git a/include/edge.hpp b/include/edge.hpp index 7cf593e..af63228 100644 --- a/include/edge.hpp +++ b/include/edge.hpp @@ -10,7 +10,7 @@ #include "common/constants.hpp" #include "edge_view.hpp" #include "memory/node_arena.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "temporal_context.hpp" #include "common/types.hpp" diff --git a/include/edge_store.hpp b/include/edge_store.hpp index 5992671..da7cbd9 100644 --- a/include/edge_store.hpp +++ b/include/edge_store.hpp @@ -14,7 +14,7 @@ #include "common/concurrency.hpp" #include "edge.hpp" #include "memory/node_arena.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "common/utils.hpp" diff --git a/include/edge_view.hpp b/include/edge_view.hpp index f4dff68..79b8f53 100644 --- a/include/edge_view.hpp +++ b/include/edge_view.hpp @@ -6,7 +6,7 @@ #include #include "memory/node_arena.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" #include "common/types.hpp" namespace tundradb { diff --git a/include/field_update.hpp b/include/field_update.hpp index 03ff966..a54a6d4 100644 --- a/include/field_update.hpp +++ b/include/field_update.hpp @@ -6,7 +6,7 @@ #include #include -#include "schema.hpp" +#include "schema/schema.hpp" #include "common/types.hpp" #include "update_type.hpp" diff --git a/include/memory/schema_layout.hpp b/include/memory/schema_layout.hpp index 14faf14..556df29 100644 --- a/include/memory/schema_layout.hpp +++ b/include/memory/schema_layout.hpp @@ -13,8 +13,8 @@ #include "llvm/ADT/StringMap.h" #include "memory/map_ref.hpp" #include "memory/mem_utils.hpp" -#include "schema.hpp" -#include "type_descriptor.hpp" +#include "schema/schema.hpp" +#include "schema/type_descriptor.hpp" #include "common/types.hpp" namespace tundradb { diff --git a/include/metadata.hpp b/include/metadata.hpp index 3dbbe5a..b6fba4c 100644 --- a/include/metadata.hpp +++ b/include/metadata.hpp @@ -14,8 +14,8 @@ #include "json.hpp" #include "llvm/ADT/SmallVector.h" #include "common/logger.hpp" -#include "schema.hpp" -#include "type_descriptor.hpp" +#include "schema/schema.hpp" +#include "schema/type_descriptor.hpp" #include "common/types.hpp" using namespace std::string_literals; diff --git a/include/node.hpp b/include/node.hpp index ba5e665..5cfc2a3 100644 --- a/include/node.hpp +++ b/include/node.hpp @@ -10,7 +10,7 @@ #include "common/logger.hpp" #include "memory/node_arena.hpp" #include "node_view.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" #include "temporal_context.hpp" #include "common/types.hpp" #include "update_type.hpp" diff --git a/include/node_view.hpp b/include/node_view.hpp index 5a2078e..7f5adc3 100644 --- a/include/node_view.hpp +++ b/include/node_view.hpp @@ -6,7 +6,7 @@ #include #include "memory/node_arena.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" #include "temporal_context.hpp" #include "common/types.hpp" diff --git a/include/query.hpp b/include/query.hpp index fb0dc16..29c0fad 100644 --- a/include/query.hpp +++ b/include/query.hpp @@ -19,7 +19,7 @@ #include #include "node.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" #include "temporal_context.hpp" #include "common/types.hpp" diff --git a/include/query_execution.hpp b/include/query_execution.hpp index cffae8a..32e8e67 100644 --- a/include/query_execution.hpp +++ b/include/query_execution.hpp @@ -19,7 +19,7 @@ #include #include "query.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" namespace tundradb { diff --git a/include/schema.hpp b/include/schema/schema.hpp similarity index 99% rename from include/schema.hpp rename to include/schema/schema.hpp index 084e6b6..ce01edd 100644 --- a/include/schema.hpp +++ b/include/schema/schema.hpp @@ -13,7 +13,7 @@ #include "llvm/ADT/DenseMap.h" #include "llvm/ADT/SmallVector.h" #include "common/logger.hpp" -#include "type_descriptor.hpp" +#include "schema/type_descriptor.hpp" #include "common/types.hpp" namespace tundradb { diff --git a/include/type_descriptor.hpp b/include/schema/type_descriptor.hpp similarity index 100% rename from include/type_descriptor.hpp rename to include/schema/type_descriptor.hpp diff --git a/include/schema_utils.hpp b/include/schema/utils.hpp similarity index 100% rename from include/schema_utils.hpp rename to include/schema/utils.hpp diff --git a/include/shard.hpp b/include/shard.hpp index b92f998..8141dc6 100644 --- a/include/shard.hpp +++ b/include/shard.hpp @@ -16,7 +16,7 @@ #include "common/config.hpp" #include "field_update.hpp" #include "node.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" namespace tundradb { diff --git a/include/snapshot_manager.hpp b/include/snapshot_manager.hpp index a7b9ace..b92b0da 100644 --- a/include/snapshot_manager.hpp +++ b/include/snapshot_manager.hpp @@ -6,7 +6,7 @@ #include "edge_store.hpp" #include "metadata.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" namespace tundradb { diff --git a/src/arrow/utils.cpp b/src/arrow/utils.cpp index 3e3ba93..60fbab2 100644 --- a/src/arrow/utils.cpp +++ b/src/arrow/utils.cpp @@ -17,7 +17,7 @@ #include "common/logger.hpp" #include "node.hpp" #include "query.hpp" -#include "schema.hpp" +#include "schema/schema.hpp" namespace tundradb { diff --git a/src/schema/CMakeLists.txt b/src/schema/CMakeLists.txt new file mode 100644 index 0000000..c281d3a --- /dev/null +++ b/src/schema/CMakeLists.txt @@ -0,0 +1,3 @@ +target_sources(core PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/schema.cpp +) diff --git a/src/schema.cpp b/src/schema/schema.cpp similarity index 99% rename from src/schema.cpp rename to src/schema/schema.cpp index 9898464..a8bff73 100644 --- a/src/schema.cpp +++ b/src/schema/schema.cpp @@ -1,4 +1,4 @@ -#include "schema.hpp" +#include "schema/schema.hpp" #include diff --git a/tests/map_arena_test.cpp b/tests/map_arena_test.cpp index 6c80507..789e9d1 100644 --- a/tests/map_arena_test.cpp +++ b/tests/map_arena_test.cpp @@ -10,7 +10,7 @@ #include "../include/edge.hpp" #include "../include/node.hpp" #include "memory/node_arena.hpp" -#include "../include/schema.hpp" +#include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "common/types.hpp" #include "edge_store.hpp" diff --git a/tests/node_arena_test.cpp b/tests/node_arena_test.cpp index a99d75c..3b57e34 100644 --- a/tests/node_arena_test.cpp +++ b/tests/node_arena_test.cpp @@ -10,7 +10,7 @@ #include "../include/field_update.hpp" #include "memory/memory_arena.hpp" #include "../include/node.hpp" -#include "../include/schema.hpp" +#include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "common/types.hpp" diff --git a/tests/node_test.cpp b/tests/node_test.cpp index af497f7..d0171aa 100644 --- a/tests/node_test.cpp +++ b/tests/node_test.cpp @@ -9,7 +9,7 @@ #include "../include/field_update.hpp" #include "common/logger.hpp" -#include "../include/schema.hpp" +#include "schema/schema.hpp" #include "common/types.hpp" using namespace tundradb; diff --git a/tests/node_version_test.cpp b/tests/node_version_test.cpp index 46efbd9..9732455 100644 --- a/tests/node_version_test.cpp +++ b/tests/node_version_test.cpp @@ -5,7 +5,7 @@ #include "memory/map_arena.hpp" #include "memory/node_arena.hpp" -#include "../include/schema.hpp" +#include "schema/schema.hpp" #include "memory/schema_layout.hpp" using namespace tundradb; diff --git a/tests/node_view_test.cpp b/tests/node_view_test.cpp index 739246c..ea8d316 100644 --- a/tests/node_view_test.cpp +++ b/tests/node_view_test.cpp @@ -7,7 +7,7 @@ #include "../include/node.hpp" #include "memory/node_arena.hpp" -#include "../include/schema.hpp" +#include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "../include/temporal_context.hpp" diff --git a/tests/schema_utils_test.cpp b/tests/schema_utils_test.cpp index 8159c1b..66723dd 100644 --- a/tests/schema_utils_test.cpp +++ b/tests/schema_utils_test.cpp @@ -1,4 +1,4 @@ -#include "schema_utils.hpp" +#include "schema/utils.hpp" #include #include diff --git a/tests/type_conversion_test.cpp b/tests/type_conversion_test.cpp index 0bd3fb0..6e0a439 100644 --- a/tests/type_conversion_test.cpp +++ b/tests/type_conversion_test.cpp @@ -1,7 +1,7 @@ #include #include -#include "../include/schema.hpp" +#include "schema/schema.hpp" #include "common/types.hpp" using namespace tundradb; diff --git a/tests/type_system_test.cpp b/tests/type_system_test.cpp index d360705..10cac29 100644 --- a/tests/type_system_test.cpp +++ b/tests/type_system_test.cpp @@ -2,7 +2,7 @@ #include -#include "../include/type_descriptor.hpp" +#include "schema/type_descriptor.hpp" #include "common/value_type.hpp" using namespace tundradb; From c656301360db8705852d00f6977a8293d30b13c4 Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 21:45:51 -0400 Subject: [PATCH 5/9] Move core/ domain: node, edge, edge_store, node_view, edge_view, field_update, update_type - git mv 7 headers to include/core/, edge_store.cpp to src/core/ - Add src/core/CMakeLists.txt - Update all #include directives Made-with: Cursor --- CMakeLists.txt | 2 +- include/common/utils.hpp | 2 +- include/core.hpp | 6 +++--- include/{ => core}/edge.hpp | 4 ++-- include/{ => core}/edge_store.hpp | 2 +- include/{ => core}/edge_view.hpp | 0 include/{ => core}/field_update.hpp | 2 +- include/{ => core}/node.hpp | 4 ++-- include/{ => core}/node_view.hpp | 0 include/{ => core}/update_type.hpp | 0 include/memory/node_arena.hpp | 4 ++-- include/query.hpp | 2 +- include/row.hpp | 4 ++-- include/shard.hpp | 4 ++-- include/snapshot_manager.hpp | 2 +- include/storage.hpp | 2 +- src/arrow/utils.cpp | 2 +- src/core/CMakeLists.txt | 3 +++ src/{ => core}/edge_store.cpp | 2 +- src/query.cpp | 2 +- src/query_execution.cpp | 2 +- src/snapshot_manager.cpp | 4 ++-- src/storage.cpp | 4 ++-- tests/edge_store_test.cpp | 4 ++-- tests/map_arena_test.cpp | 6 +++--- tests/node_arena_test.cpp | 4 ++-- tests/node_test.cpp | 4 ++-- tests/node_view_test.cpp | 4 ++-- tests/snapshot_test.cpp | 2 +- tests/where_expression_test.cpp | 2 +- 30 files changed, 44 insertions(+), 41 deletions(-) rename include/{ => core}/edge.hpp (99%) rename include/{ => core}/edge_store.hpp (99%) rename include/{ => core}/edge_view.hpp (100%) rename include/{ => core}/field_update.hpp (95%) rename include/{ => core}/node.hpp (99%) rename include/{ => core}/node_view.hpp (100%) rename include/{ => core}/update_type.hpp (100%) create mode 100644 src/core/CMakeLists.txt rename src/{ => core}/edge_store.cpp (99%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 560e1f8..6f3d5e3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -238,6 +238,7 @@ add_library(core) add_subdirectory(src/common) add_subdirectory(src/arrow) add_subdirectory(src/schema) +add_subdirectory(src/core) # Sources not yet moved to domain folders target_sources(core PRIVATE @@ -251,7 +252,6 @@ target_sources(core PRIVATE src/metadata.cpp src/snapshot_manager.cpp - src/edge_store.cpp ) target_include_directories(core diff --git a/include/common/utils.hpp b/include/common/utils.hpp index 1040efc..654e2ee 100644 --- a/include/common/utils.hpp +++ b/include/common/utils.hpp @@ -18,7 +18,7 @@ #include "arrow/utils.hpp" #include "common/constants.hpp" #include "common/logger.hpp" -#include "node.hpp" +#include "core/node.hpp" #include "query.hpp" #include "common/types.hpp" diff --git a/include/core.hpp b/include/core.hpp index 6bc3466..364ba6f 100644 --- a/include/core.hpp +++ b/include/core.hpp @@ -11,11 +11,11 @@ #include "arrow/utils.hpp" #include "common/config.hpp" -#include "edge_store.hpp" -#include "field_update.hpp" +#include "core/edge_store.hpp" +#include "core/field_update.hpp" #include "common/logger.hpp" #include "metadata.hpp" -#include "node.hpp" +#include "core/node.hpp" #include "query.hpp" #include "query_execution.hpp" #include "schema/schema.hpp" diff --git a/include/edge.hpp b/include/core/edge.hpp similarity index 99% rename from include/edge.hpp rename to include/core/edge.hpp index af63228..d5f0a82 100644 --- a/include/edge.hpp +++ b/include/core/edge.hpp @@ -8,13 +8,13 @@ #include #include "common/constants.hpp" -#include "edge_view.hpp" +#include "core/edge_view.hpp" #include "memory/node_arena.hpp" #include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "temporal_context.hpp" #include "common/types.hpp" -#include "update_type.hpp" +#include "core/update_type.hpp" namespace tundradb { class Edge { diff --git a/include/edge_store.hpp b/include/core/edge_store.hpp similarity index 99% rename from include/edge_store.hpp rename to include/core/edge_store.hpp index da7cbd9..8626fdf 100644 --- a/include/edge_store.hpp +++ b/include/core/edge_store.hpp @@ -12,7 +12,7 @@ #include #include "common/concurrency.hpp" -#include "edge.hpp" +#include "core/edge.hpp" #include "memory/node_arena.hpp" #include "schema/schema.hpp" #include "memory/schema_layout.hpp" diff --git a/include/edge_view.hpp b/include/core/edge_view.hpp similarity index 100% rename from include/edge_view.hpp rename to include/core/edge_view.hpp diff --git a/include/field_update.hpp b/include/core/field_update.hpp similarity index 95% rename from include/field_update.hpp rename to include/core/field_update.hpp index a54a6d4..36c6714 100644 --- a/include/field_update.hpp +++ b/include/core/field_update.hpp @@ -8,7 +8,7 @@ #include "schema/schema.hpp" #include "common/types.hpp" -#include "update_type.hpp" +#include "core/update_type.hpp" namespace tundradb { diff --git a/include/node.hpp b/include/core/node.hpp similarity index 99% rename from include/node.hpp rename to include/core/node.hpp index 5cfc2a3..ed7b55a 100644 --- a/include/node.hpp +++ b/include/core/node.hpp @@ -9,11 +9,11 @@ #include "common/constants.hpp" #include "common/logger.hpp" #include "memory/node_arena.hpp" -#include "node_view.hpp" +#include "core/node_view.hpp" #include "schema/schema.hpp" #include "temporal_context.hpp" #include "common/types.hpp" -#include "update_type.hpp" +#include "core/update_type.hpp" namespace tundradb { diff --git a/include/node_view.hpp b/include/core/node_view.hpp similarity index 100% rename from include/node_view.hpp rename to include/core/node_view.hpp diff --git a/include/update_type.hpp b/include/core/update_type.hpp similarity index 100% rename from include/update_type.hpp rename to include/core/update_type.hpp diff --git a/include/memory/node_arena.hpp b/include/memory/node_arena.hpp index 57dec76..48f8d78 100644 --- a/include/memory/node_arena.hpp +++ b/include/memory/node_arena.hpp @@ -13,7 +13,7 @@ #include "memory/array_arena.hpp" #include "common/clock.hpp" -#include "field_update.hpp" +#include "core/field_update.hpp" #include "memory/free_list_arena.hpp" #include "memory/map_arena.hpp" #include "memory/mem_arena.hpp" @@ -21,7 +21,7 @@ #include "memory/schema_layout.hpp" #include "memory/string_arena.hpp" #include "common/types.hpp" -#include "update_type.hpp" +#include "core/update_type.hpp" namespace tundradb { diff --git a/include/query.hpp b/include/query.hpp index 29c0fad..2deb9fb 100644 --- a/include/query.hpp +++ b/include/query.hpp @@ -18,7 +18,7 @@ #include #include -#include "node.hpp" +#include "core/node.hpp" #include "schema/schema.hpp" #include "temporal_context.hpp" #include "common/types.hpp" diff --git a/include/row.hpp b/include/row.hpp index cb481fe..f309bd9 100644 --- a/include/row.hpp +++ b/include/row.hpp @@ -13,9 +13,9 @@ #include #include "common/constants.hpp" -#include "edge.hpp" +#include "core/edge.hpp" #include "common/logger.hpp" -#include "node.hpp" +#include "core/node.hpp" #include "query.hpp" #include "common/types.hpp" diff --git a/include/shard.hpp b/include/shard.hpp index 8141dc6..83ccb4b 100644 --- a/include/shard.hpp +++ b/include/shard.hpp @@ -14,8 +14,8 @@ #include #include "common/config.hpp" -#include "field_update.hpp" -#include "node.hpp" +#include "core/field_update.hpp" +#include "core/node.hpp" #include "schema/schema.hpp" namespace tundradb { diff --git a/include/snapshot_manager.hpp b/include/snapshot_manager.hpp index b92b0da..28c4a29 100644 --- a/include/snapshot_manager.hpp +++ b/include/snapshot_manager.hpp @@ -4,7 +4,7 @@ #include -#include "edge_store.hpp" +#include "core/edge_store.hpp" #include "metadata.hpp" #include "schema/schema.hpp" diff --git a/include/storage.hpp b/include/storage.hpp index 7ec4a9d..f830b6f 100644 --- a/include/storage.hpp +++ b/include/storage.hpp @@ -7,7 +7,7 @@ #include #include "common/config.hpp" -#include "edge.hpp" +#include "core/edge.hpp" #include "metadata.hpp" namespace tundradb { diff --git a/src/arrow/utils.cpp b/src/arrow/utils.cpp index 60fbab2..b698651 100644 --- a/src/arrow/utils.cpp +++ b/src/arrow/utils.cpp @@ -15,7 +15,7 @@ #include "arrow/map_union_types.hpp" #include "common/logger.hpp" -#include "node.hpp" +#include "core/node.hpp" #include "query.hpp" #include "schema/schema.hpp" diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt new file mode 100644 index 0000000..a0ebfba --- /dev/null +++ b/src/core/CMakeLists.txt @@ -0,0 +1,3 @@ +target_sources(core PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/edge_store.cpp +) diff --git a/src/edge_store.cpp b/src/core/edge_store.cpp similarity index 99% rename from src/edge_store.cpp rename to src/core/edge_store.cpp index fed3081..1a2246d 100644 --- a/src/edge_store.cpp +++ b/src/core/edge_store.cpp @@ -1,4 +1,4 @@ -#include "edge_store.hpp" +#include "core/edge_store.hpp" #include #include diff --git a/src/query.cpp b/src/query.cpp index 3059254..972c505 100644 --- a/src/query.cpp +++ b/src/query.cpp @@ -5,7 +5,7 @@ #include #include -#include "edge.hpp" +#include "core/edge.hpp" #include "common/logger.hpp" namespace tundradb { diff --git a/src/query_execution.cpp b/src/query_execution.cpp index 54422fd..3268aa4 100644 --- a/src/query_execution.cpp +++ b/src/query_execution.cpp @@ -6,7 +6,7 @@ #include "arrow/map_union_types.hpp" #include "arrow/utils.hpp" #include "common/constants.hpp" -#include "edge_store.hpp" +#include "core/edge_store.hpp" #include "common/logger.hpp" #include "common/utils.hpp" diff --git a/src/snapshot_manager.cpp b/src/snapshot_manager.cpp index 36e986b..9131ea6 100644 --- a/src/snapshot_manager.cpp +++ b/src/snapshot_manager.cpp @@ -1,8 +1,8 @@ #include "snapshot_manager.hpp" -#include "edge.hpp" +#include "core/edge.hpp" #include "common/logger.hpp" -#include "node.hpp" +#include "core/node.hpp" #include "shard.hpp" #include "storage.hpp" #include "common/utils.hpp" diff --git a/src/storage.cpp b/src/storage.cpp index 2f62352..24d88e7 100644 --- a/src/storage.cpp +++ b/src/storage.cpp @@ -21,11 +21,11 @@ #include "arrow/utils.hpp" #include "common/constants.hpp" -#include "edge_store.hpp" +#include "core/edge_store.hpp" #include "json.hpp" #include "common/logger.hpp" #include "metadata.hpp" -#include "node.hpp" +#include "core/node.hpp" #include "shard.hpp" #include "arrow/table_info.hpp" diff --git a/tests/edge_store_test.cpp b/tests/edge_store_test.cpp index 59bcea4..db0b875 100644 --- a/tests/edge_store_test.cpp +++ b/tests/edge_store_test.cpp @@ -1,8 +1,8 @@ -#include "edge_store.hpp" +#include "core/edge_store.hpp" #include -#include "edge.hpp" +#include "core/edge.hpp" namespace tundradb { diff --git a/tests/map_arena_test.cpp b/tests/map_arena_test.cpp index 789e9d1..1ed9716 100644 --- a/tests/map_arena_test.cpp +++ b/tests/map_arena_test.cpp @@ -7,13 +7,13 @@ #include "memory/array_arena.hpp" #include "common/clock.hpp" -#include "../include/edge.hpp" -#include "../include/node.hpp" +#include "core/edge.hpp" +#include "core/node.hpp" #include "memory/node_arena.hpp" #include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "common/types.hpp" -#include "edge_store.hpp" +#include "core/edge_store.hpp" using namespace tundradb; diff --git a/tests/node_arena_test.cpp b/tests/node_arena_test.cpp index 3b57e34..e44fd96 100644 --- a/tests/node_arena_test.cpp +++ b/tests/node_arena_test.cpp @@ -7,9 +7,9 @@ #include #include -#include "../include/field_update.hpp" +#include "core/field_update.hpp" #include "memory/memory_arena.hpp" -#include "../include/node.hpp" +#include "core/node.hpp" #include "schema/schema.hpp" #include "memory/schema_layout.hpp" #include "common/types.hpp" diff --git a/tests/node_test.cpp b/tests/node_test.cpp index d0171aa..ba02739 100644 --- a/tests/node_test.cpp +++ b/tests/node_test.cpp @@ -1,4 +1,4 @@ -#include "../include/node.hpp" +#include "core/node.hpp" #include #include @@ -7,7 +7,7 @@ #include #include -#include "../include/field_update.hpp" +#include "core/field_update.hpp" #include "common/logger.hpp" #include "schema/schema.hpp" #include "common/types.hpp" diff --git a/tests/node_view_test.cpp b/tests/node_view_test.cpp index ea8d316..eed3fd6 100644 --- a/tests/node_view_test.cpp +++ b/tests/node_view_test.cpp @@ -1,11 +1,11 @@ -#include "../include/node_view.hpp" +#include "core/node_view.hpp" #include #include #include -#include "../include/node.hpp" +#include "core/node.hpp" #include "memory/node_arena.hpp" #include "schema/schema.hpp" #include "memory/schema_layout.hpp" diff --git a/tests/snapshot_test.cpp b/tests/snapshot_test.cpp index f72a83a..cd8725e 100644 --- a/tests/snapshot_test.cpp +++ b/tests/snapshot_test.cpp @@ -8,7 +8,7 @@ #include "arrow/map_union_types.hpp" #include "../include/core.hpp" -#include "../include/field_update.hpp" +#include "core/field_update.hpp" #include "common/logger.hpp" using namespace std::string_literals; diff --git a/tests/where_expression_test.cpp b/tests/where_expression_test.cpp index cb1dfae..37ff730 100644 --- a/tests/where_expression_test.cpp +++ b/tests/where_expression_test.cpp @@ -7,7 +7,7 @@ #include "arrow/map_union_types.hpp" #include "../include/core.hpp" -#include "../include/field_update.hpp" +#include "core/field_update.hpp" #include "common/logger.hpp" #include "../include/metadata.hpp" #include "../include/query.hpp" From e16558e59278c896a5277ee944734edbc5ed8477 Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 21:52:45 -0400 Subject: [PATCH 6/9] Move storage/ domain: storage, snapshot_manager, metadata, shard, file_utils - git mv 5 headers to include/storage/, 4 sources to src/storage/ - Add src/storage/CMakeLists.txt - Update all #include directives Made-with: Cursor --- CMakeLists.txt | 6 +----- include/core.hpp | 8 ++++---- include/{ => storage}/file_utils.hpp | 0 include/{ => storage}/metadata.hpp | 2 +- include/{ => storage}/shard.hpp | 0 include/{ => storage}/snapshot_manager.hpp | 2 +- include/{ => storage}/storage.hpp | 2 +- src/core/edge_store.cpp | 2 +- src/schema/schema.cpp | 2 +- src/storage/CMakeLists.txt | 6 ++++++ src/{ => storage}/metadata.cpp | 2 +- src/{ => storage}/shard.cpp | 2 +- src/{ => storage}/snapshot_manager.cpp | 6 +++--- src/{ => storage}/storage.cpp | 6 +++--- tests/benchmark_test.cpp | 2 +- tests/join_test.cpp | 2 +- tests/where_expression_test.cpp | 2 +- tests/where_pushdown_join_test.cpp | 2 +- 18 files changed, 28 insertions(+), 26 deletions(-) rename include/{ => storage}/file_utils.hpp (100%) rename include/{ => storage}/metadata.hpp (99%) rename include/{ => storage}/shard.hpp (100%) rename include/{ => storage}/snapshot_manager.hpp (99%) rename include/{ => storage}/storage.hpp (97%) create mode 100644 src/storage/CMakeLists.txt rename src/{ => storage}/metadata.cpp (99%) rename src/{ => storage}/shard.cpp (99%) rename src/{ => storage}/snapshot_manager.cpp (99%) rename src/{ => storage}/storage.cpp (99%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6f3d5e3..3d96f98 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -239,6 +239,7 @@ add_subdirectory(src/common) add_subdirectory(src/arrow) add_subdirectory(src/schema) add_subdirectory(src/core) +add_subdirectory(src/storage) # Sources not yet moved to domain folders target_sources(core PRIVATE @@ -247,11 +248,6 @@ target_sources(core PRIVATE src/query_execution.cpp src/join.cpp src/row.cpp - src/shard.cpp - src/storage.cpp - src/metadata.cpp - - src/snapshot_manager.cpp ) target_include_directories(core diff --git a/include/core.hpp b/include/core.hpp index 364ba6f..73c165f 100644 --- a/include/core.hpp +++ b/include/core.hpp @@ -14,14 +14,14 @@ #include "core/edge_store.hpp" #include "core/field_update.hpp" #include "common/logger.hpp" -#include "metadata.hpp" +#include "storage/metadata.hpp" #include "core/node.hpp" #include "query.hpp" #include "query_execution.hpp" #include "schema/schema.hpp" -#include "shard.hpp" -#include "snapshot_manager.hpp" -#include "storage.hpp" +#include "storage/shard.hpp" +#include "storage/snapshot_manager.hpp" +#include "storage/storage.hpp" #include "common/utils.hpp" namespace tundradb { diff --git a/include/file_utils.hpp b/include/storage/file_utils.hpp similarity index 100% rename from include/file_utils.hpp rename to include/storage/file_utils.hpp diff --git a/include/metadata.hpp b/include/storage/metadata.hpp similarity index 99% rename from include/metadata.hpp rename to include/storage/metadata.hpp index b6fba4c..d3d994d 100644 --- a/include/metadata.hpp +++ b/include/storage/metadata.hpp @@ -10,7 +10,7 @@ #include #include "arrow/map_union_types.hpp" -#include "file_utils.hpp" +#include "storage/file_utils.hpp" #include "json.hpp" #include "llvm/ADT/SmallVector.h" #include "common/logger.hpp" diff --git a/include/shard.hpp b/include/storage/shard.hpp similarity index 100% rename from include/shard.hpp rename to include/storage/shard.hpp diff --git a/include/snapshot_manager.hpp b/include/storage/snapshot_manager.hpp similarity index 99% rename from include/snapshot_manager.hpp rename to include/storage/snapshot_manager.hpp index 28c4a29..d52c874 100644 --- a/include/snapshot_manager.hpp +++ b/include/storage/snapshot_manager.hpp @@ -5,7 +5,7 @@ #include #include "core/edge_store.hpp" -#include "metadata.hpp" +#include "storage/metadata.hpp" #include "schema/schema.hpp" namespace tundradb { diff --git a/include/storage.hpp b/include/storage/storage.hpp similarity index 97% rename from include/storage.hpp rename to include/storage/storage.hpp index f830b6f..d4fdb31 100644 --- a/include/storage.hpp +++ b/include/storage/storage.hpp @@ -8,7 +8,7 @@ #include "common/config.hpp" #include "core/edge.hpp" -#include "metadata.hpp" +#include "storage/metadata.hpp" namespace tundradb { diff --git a/src/core/edge_store.cpp b/src/core/edge_store.cpp index 1a2246d..e70e6be 100644 --- a/src/core/edge_store.cpp +++ b/src/core/edge_store.cpp @@ -6,7 +6,7 @@ #include "common/constants.hpp" #include "json.hpp" #include "common/logger.hpp" -#include "metadata.hpp" +#include "storage/metadata.hpp" namespace tundradb { diff --git a/src/schema/schema.cpp b/src/schema/schema.cpp index a8bff73..75deb8b 100644 --- a/src/schema/schema.cpp +++ b/src/schema/schema.cpp @@ -4,7 +4,7 @@ #include "arrow/map_union_types.hpp" #include "arrow/utils.hpp" -#include "metadata.hpp" +#include "storage/metadata.hpp" namespace tundradb { diff --git a/src/storage/CMakeLists.txt b/src/storage/CMakeLists.txt new file mode 100644 index 0000000..f4e4df6 --- /dev/null +++ b/src/storage/CMakeLists.txt @@ -0,0 +1,6 @@ +target_sources(core PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/storage.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/snapshot_manager.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/metadata.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/shard.cpp +) diff --git a/src/metadata.cpp b/src/storage/metadata.cpp similarity index 99% rename from src/metadata.cpp rename to src/storage/metadata.cpp index dbb9c00..b972788 100644 --- a/src/metadata.cpp +++ b/src/storage/metadata.cpp @@ -1,4 +1,4 @@ -#include "metadata.hpp" +#include "storage/metadata.hpp" #include diff --git a/src/shard.cpp b/src/storage/shard.cpp similarity index 99% rename from src/shard.cpp rename to src/storage/shard.cpp index 048c2fc..ee954a4 100644 --- a/src/shard.cpp +++ b/src/storage/shard.cpp @@ -1,4 +1,4 @@ -#include "shard.hpp" +#include "storage/shard.hpp" #include "common/logger.hpp" #include "common/utils.hpp" diff --git a/src/snapshot_manager.cpp b/src/storage/snapshot_manager.cpp similarity index 99% rename from src/snapshot_manager.cpp rename to src/storage/snapshot_manager.cpp index 9131ea6..f302de7 100644 --- a/src/snapshot_manager.cpp +++ b/src/storage/snapshot_manager.cpp @@ -1,10 +1,10 @@ -#include "snapshot_manager.hpp" +#include "storage/snapshot_manager.hpp" #include "core/edge.hpp" #include "common/logger.hpp" #include "core/node.hpp" -#include "shard.hpp" -#include "storage.hpp" +#include "storage/shard.hpp" +#include "storage/storage.hpp" #include "common/utils.hpp" namespace tundradb { diff --git a/src/storage.cpp b/src/storage/storage.cpp similarity index 99% rename from src/storage.cpp rename to src/storage/storage.cpp index 24d88e7..1ac6781 100644 --- a/src/storage.cpp +++ b/src/storage/storage.cpp @@ -1,4 +1,4 @@ -#include "storage.hpp" +#include "storage/storage.hpp" #include #include @@ -24,9 +24,9 @@ #include "core/edge_store.hpp" #include "json.hpp" #include "common/logger.hpp" -#include "metadata.hpp" +#include "storage/metadata.hpp" #include "core/node.hpp" -#include "shard.hpp" +#include "storage/shard.hpp" #include "arrow/table_info.hpp" namespace tundradb { diff --git a/tests/benchmark_test.cpp b/tests/benchmark_test.cpp index 7c4097a..1aa25be 100644 --- a/tests/benchmark_test.cpp +++ b/tests/benchmark_test.cpp @@ -11,7 +11,7 @@ #include "../include/core.hpp" #include "common/logger.hpp" -#include "../include/metadata.hpp" +#include "storage/metadata.hpp" #include "../include/query.hpp" #include "common/types.hpp" diff --git a/tests/join_test.cpp b/tests/join_test.cpp index 6a7af21..cd1466c 100644 --- a/tests/join_test.cpp +++ b/tests/join_test.cpp @@ -7,7 +7,7 @@ #include "../include/core.hpp" #include "common/debug_utils.hpp" #include "common/logger.hpp" -#include "../include/metadata.hpp" +#include "storage/metadata.hpp" #include "../include/query.hpp" // Helper macro for Arrow operations diff --git a/tests/where_expression_test.cpp b/tests/where_expression_test.cpp index 37ff730..26dd336 100644 --- a/tests/where_expression_test.cpp +++ b/tests/where_expression_test.cpp @@ -9,7 +9,7 @@ #include "../include/core.hpp" #include "core/field_update.hpp" #include "common/logger.hpp" -#include "../include/metadata.hpp" +#include "storage/metadata.hpp" #include "../include/query.hpp" #include "common/utils.hpp" diff --git a/tests/where_pushdown_join_test.cpp b/tests/where_pushdown_join_test.cpp index 4a9f8ad..346d99c 100644 --- a/tests/where_pushdown_join_test.cpp +++ b/tests/where_pushdown_join_test.cpp @@ -11,7 +11,7 @@ #include "../include/core.hpp" #include "common/logger.hpp" -#include "../include/metadata.hpp" +#include "storage/metadata.hpp" #include "../include/query.hpp" #include "common/utils.hpp" From 28899e3c147b3d3c315444920920a2aeaf220227 Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 21:57:08 -0400 Subject: [PATCH 7/9] Move query/ domain: query, execution, row, join, temporal_context MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - git mv 5 headers to include/query/, 4 sources to src/query/ - Rename query_execution.hpp → execution.hpp, query_execution.cpp → execution.cpp - Add src/query/CMakeLists.txt - Update all #include directives Made-with: Cursor --- CMakeLists.txt | 5 +---- bench/tundra_runner.cpp | 2 +- include/common/utils.hpp | 2 +- include/core.hpp | 4 ++-- include/core/edge.hpp | 2 +- include/core/node.hpp | 2 +- include/core/node_view.hpp | 2 +- include/{query_execution.hpp => query/execution.hpp} | 2 +- include/{ => query}/join.hpp | 2 +- include/{ => query}/query.hpp | 2 +- include/{ => query}/row.hpp | 2 +- include/{ => query}/temporal_context.hpp | 0 src/arrow/utils.cpp | 2 +- src/core.cpp | 6 +++--- src/query/CMakeLists.txt | 6 ++++++ src/{query_execution.cpp => query/execution.cpp} | 2 +- src/{ => query}/join.cpp | 2 +- src/{ => query}/query.cpp | 2 +- src/{ => query}/row.cpp | 2 +- tests/array_query_test.cpp | 2 +- tests/benchmark_test.cpp | 2 +- tests/join_test.cpp | 2 +- tests/node_view_test.cpp | 2 +- tests/temporal_query_test.cpp | 4 ++-- tests/update_query_join_test.cpp | 2 +- tests/update_query_test.cpp | 2 +- tests/where_expression_test.cpp | 2 +- tests/where_pushdown_join_test.cpp | 2 +- 28 files changed, 36 insertions(+), 33 deletions(-) rename include/{query_execution.hpp => query/execution.hpp} (99%) rename include/{ => query}/join.hpp (99%) rename include/{ => query}/query.hpp (99%) rename include/{ => query}/row.hpp (99%) rename include/{ => query}/temporal_context.hpp (100%) create mode 100644 src/query/CMakeLists.txt rename src/{query_execution.cpp => query/execution.cpp} (99%) rename src/{ => query}/join.cpp (99%) rename src/{ => query}/query.cpp (99%) rename src/{ => query}/row.cpp (99%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 3d96f98..c4290bb 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -240,14 +240,11 @@ add_subdirectory(src/arrow) add_subdirectory(src/schema) add_subdirectory(src/core) add_subdirectory(src/storage) +add_subdirectory(src/query) # Sources not yet moved to domain folders target_sources(core PRIVATE src/core.cpp - src/query.cpp - src/query_execution.cpp - src/join.cpp - src/row.cpp ) target_include_directories(core diff --git a/bench/tundra_runner.cpp b/bench/tundra_runner.cpp index d237442..818930b 100644 --- a/bench/tundra_runner.cpp +++ b/bench/tundra_runner.cpp @@ -7,7 +7,7 @@ #include #include "../include/core.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" #include "common/types.hpp" using namespace tundradb; diff --git a/include/common/utils.hpp b/include/common/utils.hpp index 654e2ee..adc43d3 100644 --- a/include/common/utils.hpp +++ b/include/common/utils.hpp @@ -19,7 +19,7 @@ #include "common/constants.hpp" #include "common/logger.hpp" #include "core/node.hpp" -#include "query.hpp" +#include "query/query.hpp" #include "common/types.hpp" namespace tundradb { diff --git a/include/core.hpp b/include/core.hpp index 73c165f..9ec7bb7 100644 --- a/include/core.hpp +++ b/include/core.hpp @@ -16,8 +16,8 @@ #include "common/logger.hpp" #include "storage/metadata.hpp" #include "core/node.hpp" -#include "query.hpp" -#include "query_execution.hpp" +#include "query/query.hpp" +#include "query/execution.hpp" #include "schema/schema.hpp" #include "storage/shard.hpp" #include "storage/snapshot_manager.hpp" diff --git a/include/core/edge.hpp b/include/core/edge.hpp index d5f0a82..92447ac 100644 --- a/include/core/edge.hpp +++ b/include/core/edge.hpp @@ -12,7 +12,7 @@ #include "memory/node_arena.hpp" #include "schema/schema.hpp" #include "memory/schema_layout.hpp" -#include "temporal_context.hpp" +#include "query/temporal_context.hpp" #include "common/types.hpp" #include "core/update_type.hpp" diff --git a/include/core/node.hpp b/include/core/node.hpp index ed7b55a..33cfbf4 100644 --- a/include/core/node.hpp +++ b/include/core/node.hpp @@ -11,7 +11,7 @@ #include "memory/node_arena.hpp" #include "core/node_view.hpp" #include "schema/schema.hpp" -#include "temporal_context.hpp" +#include "query/temporal_context.hpp" #include "common/types.hpp" #include "core/update_type.hpp" diff --git a/include/core/node_view.hpp b/include/core/node_view.hpp index 7f5adc3..ee9c903 100644 --- a/include/core/node_view.hpp +++ b/include/core/node_view.hpp @@ -7,7 +7,7 @@ #include "memory/node_arena.hpp" #include "schema/schema.hpp" -#include "temporal_context.hpp" +#include "query/temporal_context.hpp" #include "common/types.hpp" namespace tundradb { diff --git a/include/query_execution.hpp b/include/query/execution.hpp similarity index 99% rename from include/query_execution.hpp rename to include/query/execution.hpp index 32e8e67..eeeaa54 100644 --- a/include/query_execution.hpp +++ b/include/query/execution.hpp @@ -18,7 +18,7 @@ #include #include -#include "query.hpp" +#include "query/query.hpp" #include "schema/schema.hpp" namespace tundradb { diff --git a/include/join.hpp b/include/query/join.hpp similarity index 99% rename from include/join.hpp rename to include/query/join.hpp index 6f4aa1a..74553af 100644 --- a/include/join.hpp +++ b/include/query/join.hpp @@ -5,7 +5,7 @@ #include -#include "query.hpp" +#include "query/query.hpp" namespace tundradb { diff --git a/include/query.hpp b/include/query/query.hpp similarity index 99% rename from include/query.hpp rename to include/query/query.hpp index 2deb9fb..7fbb08d 100644 --- a/include/query.hpp +++ b/include/query/query.hpp @@ -20,7 +20,7 @@ #include "core/node.hpp" #include "schema/schema.hpp" -#include "temporal_context.hpp" +#include "query/temporal_context.hpp" #include "common/types.hpp" namespace tundradb { diff --git a/include/row.hpp b/include/query/row.hpp similarity index 99% rename from include/row.hpp rename to include/query/row.hpp index f309bd9..9bb6100 100644 --- a/include/row.hpp +++ b/include/query/row.hpp @@ -16,7 +16,7 @@ #include "core/edge.hpp" #include "common/logger.hpp" #include "core/node.hpp" -#include "query.hpp" +#include "query/query.hpp" #include "common/types.hpp" namespace tundradb { diff --git a/include/temporal_context.hpp b/include/query/temporal_context.hpp similarity index 100% rename from include/temporal_context.hpp rename to include/query/temporal_context.hpp diff --git a/src/arrow/utils.cpp b/src/arrow/utils.cpp index b698651..faf698e 100644 --- a/src/arrow/utils.cpp +++ b/src/arrow/utils.cpp @@ -16,7 +16,7 @@ #include "arrow/map_union_types.hpp" #include "common/logger.hpp" #include "core/node.hpp" -#include "query.hpp" +#include "query/query.hpp" #include "schema/schema.hpp" namespace tundradb { diff --git a/src/core.cpp b/src/core.cpp index 3dc6dcc..1fd88b0 100644 --- a/src/core.cpp +++ b/src/core.cpp @@ -21,10 +21,10 @@ #include #include "arrow/utils.hpp" -#include "join.hpp" +#include "query/join.hpp" #include "common/logger.hpp" -#include "row.hpp" -#include "temporal_context.hpp" +#include "query/row.hpp" +#include "query/temporal_context.hpp" #include "common/utils.hpp" namespace fs = std::filesystem; diff --git a/src/query/CMakeLists.txt b/src/query/CMakeLists.txt new file mode 100644 index 0000000..15f84c3 --- /dev/null +++ b/src/query/CMakeLists.txt @@ -0,0 +1,6 @@ +target_sources(core PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/query.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/execution.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/row.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/join.cpp +) diff --git a/src/query_execution.cpp b/src/query/execution.cpp similarity index 99% rename from src/query_execution.cpp rename to src/query/execution.cpp index 3268aa4..0360b0a 100644 --- a/src/query_execution.cpp +++ b/src/query/execution.cpp @@ -1,4 +1,4 @@ -#include "query_execution.hpp" +#include "query/execution.hpp" #include #include diff --git a/src/join.cpp b/src/query/join.cpp similarity index 99% rename from src/join.cpp rename to src/query/join.cpp index 005e193..ae8b8d5 100644 --- a/src/join.cpp +++ b/src/query/join.cpp @@ -1,4 +1,4 @@ -#include "join.hpp" +#include "query/join.hpp" #include "common/logger.hpp" #include "common/utils.hpp" diff --git a/src/query.cpp b/src/query/query.cpp similarity index 99% rename from src/query.cpp rename to src/query/query.cpp index 972c505..d67537b 100644 --- a/src/query.cpp +++ b/src/query/query.cpp @@ -1,4 +1,4 @@ -#include "query.hpp" +#include "query/query.hpp" #include #include diff --git a/src/row.cpp b/src/query/row.cpp similarity index 99% rename from src/row.cpp rename to src/query/row.cpp index ee1f091..0004c10 100644 --- a/src/row.cpp +++ b/src/query/row.cpp @@ -1,4 +1,4 @@ -#include "row.hpp" +#include "query/row.hpp" #include "common/logger.hpp" diff --git a/tests/array_query_test.cpp b/tests/array_query_test.cpp index 6bde469..284b5ea 100644 --- a/tests/array_query_test.cpp +++ b/tests/array_query_test.cpp @@ -6,7 +6,7 @@ #include "common/clock.hpp" #include "../include/core.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" #include "common/utils.hpp" #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/benchmark_test.cpp b/tests/benchmark_test.cpp index 1aa25be..5d72fbf 100644 --- a/tests/benchmark_test.cpp +++ b/tests/benchmark_test.cpp @@ -12,7 +12,7 @@ #include "../include/core.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" #include "common/types.hpp" // Helper macro for Arrow operations diff --git a/tests/join_test.cpp b/tests/join_test.cpp index cd1466c..13a9843 100644 --- a/tests/join_test.cpp +++ b/tests/join_test.cpp @@ -8,7 +8,7 @@ #include "common/debug_utils.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" // Helper macro for Arrow operations #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/node_view_test.cpp b/tests/node_view_test.cpp index eed3fd6..9384e60 100644 --- a/tests/node_view_test.cpp +++ b/tests/node_view_test.cpp @@ -9,7 +9,7 @@ #include "memory/node_arena.hpp" #include "schema/schema.hpp" #include "memory/schema_layout.hpp" -#include "../include/temporal_context.hpp" +#include "query/temporal_context.hpp" using namespace tundradb; diff --git a/tests/temporal_query_test.cpp b/tests/temporal_query_test.cpp index ae72801..0141f6b 100644 --- a/tests/temporal_query_test.cpp +++ b/tests/temporal_query_test.cpp @@ -6,8 +6,8 @@ #include "../include/core.hpp" #include "common/logger.hpp" #include "memory/node_arena.hpp" -#include "../include/query.hpp" -#include "../include/temporal_context.hpp" +#include "query/query.hpp" +#include "query/temporal_context.hpp" using namespace tundradb; diff --git a/tests/update_query_join_test.cpp b/tests/update_query_join_test.cpp index 937aadc..ab0f877 100644 --- a/tests/update_query_join_test.cpp +++ b/tests/update_query_join_test.cpp @@ -7,7 +7,7 @@ #include #include "../include/core.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" #include "common/utils.hpp" #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/update_query_test.cpp b/tests/update_query_test.cpp index a40159f..059d054 100644 --- a/tests/update_query_test.cpp +++ b/tests/update_query_test.cpp @@ -6,7 +6,7 @@ #include "arrow/map_union_types.hpp" #include "../include/core.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" #include "common/utils.hpp" #define ASSERT_OK(expr) ASSERT_TRUE((expr).ok()) diff --git a/tests/where_expression_test.cpp b/tests/where_expression_test.cpp index 26dd336..3cda925 100644 --- a/tests/where_expression_test.cpp +++ b/tests/where_expression_test.cpp @@ -10,7 +10,7 @@ #include "core/field_update.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" #include "common/utils.hpp" // Helper macro for Arrow operations diff --git a/tests/where_pushdown_join_test.cpp b/tests/where_pushdown_join_test.cpp index 346d99c..ad19f14 100644 --- a/tests/where_pushdown_join_test.cpp +++ b/tests/where_pushdown_join_test.cpp @@ -12,7 +12,7 @@ #include "../include/core.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" -#include "../include/query.hpp" +#include "query/query.hpp" #include "common/utils.hpp" // Helper macro for Arrow operations From d0fe0f8a4df69cc96ddecae60768caefeef75691 Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 21:59:44 -0400 Subject: [PATCH 8/9] =?UTF-8?q?Move=20main/=20domain:=20core.hpp=20?= =?UTF-8?q?=E2=86=92=20main/database.hpp,=20core.cpp=20=E2=86=92=20main/da?= =?UTF-8?q?tabase.cpp?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Rename Database facade to main/ following KuzuDB convention - Add src/main/CMakeLists.txt - Update all #include directives Made-with: Cursor --- CMakeLists.txt | 6 +----- bench/tundra_runner.cpp | 2 +- include/{core.hpp => main/database.hpp} | 0 src/main/CMakeLists.txt | 3 +++ src/{core.cpp => main/database.cpp} | 2 +- src/tundra_shell.cpp | 2 +- tests/array_query_test.cpp | 2 +- tests/benchmark_test.cpp | 2 +- tests/database_test.cpp | 2 +- tests/join_test.cpp | 2 +- tests/sharding_test.cpp | 2 +- tests/snapshot_test.cpp | 2 +- tests/temporal_query_test.cpp | 2 +- tests/update_query_join_test.cpp | 2 +- tests/update_query_test.cpp | 2 +- tests/where_expression_test.cpp | 2 +- tests/where_pushdown_join_test.cpp | 2 +- 17 files changed, 18 insertions(+), 19 deletions(-) rename include/{core.hpp => main/database.hpp} (100%) create mode 100644 src/main/CMakeLists.txt rename src/{core.cpp => main/database.cpp} (99%) diff --git a/CMakeLists.txt b/CMakeLists.txt index c4290bb..720e066 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -241,11 +241,7 @@ add_subdirectory(src/schema) add_subdirectory(src/core) add_subdirectory(src/storage) add_subdirectory(src/query) - -# Sources not yet moved to domain folders -target_sources(core PRIVATE - src/core.cpp -) +add_subdirectory(src/main) target_include_directories(core PUBLIC diff --git a/bench/tundra_runner.cpp b/bench/tundra_runner.cpp index 818930b..a52e002 100644 --- a/bench/tundra_runner.cpp +++ b/bench/tundra_runner.cpp @@ -6,7 +6,7 @@ #include #include -#include "../include/core.hpp" +#include "main/database.hpp" #include "query/query.hpp" #include "common/types.hpp" diff --git a/include/core.hpp b/include/main/database.hpp similarity index 100% rename from include/core.hpp rename to include/main/database.hpp diff --git a/src/main/CMakeLists.txt b/src/main/CMakeLists.txt new file mode 100644 index 0000000..5af71fa --- /dev/null +++ b/src/main/CMakeLists.txt @@ -0,0 +1,3 @@ +target_sources(core PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/database.cpp +) diff --git a/src/core.cpp b/src/main/database.cpp similarity index 99% rename from src/core.cpp rename to src/main/database.cpp index 1fd88b0..730dc53 100644 --- a/src/core.cpp +++ b/src/main/database.cpp @@ -1,4 +1,4 @@ -#include "core.hpp" +#include "main/database.hpp" #include #include diff --git a/src/tundra_shell.cpp b/src/tundra_shell.cpp index d33e9b8..a13de13 100644 --- a/src/tundra_shell.cpp +++ b/src/tundra_shell.cpp @@ -28,7 +28,7 @@ #include "TundraQLParser.h" #include "arrow/map_union_types.hpp" #include "common/constants.hpp" -#include "core.hpp" +#include "main/database.hpp" #include "linenoise.h" #include "common/logger.hpp" #include "common/types.hpp" diff --git a/tests/array_query_test.cpp b/tests/array_query_test.cpp index 284b5ea..95ddf23 100644 --- a/tests/array_query_test.cpp +++ b/tests/array_query_test.cpp @@ -5,7 +5,7 @@ #include #include "common/clock.hpp" -#include "../include/core.hpp" +#include "main/database.hpp" #include "query/query.hpp" #include "common/utils.hpp" diff --git a/tests/benchmark_test.cpp b/tests/benchmark_test.cpp index 5d72fbf..ddc1560 100644 --- a/tests/benchmark_test.cpp +++ b/tests/benchmark_test.cpp @@ -9,7 +9,7 @@ #include #include -#include "../include/core.hpp" +#include "main/database.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" #include "query/query.hpp" diff --git a/tests/database_test.cpp b/tests/database_test.cpp index 4d66166..ea6f285 100644 --- a/tests/database_test.cpp +++ b/tests/database_test.cpp @@ -6,7 +6,7 @@ #include -#include "core.hpp" +#include "main/database.hpp" #include "common/logger.hpp" using namespace tundradb; diff --git a/tests/join_test.cpp b/tests/join_test.cpp index 13a9843..1f6de37 100644 --- a/tests/join_test.cpp +++ b/tests/join_test.cpp @@ -4,7 +4,7 @@ #include #include -#include "../include/core.hpp" +#include "main/database.hpp" #include "common/debug_utils.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" diff --git a/tests/sharding_test.cpp b/tests/sharding_test.cpp index 250c6dc..417733d 100644 --- a/tests/sharding_test.cpp +++ b/tests/sharding_test.cpp @@ -5,7 +5,7 @@ #include #include "arrow/utils.hpp" -#include "../include/core.hpp" +#include "main/database.hpp" #include "common/debug_utils.hpp" using namespace tundradb; diff --git a/tests/snapshot_test.cpp b/tests/snapshot_test.cpp index cd8725e..ec26e96 100644 --- a/tests/snapshot_test.cpp +++ b/tests/snapshot_test.cpp @@ -7,7 +7,7 @@ #include #include "arrow/map_union_types.hpp" -#include "../include/core.hpp" +#include "main/database.hpp" #include "core/field_update.hpp" #include "common/logger.hpp" diff --git a/tests/temporal_query_test.cpp b/tests/temporal_query_test.cpp index 0141f6b..44ecc11 100644 --- a/tests/temporal_query_test.cpp +++ b/tests/temporal_query_test.cpp @@ -3,7 +3,7 @@ #include #include "common/clock.hpp" -#include "../include/core.hpp" +#include "main/database.hpp" #include "common/logger.hpp" #include "memory/node_arena.hpp" #include "query/query.hpp" diff --git a/tests/update_query_join_test.cpp b/tests/update_query_join_test.cpp index ab0f877..e075126 100644 --- a/tests/update_query_join_test.cpp +++ b/tests/update_query_join_test.cpp @@ -6,7 +6,7 @@ #include #include -#include "../include/core.hpp" +#include "main/database.hpp" #include "query/query.hpp" #include "common/utils.hpp" diff --git a/tests/update_query_test.cpp b/tests/update_query_test.cpp index 059d054..5bbc907 100644 --- a/tests/update_query_test.cpp +++ b/tests/update_query_test.cpp @@ -5,7 +5,7 @@ #include #include "arrow/map_union_types.hpp" -#include "../include/core.hpp" +#include "main/database.hpp" #include "query/query.hpp" #include "common/utils.hpp" diff --git a/tests/where_expression_test.cpp b/tests/where_expression_test.cpp index 3cda925..7b0b1ae 100644 --- a/tests/where_expression_test.cpp +++ b/tests/where_expression_test.cpp @@ -6,7 +6,7 @@ #include #include "arrow/map_union_types.hpp" -#include "../include/core.hpp" +#include "main/database.hpp" #include "core/field_update.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" diff --git a/tests/where_pushdown_join_test.cpp b/tests/where_pushdown_join_test.cpp index ad19f14..a3f876a 100644 --- a/tests/where_pushdown_join_test.cpp +++ b/tests/where_pushdown_join_test.cpp @@ -9,7 +9,7 @@ #include #include -#include "../include/core.hpp" +#include "main/database.hpp" #include "common/logger.hpp" #include "storage/metadata.hpp" #include "query/query.hpp" From 4876c3ebfd36420c0f2058606f7ec322d9488c65 Mon Sep 17 00:00:00 2001 From: dmgcodevil Date: Fri, 3 Apr 2026 22:07:54 -0400 Subject: [PATCH 9/9] =?UTF-8?q?Move=20apps/=20domain:=20tundra=5Fshell.cpp?= =?UTF-8?q?=20=E2=86=92=20apps/?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Move shell binary source out of src/ into apps/ - Update CMakeLists.txt executable path Made-with: Cursor --- CMakeLists.txt | 2 +- {src => apps}/tundra_shell.cpp | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename {src => apps}/tundra_shell.cpp (100%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 720e066..e8a00dc 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -375,7 +375,7 @@ if(TUNDRADB_BUILD_SHELL) endif() # Interactive shell executable - add_executable(tundra_shell src/tundra_shell.cpp libs/linenoise/linenoise.c) + add_executable(tundra_shell apps/tundra_shell.cpp libs/linenoise/linenoise.c) target_include_directories(tundra_shell PRIVATE diff --git a/src/tundra_shell.cpp b/apps/tundra_shell.cpp similarity index 100% rename from src/tundra_shell.cpp rename to apps/tundra_shell.cpp