Releases: xdb-project/xdb
Releases · xdb-project/xdb
Release list
XDB v1.4.2 - add test mode API and prevent storage pollution
[1.4.2] - 2026-02-01
Added
- Test Mode API: Introduced
db_set_test_mode()to suppress background maintenance tasks, ensuring a cleaner environment during automated testing.
Fixed
- Storage Pollution: Prevented snapshot triggering during unit tests to avoid unwanted data persistence in the
data/directory.
XDB v1.4.1 - resolve SIGSEGV and memory corruption
[1.4.1] - 2026-01-31
Fixed (Stability & Memory Integrity)
- Atomic Insert (Deep Copy): Resolved Use-After-Free memory corruption by implementing
cJSON_Duplicatein thedb_insertfunction. The database now maintains full memory ownership, isolated from the network layer request lifecycle. - Safe Detach-Append Strategy: Replaced destructive in-place replacement with a Detach & Append strategy for update operations. This ensures internal Linked List pointer integrity during high-concurrency access.
- Thread-Safe Iteration: Replaced standard iteration macros with manual pointer navigation to prevent race conditions when the collection structure is modified by concurrent threads.
- SIGSEGV Prevention: Eliminated the primary cause of Segmentation Faults in the
get_object_itemfunction, previously triggered by dangling pointer access.
XDB v1.4.0 - implement selective update patch, enforce id immutability
[1.4.0] - 2026-01-30
Added
- Selective Update (Patch): Supported partial updates, allowing users to update specific fields without overwriting the entire document.
Enforced
- _id Immutability: Implemented strict protection to ensure any attempt to modify the unique identifier (
_id) during an update is ignored, maintaining data integrity.
Optimized
- Memory Pointer Synchronization: Improved synchronization between
g_indexand the main document store to ensure data consistency and faster lookups.
XDB v1.3.0 - implement atomic update and upsert
[1.3.0] - 2026-01-30
Added
- Atomic Update: Implemented
db_updatefunction for efficient document updates without altering the_id. - Upsert Logic: Introduced
db_upsertfunction to automatically determine whether to perform an insert or update based on ID existence. - Protocol Extension: Integrated
updateandupsertactions intoserver.cfor network-layer access. - Regression Tests: Added new test cases in
test_crud.cto verify data update workflows.
Fixed
- Compiler Warnings: Added
<stdlib.h>header in unit tests to resolve implicitfree()declaration issues. - Test Compatibility: Replaced
ASSERT_STR_EQmacro with standardstrcmpintest_crud.cto ensure compilation stability.
XDB v1.2.0 - implement in-memory indexing for O(1) ID lookups
[1.2.0] - 2026-01-29
Added
- Basic Indexing: Implemented an in-memory Hash Map (O(1) Lookups) for _id fields to replace linear scans during ID-based queries.
- Index Synchronization: Automatic index updates on document insertion and deletion to ensure data consistency.
Improved
- Search Performance: Significant latency reduction for large datasets when querying by unique identifier.
Fixed
- Deep Copy Indexing: Resolved empty data return in
db_findby implementing Deep Copy indexing to ensure data persistence during retrieval.
XDB v1.1.0 - add database snapshot feature
[1.1.0] - 2026-01-29
Added
- Snapshot System: Added Auto-Snapshotting every 5 writes and Manual Snapshot action via TCP (
{"action": "snapshot"}).
Fixed
- Empty Request Handling Added a filter to ignore whitespace-only or empty newline messages from clients
XDB v1.0.0 - initial release
[1.0.0] - 2026-01-27
Added
- Core Engine: Initial implementation of the JSON-based database engine.
- CRUD Operations: Full support for Create, Read, Update, and Delete operations.
- Dependency Management: Integrated
cJSONlibrary via Git Submodules for high-performance JSON parsing. - CI/CD Pipeline:
- Automated code formatting with
clang-format. - Static analysis using
cppcheckwith a custom suppression list. - Multi-compiler build verification (GCC and Clang).
- Memory safety validation using
Valgrindfor Pull Requests.
- Automated code formatting with
- Build System: Optimized Makefile for clean compilation and automated unit testing.
- Project Structure: Standardized C project layout (
src,include,third_party). - Documentation: Comprehensive README and initial project configuration files.