Skip to content

lola: Preparation for moving TransactionLogLocalView#299

Draft
bemerybmw wants to merge 8 commits intomainfrom
brem_move_transaction_log_set_preparation
Draft

lola: Preparation for moving TransactionLogLocalView#299
bemerybmw wants to merge 8 commits intomainfrom
brem_move_transaction_log_set_preparation

Conversation

@bemerybmw
Copy link
Copy Markdown
Contributor

No description provided.

These Impl classes were previously added to avoid having to change
calling code to explicitly use the default template argument (i.e.
EventSubscriptionControl<>). Using the explicit template argument makes the code
more explicit and also removes the additional code complexity of having
the alias and Impl class.
We remove noexcept from all signatures to allow us to use precondition
violation tests instead of death tests. Precondition tests are orders of
magnitude faster than death tests due to not having to fork a process
and also don't have issues associated with RAII objects being destroyed
twice (i.e. in forked process and main process).
We now return a struct instead of a pair. This makes it easier to add
additional return types in future (we will soon return a reference to a
TransactionLogSet as well) and also makes it clearer on caller side as
they can access members using the names defined in the struct rather
than .first / .second.

We also return a reference to EventDataStorage instead of a pointer,
since it should always be created.
Updated documentation of functions and general clean up of functions.
We use ScopeExit so that we can rely only the more complicated testing
of move construction / move assignment from the ScopeExit class.
This change will be needed in an upcoming PR in which
TransactionLogSet::Register() creates a TransactionLogRegistrationGuard.
Both of thes files will need TransactionLogIndex so to avoid cyclic
dependencies we extract TransactionLogIndex into a separate file.
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