-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[feat] Add overview APIs for Celery and Kafka in messaging queues integration #6756
[feat] Add overview APIs for Celery and Kafka in messaging queues integration #6756
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❌ Changes requested. Reviewed everything up to a4cb482 in 2 minutes and 43 seconds
More details
- Looked at
1258
lines of code in7
files - Skipped
0
files when reviewing. - Skipped posting
4
drafted comments based on config settings.
1. pkg/query-service/app/integrations/messagingQueues/kafka/model_test.go:160
- Draft comment:
ThewantKind
should be"worker"
instead of"active"
to match the expected behavior ofGetKind
.
wantKind: "worker",
- Reason this comment was not posted:
Marked as duplicate.
2. pkg/query-service/app/integrations/messagingQueues/kafka/model_test.go:183
- Draft comment:
TheGetKind
method should return"worker"
instead of"active"
to match the expected behavior.
assert.Equal(t, "worker", task.GetKind(), "GetKind should return kind")
- Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable:
Looking at the test cases and implementation: 1) The struct initializes kind="worker" and status="active" 2) The test expects GetKind() to return "active" 3) This seems inconsistent with field naming, as GetKind() should logically return the 'kind' field 4) However, without seeing the actual CeleryTask implementation, I can't be 100% certain this is wrong 5) The test is consistent with itself across both TestCeleryTask and TestCeleryTaskInterface.
Without seeing the actual implementation of CeleryTask and its GetKind() method, I can't be completely certain that returning status instead of kind is incorrect. The consistent test behavior suggests this might be intentional.
While the field naming suggests GetKind() should return the kind field, the consistent test behavior and lack of implementation visibility means we can't be confident enough to declare this as definitely wrong.
Without seeing the CeleryTask implementation, we can't be confident enough that this is actually a bug rather than intentional behavior.
3. pkg/query-service/app/integrations/messagingQueues/kafka/model.go:48
- Draft comment:
return r.kind
- Reason this comment was not posted:
Marked as duplicate.
4. pkg/query-service/app/integrations/messagingQueues/kafka/model.go:57
- Draft comment:
r.status = status
- Reason this comment was not posted:
Marked as duplicate.
Workflow ID: wflow_wONOujMOIb5z66UF
Want Ellipsis to fix these issues? Tag @ellipsis-dev
in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
pkg/query-service/app/integrations/messagingQueues/kafka/model.go
Outdated
Show resolved
Hide resolved
pkg/query-service/app/integrations/messagingQueues/kafka/model.go
Outdated
Show resolved
Hide resolved
60cad1a
to
6f9271f
Compare
pkg/query-service/app/integrations/messagingQueues/kafka/model.go
Outdated
Show resolved
Hide resolved
pkg/query-service/app/integrations/messagingQueues/kafka/sql.go
Outdated
Show resolved
Hide resolved
pkg/query-service/app/integrations/messagingQueues/kafka/sql.go
Outdated
Show resolved
Hide resolved
123996d
to
a91a30b
Compare
@srikanthccv I want to open up some more PRs, but those are making some slight changes on top of this, it would be a good idea to either get it merged, or I add code changes to this one (and make a big PR). let me know WDYT |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's a good idea to keep the base changes setup and their reasoning in this PR. In the next PRs, then I don't have to think about them again
pkg/query-service/app/integrations/messagingQueues/kafka/sql.go
Outdated
Show resolved
Hide resolved
pkg/query-service/app/integrations/messagingQueues/kafka/sql.go
Outdated
Show resolved
Hide resolved
Signed-off-by: Shivanshu Raj Shrivastava <[email protected]>
Signed-off-by: Shivanshu Raj Shrivastava <[email protected]>
Signed-off-by: Shivanshu Raj Shrivastava <[email protected]>
Signed-off-by: Shivanshu Raj Shrivastava <[email protected]>
a2d5495
to
50ac256
Compare
@srikanthccv addressed the other changes, apart from filter is there anything else? The filtering refactoring will be done via this post first merge #6768 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the custom parsing and query building means there could be number of issue with how they are done. I am not reviewing them since you want to address them later
Related to: https://github.com/SigNoz/engineering-pod/issues/2009
Fixes: #6755
Important
Add new API routes and SQL query generation for Celery and Kafka messaging queues, with corresponding tests.
/api/v1/messaging-queues/queue-overview
for general queue overview./api/v1/messaging-queues/celery
routes for Celery overview, tasks, and performance./api/v1/messaging-queues/kafka
.generateOverviewSQL()
insql.go
for queue overview queries.generateProducerConsumerEvalSQL()
insql.go
for producer-consumer evaluation.QueueFilters
andCeleryTask
structs inmodel.go
.sql_test.go
.model_test.go
.translator_test.go
.This description was created by for a4cb482. It will automatically update as commits are pushed.