Skip to content

feat(taskprocessing): Add queue_stats API endpoint for external autoscalers#58376

Merged
oleksandr-nc merged 1 commit intomasterfrom
feat/taskprocessing/keda-autoscaler
Mar 30, 2026
Merged

feat(taskprocessing): Add queue_stats API endpoint for external autoscalers#58376
oleksandr-nc merged 1 commit intomasterfrom
feat/taskprocessing/keda-autoscaler

Conversation

@oleksandr-nc
Copy link
Copy Markdown
Contributor

@oleksandr-nc oleksandr-nc commented Feb 17, 2026

Summary

This is a new admin-only OCS endpoint (GET /taskprocessing/queue_stats) that returns the count of scheduled and running tasks, designed for KEDA and similar external scalers to poll for queue depth.

TODO

  • Finish design
  • Test with LLM2 and ContextChat
  • Fix bugs

Checklist

@oleksandr-nc oleksandr-nc added the 2. developing Work in progress label Feb 23, 2026
@oleksandr-nc oleksandr-nc force-pushed the feat/taskprocessing/keda-autoscaler branch from eed2cdd to e099331 Compare February 23, 2026 16:38
@marcelklehr
Copy link
Copy Markdown
Member

Not sure how useful unit tests are in this case 🤔 We can keep them, but if we want proper test coverage, I'd argue we should test against a real db as well.

@oleksandr-nc oleksandr-nc force-pushed the feat/taskprocessing/keda-autoscaler branch 2 times, most recently from 08e97d5 to 6d42d50 Compare March 23, 2026 10:19
@oleksandr-nc oleksandr-nc marked this pull request as ready for review March 23, 2026 10:47
@oleksandr-nc oleksandr-nc requested review from a team and provokateurin as code owners March 23, 2026 10:47
@oleksandr-nc oleksandr-nc requested review from Altahrim, ArtificialOwl and icewind1991 and removed request for a team March 23, 2026 10:47
Copy link
Copy Markdown
Member

@provokateurin provokateurin left a comment

Choose a reason for hiding this comment

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

LGTM

@oleksandr-nc oleksandr-nc force-pushed the feat/taskprocessing/keda-autoscaler branch from 6d42d50 to 0d6bc54 Compare March 30, 2026 08:57
@oleksandr-nc
Copy link
Copy Markdown
Contributor Author

@provokateurin, thank you very much for the review - I have fixed everything you pointed out!

…calers

Signed-off-by: Oleksander Piskun <oleksandr2088@icloud.com>
@oleksandr-nc oleksandr-nc force-pushed the feat/taskprocessing/keda-autoscaler branch from 0d6bc54 to f573285 Compare March 30, 2026 12:04
@oleksandr-nc oleksandr-nc merged commit 5ce08e9 into master Mar 30, 2026
199 of 206 checks passed
@oleksandr-nc oleksandr-nc deleted the feat/taskprocessing/keda-autoscaler branch March 30, 2026 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

2. developing Work in progress

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants