98 Commits

Author SHA1 Message Date
a31d8739e2
docs: enhance JSDoc for DockerOrchestrator cleanup methods
- Add detailed documentation for `cleanup()` and `cleanupFailedStart()` methods
- Clarify the purpose, behavior, and differences between the methods
- Document parameters, return values, and error handling
- Add @remarks sections for important implementation details
2025-06-19 16:58:09 -05:00
87699dd1af
refactor: simplify node startup and improve test reliability
- Remove waitForReady option from RhizomeNode.start() and always wait for readiness
- Update test files to use simplified start() method
- Clean up debug logging in lossless view
- Rename docker orchestrator test file to remove version suffix
2025-06-19 16:58:09 -05:00
8059a5350a
Windsurf workflow to generate a merge request summary 2025-06-19 16:58:08 -05:00
be0f0659b9
Remove empty test 2025-06-19 16:58:08 -05:00
c8d38a4af2
refactor: remove dockerOptions and fix resource limits
- Removed unused dockerOptions from DockerOrchestrator and all manager classes
- Updated container-manager to use NanoCpus for CPU limits instead of CpuQuota/CpuPeriod
- Fixed resource limit enforcement in container configuration
- Improved test reliability and error handling
- Cleaned up test files and removed unused code
2025-06-19 16:58:08 -05:00
b5c0c010a9
feat: Refactor Docker orchestrator and enhance test utilities
This commit includes a major refactoring of the Docker orchestrator implementation
along with improvements to the testing infrastructure:

- Refactored Docker orchestrator to handle dynamic port assignment
- Added comprehensive test utilities in docker-test-utils.ts
- Improved error handling and resource cleanup in test environments
- Enhanced NodeStatus interface with containerId and networkId
- Added support for different storage types in NodeConfig
- Fixed request port handling in TestOrchestrator
- Added proper cleanup method to NodeOrchestrator interface

The changes ensure more reliable container management and better test isolation
while maintaining backward compatibility with existing implementations.

