Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

execute archive logic only once #460

Merged
merged 1 commit into from
Jan 9, 2024
Merged

Conversation

DavidBadura
Copy link
Member

@DavidBadura DavidBadura commented Jan 9, 2024

Previously, the archiving logic was always executed when a SplitStream event was detected. If there were n of them when saving, the logic was executed n times. This is very pointless as the logic archives all events in the past. Through optimization, the logic is only executed once, for the last event.

@DavidBadura DavidBadura added this to the 3.0.0 milestone Jan 9, 2024
@DavidBadura DavidBadura added the enhancement New feature or request label Jan 9, 2024
Copy link

github-actions bot commented Jan 9, 2024

Hello 👋

here is the most recent benchmark result:

SimpleSetupBench
================

+----------------------------------------+--------------------+--------------------+-----------------+------------+
|                                        | time (kde mode)                         | memory                       |
+----------------------------------------+--------------------+--------------------+-----------------+------------+
| subject                                | Tag: <current>     | Tag: base          | Tag: <current>  | Tag: base  |
+----------------------------------------+--------------------+--------------------+-----------------+------------+
| benchLoad10000Events ()                | 120.870ms (±0.00%) | 122.764ms (±0.00%) | 32.597mb        | 32.597mb   |
| benchSave1Event ()                     | 1.093ms (±0.00%)   | 1.601ms (±0.00%)   | 32.597mb        | 32.597mb   |
| benchSave10000Events ()                | 279.743ms (±0.00%) | 296.544ms (±0.00%) | 32.821mb        | 32.820mb   |
| benchSave10000Aggregates ()            | 11.669s (±0.00%)   | 12.993s (±0.00%)   | 32.597mb        | 32.597mb   |
| benchSave10000AggregatesTransaction () | 749.152ms (±0.00%) | 738.579ms (±0.00%) | 32.597mb        | 32.597mb   |
+----------------------------------------+--------------------+--------------------+-----------------+------------+

SplitStreamBench
================

+-------------------------+--------------------+--------------------+-----------------+------------+
|                         | time (kde mode)                         | memory                       |
+-------------------------+--------------------+--------------------+-----------------+------------+
| subject                 | Tag: <current>     | Tag: base          | Tag: <current>  | Tag: base  |
+-------------------------+--------------------+--------------------+-----------------+------------+
| benchLoad10000Events () | 2.294ms (±0.00%)   | 2.304ms (±0.00%)   | 35.981mb        | 35.981mb   |
| benchSave10000Events () | 312.389ms (±0.00%) | 358.831ms (±0.00%) | 36.246mb        | 36.246mb   |
+-------------------------+--------------------+--------------------+-----------------+------------+

SyncProjectionistBench
======================

+-------------------------+--------------------+--------------------+-----------------+------------+
|                         | time (kde mode)                         | memory                       |
+-------------------------+--------------------+--------------------+-----------------+------------+
| subject                 | Tag: <current>     | Tag: base          | Tag: <current>  | Tag: base  |
+-------------------------+--------------------+--------------------+-----------------+------------+
| benchSave1Event ()      | 1.438ms (±0.00%)   | 1.684ms (±0.00%)   | 8.094mb         | 8.093mb    |
| benchSave10000Events () | 450.408ms (±0.00%) | 448.811ms (±0.00%) | 33.425mb        | 33.424mb   |
+-------------------------+--------------------+--------------------+-----------------+------------+

SnapshotsBench
==============

+----------------------------------------+--------------------+--------------------+-----------------+------------+
|                                        | time (kde mode)                         | memory                       |
+----------------------------------------+--------------------+--------------------+-----------------+------------+
| subject                                | Tag: <current>     | Tag: base          | Tag: <current>  | Tag: base  |
+----------------------------------------+--------------------+--------------------+-----------------+------------+
| benchLoad10000EventsMissingSnapshot () | 121.850ms (±0.00%) | 122.850ms (±0.00%) | 32.618mb        | 32.618mb   |
| benchLoad10000Events ()                | 196.300μs (±0.00%) | 199.650μs (±0.00%) | 32.618mb        | 32.618mb   |
+----------------------------------------+--------------------+--------------------+-----------------+------------+

This comment gets update everytime a new commit comes in!

@DavidBadura DavidBadura merged commit b35940e into 3.0.x Jan 9, 2024
31 of 33 checks passed
@DavidBadura DavidBadura deleted the optimaize-archive-logic branch January 9, 2024 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants