Skip to content

Download distributed query results if > 100#730

Merged
javuto merged 1 commit intomainfrom
pagination-query-results
Oct 13, 2025
Merged

Download distributed query results if > 100#730
javuto merged 1 commit intomainfrom
pagination-query-results

Conversation

@javuto
Copy link
Collaborator

@javuto javuto commented Oct 13, 2025

Implementation of #728 with a download link for on-demand query results if they are over a max number (100 entries). UI optimization must be enabled (OPTIMIZE_UI=true).

@javuto javuto requested a review from Copilot October 13, 2025 21:23
@javuto javuto added osctrl-admin osctrl-admin related changes queries On-demand queries related issues labels Oct 13, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Implements download functionality for distributed query results when they exceed 100 entries, optimizing UI performance by preventing large datasets from being displayed in tables. This feature is only available when UI optimization is enabled.

  • Adds conditional download link display for result sets > 100 entries
  • Implements new download endpoint for exporting full query logs as JSON
  • Enhances result display with table formatting for better readability

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
cmd/admin/templates/queries-logs.html Adds download link UI and improved table rendering for query results
cmd/admin/main.go Registers new download endpoint conditionally when UI optimization is enabled
cmd/admin/handlers/json-logs.go Implements download handler and adds download URL field to response structure
Comments suppressed due to low confidence (1)

cmd/admin/handlers/json-logs.go:1

  • The condition 'downloadUrl && downloadUrl !== ""' is redundant. Since downloadUrl is assigned from json.download with a fallback to empty string, checking just 'downloadUrl' would be sufficient.
package handlers

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@javuto javuto merged commit 8268a3d into main Oct 13, 2025
55 checks passed
@javuto javuto deleted the pagination-query-results branch October 13, 2025 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

osctrl-admin osctrl-admin related changes queries On-demand queries related issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants