Skip to content

feat: add initial state module#49

Draft
yordis wants to merge 1 commit intomainfrom
split-aggregate-and-payload-mod
Draft

feat: add initial state module#49
yordis wants to merge 1 commit intomainfrom
split-aggregate-and-payload-mod

Conversation

@yordis
Copy link
Member

@yordis yordis commented Jan 23, 2026

No description provided.

@cursor
Copy link

cursor bot commented Jan 23, 2026

PR Summary

Medium Risk
Touches aggregate initialization and aggregate_state rebuilding paths; while largely additive and covered by tests, mistakes could change how state is constructed or surfaced across existing aggregates.

Overview
Adds an initial_state option to dispatch routes so aggregates can be initialized from a separate state module (via initial_state/0) instead of requiring struct(AggregateModule).

Plumbs this option through command dispatch (Dispatcher -> Aggregates.Supervisor -> AggregateStateBuilder) and extends aggregate_state/3 APIs to accept either a timeout or options (including initial_state) when rebuilding from the event store. Updates docs/guide and adds new tests + support fixtures covering separate state modules and backward compatibility.

Written by Cursor Bugbot for commit 8a8754d. This will update automatically on new commits. Configure here.

@coderabbitai
Copy link

coderabbitai bot commented Jan 23, 2026

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

  • 🔍 Trigger a full review
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch split-aggregate-and-payload-mod

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 and usage tips.

@yordis yordis force-pushed the split-aggregate-and-payload-mod branch 2 times, most recently from 225442e to 3c5fe1a Compare February 4, 2026 04:13
@yordis yordis changed the title feat: add state module feat: add initial state module Feb 4, 2026
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

@yordis yordis force-pushed the split-aggregate-and-payload-mod branch 5 times, most recently from 8a8754d to 37b9a69 Compare February 4, 2026 05:37
Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
@yordis yordis force-pushed the split-aggregate-and-payload-mod branch from 37b9a69 to c91cfd8 Compare February 4, 2026 06:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant