Skip to content

Conversation

@edmocosta
Copy link
Collaborator

Added the configuration execution time (milliseconds) on the result panel header, so users can compare their approximate execution time and roughly compare their efficiency.

Screenshot 2025-05-08 at 00 14 40

@edmocosta edmocosta closed this May 7, 2025
@edmocosta edmocosta reopened this May 7, 2025
@edmocosta edmocosta requested a review from Copilot May 7, 2025 22:42
Copy link

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

This PR adds an approximate execution time display to the result panel header so that users can compare execution efficiency alongside the results.

  • Updated state initialization style in playground.js.
  • Added new CSS and HTML markup in the result panel for displaying execution time.
  • Extended error and execution result tests in ottlplayground_test.go and updated the execution result flow in ottlplayground.go.

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
web/src/components/playground.js Improved code style with consistent semicolon and arrow function usage.
web/src/components/panels/result-panel.styles.js Added a new style block for the execution time header.
web/src/components/panels/result-panel.js Inserted UI component for showing execution time in the header.
wasm/internal/ottlplayground_test.go Updated tests to validate the inclusion and value of executionTime.
wasm/internal/ottlplayground.go Modified functions to propagate the executionTime measurement.

@edmocosta edmocosta requested a review from Copilot May 7, 2025 22:45

This comment was marked as duplicate.

@edmocosta edmocosta force-pushed the add-execution-time-header branch from 02b7580 to 20973a0 Compare May 7, 2025 22:48
@edmocosta edmocosta merged commit 26141aa into main May 7, 2025
2 checks passed
@edmocosta edmocosta deleted the add-execution-time-header branch May 7, 2025 22:51
@edmocosta
Copy link
Collaborator Author

Thank you for the suggestion, @jaronoff97 :)
Although it's not precise compared to running it within the Collector, we can still use it to help improving the statements performance, for example, running this statement using a non-optimal OTTL context vs running the same statement using the most specific context.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants