Skip to content

feat: keep all projections in memory - #404

Draft
daniel-mader wants to merge 5 commits into
betafrom
feat/in-memory-projections
Draft

daniel-mader wants to merge 5 commits into
betafrom
feat/in-memory-projections

Conversation

@daniel-mader

Copy link
Copy Markdown
Contributor

Description of change

Instead of persisting all view updates (event projections) into the database, they are kept in-memory.
They are fully recreated on application startup through the persisted events.
This offers more flexibility, while certain views can still individually be persisted at a later time in an optimized database if needed.

Links to any relevant issues

Be sure to reference any related issues by adding fixes issue #.

How the change has been tested

Describe the tests that you ran to verify your changes.
Make sure to provide instructions for the maintainer as well as any relevant configurations.

Definition of Done checklist

Add an x to the boxes that are relevant to your changes.

  • I have followed the contribution guidelines for this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have successfully tested this change in a docker environment

@daniel-mader daniel-mader self-assigned this Sep 16, 2026
@daniel-mader
daniel-mader added this pull request to stack #405 September 16, 2026 14:30
@daniel-mader daniel-mader added the Enhancement New feature or improvement to an existing feature label Sep 16, 2026
@coderabbitai

coderabbitai Bot commented Sep 16, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codecov-commenter

codecov-commenter commented Sep 16, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 68.23529% with 351 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
agent_application/src/lib.rs 25.00% 96 Missing ⚠️
agent_store/src/mongodb.rs 0.00% 86 Missing ⚠️
agent_store/src/postgres.rs 0.00% 69 Missing ⚠️
agent_store/src/replay.rs 74.34% 49 Missing ⚠️
agent_store/src/custom_queries.rs 62.92% 33 Missing ⚠️
agent_api_http/src/projection_sizes.rs 97.95% 10 Missing ⚠️
agent_store/src/in_memory.rs 70.37% 8 Missing ⚠️
Files with missing lines Coverage Δ
agent_api_http/src/lib.rs 46.70% <ø> (ø)
agent_application/src/probes/readiness.rs 100.00% <100.00%> (ø)
agent_shared/src/lib.rs 51.61% <ø> (ø)
agent_store/src/event_verification.rs 79.84% <100.00%> (+0.47%) ⬆️
agent_store/src/lib.rs 87.17% <100.00%> (+0.44%) ⬆️
agent_store/src/in_memory.rs 83.87% <70.37%> (-16.13%) ⬇️
agent_api_http/src/projection_sizes.rs 97.95% <97.95%> (ø)
agent_store/src/custom_queries.rs 62.92% <62.92%> (ø)
agent_store/src/replay.rs 74.34% <74.34%> (ø)
agent_store/src/postgres.rs 0.00% <0.00%> (ø)
... and 2 more

... and 6 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@daniel-mader
daniel-mader force-pushed the feat/in-memory-projections branch from 813c383 to 74cbe9c Compare September 16, 2026 15:15
Base automatically changed from feat/list-ordering to beta September 16, 2026 15:42
@daniel-mader
daniel-mader force-pushed the feat/in-memory-projections branch from 1ea1de8 to ba2f9de Compare September 16, 2026 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Enhancement New feature or improvement to an existing feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants