Optimize event and stack paging totals#2316
Draft
ejsmith wants to merge 4 commits into
Draft
Conversation
Member
Author
|
/preview |
|
Preview deployed
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
include=totalquery option to event list endpoints so cursor paging can opt into total metadata only when needed.sum_other_doc_countwith an optionalstack_idcardinality aggregation, and preserves known table page counts when later offset responses omit totals.8.0.0-beta2without using PIT.Root Cause
Event paging was asking Elasticsearch for exact totals on every before/after request and still returning
X-Result-Counton cursor hops. Stack paging was also deriving a stack total from terms aggregation spillover document counts, which is not a stable distinct stack count.Validation
dotnet restore src/Exceptionless.Web/Exceptionless.Web.csprojdotnet build src/Exceptionless.Web/Exceptionless.Web.csproj -p:UseSharedCompilation=false -p:BuildInParallel=false --no-restoredotnet build tests/Exceptionless.Tests/Exceptionless.Tests.csproj -p:UseSharedCompilation=false -p:BuildInParallel=false --no-restoreUPDATE_SNAPSHOTS=true dotnet test tests/Exceptionless.Tests/Exceptionless.Tests.csproj -- --filter-class Exceptionless.Tests.Controllers.OpenApiControllerTestsdotnet test tests/Exceptionless.Tests/Exceptionless.Tests.csproj -- --filter-class Exceptionless.Tests.Controllers.OpenApiControllerTestsnpm run checknpm run test:unit -- src/lib/features/shared/table.test.tsgit diff --checkUPDATE_SNAPSHOTS=true dotnet test tests/Exceptionless.Tests/Exceptionless.Tests.csproj -- --filter-class Exceptionless.Tests.Controllers.OpenApiControllerTestsdotnet test tests/Exceptionless.Tests/Exceptionless.Tests.csproj -- --filter-class Exceptionless.Tests.Controllers.OpenApiControllerTestsdotnet build src/Exceptionless.Web/Exceptionless.Web.csproj -p:UseSharedCompilation=false -p:BuildInParallel=false --no-restorenpm run checkNotes
includedoes not include total metadata; clients must passinclude=totalwhen they needX-Result-Count.