8000 feat: queued metrics, along with bug fixes for round robin queueing by abelanger5 · Pull Request #340 · hatchet-dev/hatchet · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat: queued metrics, along with bug fixes for round robin queueing #340

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

Merged
merged 1 commit into from
Apr 4, 2024

Conversation

abelanger5
Copy link
Contributor

Description

Adds an endpoint for getting queued metrics for concurrency groups.

Also fixes an ordering issue in the round robin queueing strategy where the queue was returned with an incorrect ordering (see comments in PR review).

Also adds better visualization for queued runs in the events view.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

@abelanger5 abelanger5 requested a review from grutt April 4, 2024 20:00
Copy link
vercel bot commented Apr 4, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
hatchet-docs ✅ Ready (Inspect) Visit Preview Apr 4, 2024 8:00pm

r2."status" = 'QUEUED' AND
workflowVersion."id" = $2
r2."tenantId" = @tenantId::uuid AND
(r2."status" = 'QUEUED' OR r2."status" = 'RUNNING') AND
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We are filling all available slots with a QUEUED or RUNNING status. We are obviously not going to pop the running status, but we want to figure out how many slots we have and only return queued runs in those slots.

grutt
countRunsParams.GroupKey = sqlchelpers.TextFromStr(*opts.GroupKey)
}

runsCount, err := r.queries.CountWorkflowRunsRoundRobin(context.Background(), r.pool, countRunsParams)
Copy link
Contributor

Choose a reason for hiding this comment

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

do we need to update this for future strategies?

@abelanger5 abelanger5 merged commit 334ce75 into main Apr 4, 2024
@abelanger5 abelanger5 deleted the belanger/queued-metrics branch April 4, 2024 21:45
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.

2 participants
0