Skip to content
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: added span_count using the MV and index v3 traces table [Design needs to be finalised] #6674

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

eKuG
Copy link
Contributor

@eKuG eKuG commented Dec 19, 2024

Summary

Related Issues / PR's

Screenshots

NA

Affected Areas and Manually Tested Areas


Important

Added support for sorting trace queries by span count using a new sortBy parameter in query functions.

  • Behavior:
    • Added sortBy parameter to prepareTracesQueryFunc in query_builder.go to support sorting by span count.
    • Updated PrepareTracesQuery in query_builder.go, v3/query_builder.go, and v4/query_builder.go to handle sortBy parameter.
    • Introduced TraceSortBySpanCount and TraceSortByTraceDuration constants in constants.go.
  • Query Building:
    • Modified buildTracesQuery in v3/query_builder.go and v4/query_builder.go to include logic for sorting by span count using TraceExplorerSpanCountSubQuery.
    • Adjusted query logic to use SIGNOZ_TRACE_SPAN_COUNT_MV for span count sorting.
  • Models:
    • Added SortBy field to QueryRangeParamsV3 in v3.go.

This description was created by Ellipsis for cdeb0af. It will automatically update as commits are pushed.

@github-actions github-actions bot added docs required enhancement New feature or request labels Dec 19, 2024
Copy link

Build Error! No Linked Issue found. Please link an issue or mention it in the body using #<issue_id>

@eKuG eKuG changed the title feat: added span_count using the MV and index v3 traces table feat: added span_count using the MV and index v3 traces table [Design needs to be finalised] Dec 19, 2024
Copy link

Build Error! No Linked Issue found. Please link an issue or mention it in the body using #<issue_id>

1 similar comment
Copy link

Build Error! No Linked Issue found. Please link an issue or mention it in the body using #<issue_id>

Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Reviewed everything up to cdeb0af in 1 minute and 39 seconds

More details
  • Looked at 171 lines of code in 5 files
  • Skipped 0 files when reviewing.
  • Skipped posting 3 drafted comments based on config settings.
1. pkg/query-service/app/traces/v3/query_builder.go:502
  • Draft comment:
    The sortBy parameter is added to the PrepareTracesQuery function signature but is not used within the function. Ensure that sortBy is utilized appropriately to affect the query as intended.
  • Reason this comment was not posted:
    Comment did not seem useful.
2. pkg/query-service/app/traces/v4/query_builder.go:387
  • Draft comment:
    The sortBy parameter is added to the PrepareTracesQuery function signature but is not used within the function. Ensure that sortBy is utilized appropriately to affect the query as intended.
  • Reason this comment was not posted:
    Marked as duplicate.
3. pkg/query-service/app/queryBuilder/query_builder.go:41
  • Draft comment:
    Avoid using the component/index.tsx file structure approach, as it makes it difficult to debug and find components using global search tools like VS Code.
  • Reason this comment was not posted:
    Comment was on unchanged code.

Workflow ID: wflow_8s3jLjJQ0k5Q6y9K


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs required enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant