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

Option to receive chunks in sorted order #2

Open
vcschapp opened this issue Sep 28, 2021 · 0 comments
Open

Option to receive chunks in sorted order #2

vcschapp opened this issue Sep 28, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@vcschapp
Copy link
Collaborator

vcschapp commented Sep 28, 2021

User Story

As an application writer, I would like to be able to receive all my query results sorted in ascending order of time.

Notes

  • A query writer can indicate sort @timestamp asc.
  • In multi-chunk queries, the chunks are started in time order.
  • However in multi-chunk queries, the completed chunks are sent to the stream in the order the completion occurs which may not be the time order.

Task List

  1. Add field to QuerySpec to request this, or perhaps request turning it off instead, and have it on by default.
  2. Add some kind of queuing system for completed chunks that are "early" and can't be sent to the stream because a predecessor chunk isn't finished yet.

Example

type QuerySpec struct {
        ...
        // Jumble indicates that results from completed chunks may be
        // sent to the stream as soon as they are finished even if the
        // results from an earlier chunk have not been sent yet.
        //
        // Setting Jumble to true may improve performance of
        // applications which don't need the results in time order, or
        // which need to post-process the results in any case.
        Jumble bool
        ...
}
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

No branches or pull requests

1 participant