Skip to content

feat(flow): add eval interval option #6623

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

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

discord9
Copy link
Contributor

I hereby agree to the terms of the GreptimeDB CLA.

Refer to a related PR or issue link (optional)

What's changed and what's your intention?

add eval interval option, and add check that tql flow must have this option

PR Checklist

Please convert it to a draft if some of the following conditions are not met.

  • I have written the necessary rustdoc comments.
  • I have added the necessary unit tests and integration tests.
  • This PR requires documentation updates.
  • API changes are backward compatible.
  • Schema or data changes are backward compatible.

@discord9 discord9 marked this pull request as ready for review July 31, 2025 09:31
@github-actions github-actions bot added size/M docs-not-required This change does not impact docs. labels Jul 31, 2025
discord9 added 2 commits July 31, 2025 17:33
Signed-off-by: discord9 <[email protected]>
Signed-off-by: discord9 <[email protected]>
Comment on lines +94 to 95
CREATE FLOW calc_reqs SINK TO cnt_reqs EVAL INTERVAL '1m' AS
TQL EVAL (0, 15, '5s') count_values("status_code", http_requests);
Copy link
Member

Choose a reason for hiding this comment

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

About the grammar:

  • we should check and warn/reject the absolute start/end (not express with now())
  • I don't prefer to add a new grammar section for this, and
  • it's only for batching mode
  • How about using step as the interval?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

About the grammar:

* we should check and warn/reject the absolute start/end (not express with `now()`)

* I don't prefer to add a new grammar section for this, and

* it's only for batching mode

* How about using `step` as the interval?

step still sound too frequency, how about using end - start?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs-not-required This change does not impact docs. size/M
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants