Skip to content

Conversation

@omkarK06
Copy link
Contributor

No description provided.

@omkarK06 omkarK06 changed the base branch from main to branch-v0.30.0 December 10, 2025 10:48
@github-actions github-actions bot added ☢️ Bug Something isn't working ✏️ Feature labels Dec 10, 2025
@github-actions
Copy link
Contributor

Failed to generate code suggestions for PR

@greptile-apps
Copy link
Contributor

greptile-apps bot commented Dec 10, 2025

Greptile Overview

Greptile Summary

This PR is a large omnibus change that bundles several distinct features and fixes:

  • Span Time Attributes: Added startTimeUs and endTimeUs attributes to trace span data for microsecond precision timing
  • Organization Invitation System: Major enhancements including invitation revocation, preventing users from joining multiple free orgs, email domain validation, and a new dedicated invitations page/tab
  • Memory Optimization: Added StringViewArray garbage collection in Flight encoder to reduce memory usage (addresses issue preformance issue for retemoscan/aggregation/flight #8280)
  • DataFusion Config: Disabled TopK aggregation optimization due to upstream issue #19219
  • Pipeline Conditions: Fixed state mutation bugs, added custom column support, and allowed deletion of all conditions including the first one
  • Search Highlighting: Moved highlight query calculation to search execution time for better consistency
  • Authentication: Added special handling for license API to prevent logout loops, and improved 403 error handling

Key Issues Found:

  • Bug in TraceDetails.vue: endTimeUs incorrectly uses span.start_time instead of span.end_time

Confidence Score: 3/5

  • PR contains one definite bug that needs fixing before merge, but otherwise well-implemented changes.
  • Score of 3 reflects that while most changes are well-implemented, there is one clear bug where endTimeUs uses span.start_time instead of span.end_time. This will cause incorrect end time calculations for spans. The rest of the changes appear solid with proper deep copies for state management, good error handling, and appropriate feature gating.
  • web/src/plugins/traces/TraceDetails.vue has a bug where endTimeUs uses the wrong time field.

Important Files Changed

File Analysis

Filename Score Overview
web/src/plugins/traces/TraceDetails.vue 2/5 Added startTimeUs and endTimeUs attributes for span data. Bug: endTimeUs uses span.start_time instead of span.end_time.
src/flight/src/encoder.rs 5/5 Added StringViewArray garbage collection to reduce memory usage. Implementation follows DataFusion's approach for efficient memory management.
src/service/organization.rs 4/5 Added validation to prevent users from joining multiple free organizations, email domain checking, and returning remaining invites on decline.
src/handler/http/auth/validator.rs 4/5 Added special handling for license API path to prevent logout loops for native users not yet in an organization.
web/src/views/Login.vue 4/5 Changed to fetch pending invitations from API instead of callback hash. Added 403 error handling to trigger signout.
web/src/components/iam/users/User.vue 5/5 Added invitation revoke functionality with confirmation dialog and refresh after invite sent.
web/src/components/pipeline/NodeForm/Condition.vue 5/5 Added deep copy for condition groups to prevent mutation, custom column support, and proper state restoration on cancel.
web/src/composables/useLogs.ts 5/5 Fixed column reordering to return new array instead of mutating, and skip reordering when colOrder is empty to fix Firefox sort instability.

Sequence Diagram

sequenceDiagram
    participant User
    participant Login as Login.vue
    participant API as Backend API
    participant InviteList as InvitationList.vue
    participant OrgService as Organization Service
    
    User->>Login: Login
    Login->>API: getPendingInvites()
    API-->>Login: invitations[]
    
    alt Has Pending Invites
        Login->>InviteList: Show invitations
        User->>InviteList: Accept/Decline invitation
        
        alt Accept
            InviteList->>API: acceptInvitation(token)
            API->>OrgService: Validate free org constraints
            OrgService-->>API: Success/Error
            API-->>InviteList: Result
        else Decline
            InviteList->>API: declineInvitation(token)
            API->>OrgService: Check remaining invites
            alt No remaining invites
                OrgService->>OrgService: Auto-create org for user
            end
            API-->>InviteList: remaining count
        end
    else No Invites
        Login->>User: Redirect to dashboard
    end
Loading

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

52 files reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

@omkarK06 omkarK06 force-pushed the fix/traces-span-bars-position-calc-issue-v0.30.0 branch from cd2754a to 59389dc Compare December 10, 2025 11:04
@omkarK06 omkarK06 merged commit 8730b0b into branch-v0.30.0 Dec 10, 2025
34 checks passed
@omkarK06 omkarK06 deleted the fix/traces-span-bars-position-calc-issue-v0.30.0 branch December 10, 2025 11:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

☢️ Bug Something isn't working ✏️ Feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants