#540 Kubernetes 관측성 개선 - #707
Conversation
6055e7b to
582d02c
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 87337442b0
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| ).only("judge_start_time", "judge_end_time") | ||
| for submission in submissions: | ||
| durations.append(max((submission.judge_end_time - submission.judge_start_time).total_seconds(), 0)) | ||
| metric.add_metric([], cache.llen(CELERY_BROKER_QUEUE_KEY) or 0) |
There was a problem hiding this comment.
Read the Celery queue from the broker DB
Under the current Redis settings, Django's default cache points at db 0 (redis_config() uses the default cache DB) while the Celery broker/result backend use db 4, so cache.llen("celery") is checking the wrong Redis database. In Redis/Sentinel deployments the new /metrics value will stay at zero or reflect an unrelated key, which means the Celery backlog dashboard/alert will not catch queued judge tasks; query the Celery broker connection/db instead.
Useful? React with 👍 / 👎.
Changelog
/metrics, JSON request log, request ID 처리를 추가했습니다.X-Request-ID전파를 추가했습니다.Testing
158 tests OKOps Impact
Version Compatibility