BREAKING CHANGE: The NodeOrchestrator interface now requires a cleanup() method.
2025-06-19 16:58:07 -05:00
feb7639978
docker orchestrator is working 2025-06-19 16:58:07 -05:00
0ad4d8d576
Fixed/simplified tsconfig and docker setup 2025-06-19 16:58:06 -05:00
b78985779b
Implement Docker orchestrator and fix test infrastructure
- Add DockerOrchestrator implementation with container management
- Refactor InMemoryOrchestrator to use RhizomeNode directly
- Fix orchestrated test files for single and two-node scenarios
- Update package.json with dockerode dependency
- Clean up old test files and imports
2025-06-19 16:58:06 -05:00
922610ec38
npm audit fix 2025-06-19 16:58:01 -05:00
63026d069e Update README.md 2025-06-15 14:33:29 -05:00
1b9ed0a6dd Merge pull request 'pr-1-feedback' (#2) from pr-1-feedback into main
Reviewed-on: #2
2025-06-15 14:26:31 -05:00
6c13f46714
fix(negation): improve negation chain handling and clean up logging
- Refactored isDeltaNegated to properly handle complex negation chains
- Added recursive negation detection to account for negations of negations
- Replaced console.log with debug statements in tests
- Improved test coverage and documentation
- Fixed TypeScript type issues
2025-06-15 14:15:49 -05:00
4b750c593d
feat(query): validate JSON Logic operators and improve error handling
- Add validation for JSON Logic operators in query filters
- Throw InvalidQueryOperatorError for invalid operators
- Improve error handling and logging in applyJsonLogicFilter
- Update tests to verify new error handling behavior
- Fix TypeScript linting issues and improve code style
2025-06-15 14:15:49 -05:00
51d336b88b
feat: handle undefined values in custom resolvers
- Update ResolverPlugin interface to allow resolve() to return undefined
- Modify CustomResolver to skip properties with undefined values
- Add test case for resolvers that return undefined
- Update existing tests to handle cases where no properties are resolved

This change makes the behavior more explicit when resolvers don't return a value,
which is particularly important for numeric aggregations where 0 might be a valid result.
2025-06-15 14:15:48 -05:00
d5cc436bcb
chore: remove unused _RhizomeImports from test files
- Removed unused _RhizomeImports from:
  - __tests__/compose-decompose.ts
  - __tests__/transactions.ts
  - __tests__/negation.ts
- All tests continue to pass after removal
2025-06-15 14:15:48 -05:00
35bbc974d8
refactor: move common resolve logic to base Lossy class
- Moved the resolve method implementation from individual resolvers to the base Lossy class
- Updated initializer methods to accept a LosslessViewOne parameter
- Removed redundant resolve methods from LastWriteWins, TimestampResolver, CustomResolver, and AggregationResolver
- Ensured consistent behavior across all resolver implementations
- All tests passing with the refactored code
2025-06-15 14:15:48 -05:00
dd8987563a
Fix recursion depth test validity
Previosly a failure to correctly limit the depth might not be detected
2025-06-15 14:15:47 -05:00
885630f4d9
refactor: move CommonSchemas to test-utils
- Moved CommonSchemas from src/schema/schema.ts to src/test-utils/schemas.ts
- Updated all test files to import CommonSchemas from the new location
- Fixed the Document schema to match test expectations by making the author field required
- Added additional fields to the Document schema to match the original implementation
- Ensured all tests pass with the new implementation

Addresses PR feedback that CommonSchemas is only used in tests and should be moved to test files.
2025-06-15 14:15:47 -05:00
08fb5778ba
fix: update comment about LastWriteWins tie-breaking algorithm
Addresses PR feedback about the outdated comment in concurrent-writes.ts. The comment now accurately reflects that the resolution uses the LastWriteWins resolver's tie-breaking algorithm rather than delta processing order.
2025-06-15 14:15:46 -05:00
91514289ae
Entity conforms to schema if it has all required properties, not just some 2025-06-15 14:15:46 -05:00
ada27ff1b0
removed data/ and test-data/ from repo 2025-06-15 14:15:46 -05:00
04212e87e6 Merge pull request 'major changes and feature additions' (#1) from claude_code_work into main
Reviewed-on: #1
2025-06-15 14:08:40 -05:00
cd83f026cd
add .env to .gitignore 2025-06-14 17:03:10 -05:00
98014aaa17
add script for generating test coverage report 2025-06-14 17:01:33 -05:00
af8f49ebbc updating todo with leveldb details that we just... did 2025-06-09 22:47:54 -04:00
1c55e95a7b cleanup and levelDB integration 2025-06-09 22:37:51 -04:00
c8488843d2 refactored file structure, added levelDB (needs work) 2025-06-09 21:53:28 -04:00
9a7bd7d3b0 implemented initial query engine and exposed HTTP endpoints 2025-06-09 21:23:18 -04:00
c2f1f537f7 major refactor to shore up some misalignments, ready for phase 3 2025-06-09 20:50:33 -04:00
2dbf9a420a Conflict Resolution strategies completed 2025-06-09 15:01:09 -04:00
c2aae9cfe6 support for negations complete 2025-06-09 13:39:25 -04:00
dc59dcc778 schema foundation support complete 2025-06-09 13:21:52 -04:00
33d4f92f8d transaction support done, deferred rollback 2025-06-09 12:55:15 -04:00
ba9cbc220d delta validation and error handling done 2025-06-09 12:47:37 -04:00
969e6ddc10 initial evaluation through todo.md 2025-06-09 12:37:04 -04:00
Ladd
b5e1acf4e3 minor stuff 2025-01-02 21:26:13 -06:00
Ladd
f1fcd97fe2 clarify type name 2025-01-02 21:22:29 -06:00
Ladd
6e0dccdfea refactored collection into abstract and basic in preparation for adding relational 2025-01-02 21:21:16 -06:00
Ladd
c6f6ece504 refactoring in preparation for adding more resolvers 2025-01-02 20:29:26 -06:00
Ladd
e684eac932 indentation 2025-01-02 17:00:21 -06:00
Ladd
39d70b4680 added more concise syntax for deltas 2025-01-02 16:58:51 -06:00
Ladd
b147378bf8 achieve clean shutdown, no open handles 2025-01-02 14:43:32 -06:00
Ladd
58c5f5dc4e switched back to commonjs rather than esm 2025-01-01 22:56:34 -06:00
Ladd
756fd240f5 removed libp2p/gossipsub 2025-01-01 22:45:17 -06:00
Ladd
b4451a4d7a reduce logging 2025-01-01 22:31:07 -06:00
Ladd
65572a0e01 imports formatting 2025-01-01 22:27:16 -06:00
Ladd
e89d07c127 removed old comments 2025-01-01 22:26:51 -06:00
Ladd
4eec3b294c refactored lossy for clarity, added separate class for last write wins 2025-01-01 22:21:16 -06:00
Ladd
5161ab0a85 remove unnecessary debug statements 2024-12-31 19:03:39 -06:00