Skip to content

[raft/memstore] Add scd memstore#1542

Open
the-glu wants to merge 9 commits into
interuss:masterfrom
Orbitalize:memstore_scd
Open

[raft/memstore] Add scd memstore#1542
the-glu wants to merge 9 commits into
interuss:masterfrom
Orbitalize:memstore_scd

Conversation

@the-glu

@the-glu the-glu commented Jun 17, 2026

Copy link
Copy Markdown
Member

This PR is part of a new chain, implementing memstore.

#1525 (Generic raftstore) -> #1527 (Base memstore) -> #1529 (Aux memstore) -> #1530 (Snapshots) -> #1534 (Rid memstore) -> #1535 (Correct use of now) -> #1539 (Checkpoint) -> #1542 (Scd memstore) -> #1528 (First PR with raft using memstore)


It does add SCD memstore.

PR is quite big, as it's the whole SCD memstore. However individual files can be checked individually.

There was no tests compared to RID, except for expired operational intents / subscriptions. The two ones have been copied, the rest is new.

return nil, stacktrace.NewErrorWithCode(dsserr.NotImplemented, "GetUssAvailability not implemented for memstore")
rec, ok := r.state.Availabilities[id]
if !ok {
return nil, pgx.ErrNoRows

@MariemBaccari MariemBaccari Jun 17, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why do we return pgx.ErrNoRows instead of empty or a custom error and add this check in the handler ? Having pgx leak in the memstore feels odd.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

That was to avoid changes in callers, since they use that to detect no row, but that should be improved yes. I propose to do that in a follow up PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dss-raft Relating to the application-layer consensus implemenation based on raft

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants