Commit Graph

20 Commits

Author SHA1 Message Date
Diljit
d3f1788dfb
chore: filter smartlook urls from tracing assets in page load instrumentation (#35738)
## Description
Filter smartlook urls from page load instrumentation. These api calls
need not be tracked to measure page load performance.

Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10446808927>
> Commit: c81e741f9dcb071f0961903e806e60260a744677
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10446808927&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Mon, 19 Aug 2024 04:16:17 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No
2024-08-19 11:39:39 +05:30
Diljit
ed17ee0376
chore: ce - remove sentry performance tracker (#35710)
## Description
Fix the following errors

### POST https://o296332.ingest.sentry.io/api/1546547/envelope/... 429
(Too Many Requests)

We have an integration with Sentry to instrument page loads and other
transactions. This is no longer used. All page load metrics are
collected using a new relic integration.
The sentry transactions api was throwing a 429 error when we exceed our
trial quota. Removing the integration should curb this error.

<img width="1181" alt="Screenshot 2024-08-15 at 1 22 28 PM"
src="https://github.com/user-attachments/assets/543c0ec1-e87f-4439-b715-e75b3a6fd3ed">

[Slack thread
](https://theappsmith.slack.com/archives/CGBPVEJ5C/p1723699775838509)for
more context on our sentry sub exceeding its quota.

### TypeError: e.className.split is not a function at t.value
(PageLoadInstrumentation.ts:112:33)

Add a type check for string.


Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.All"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10400625143>
> Commit: fc83198b613a973c9a02644fc742947a92bfbd3c
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10400625143&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.All`
> Spec:
> <hr>Thu, 15 Aug 2024 08:45:49 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Removed performance tracking functionality across various components
and sagas, simplifying the codebase and reducing overhead.
- **Bug Fixes**
- No specific bug fixes were made; improvements focus on performance
tracking removal.
- **Chores**
- Eliminated unnecessary dependencies related to performance metrics,
streamlining the application's dependency management.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-08-15 19:40:53 +05:30
Valera Melnikov
c42e0317de
fix: change appsmith alias (#35349)
In order to unify package names, we decided to use `@appsmith` prefix as
a marker to indicate that packages belong to our codebase and that these
packages are developed internally. So that we can use this prefix, we
need to rename the alias of the same name. But since `@appsmith` is
currently being used as an alias for `ee` folder, we have to rename the
alias as the first step.

Related discussion
https://theappsmith.slack.com/archives/CPG2ZTXEY/p1722516279126329

EE PR — https://github.com/appsmithorg/appsmith-ee/pull/4801

## Automation

/ok-to-test tags="@tag.All"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10267368821>
> Commit: 2b00af2d257e4d4304db0a80072afef7513de6be
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10267368821&attempt=2"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.All`
> Spec:
> <hr>Tue, 06 Aug 2024 14:24:22 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No
2024-08-06 17:52:22 +03:00
Diljit
7adb33d015
chore: Add hostname as common attr on all spans (#35388)
## Description
Some of the self hosted instances are sending data with the entitiy.name
as Appsmith Production OTLP. Therefore we need another attribute to
slice all the cloud data and hostname will be unique to each instance.

Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!IMPORTANT]
> 🟣 🟣 🟣 Your tests are running.
> Tests running at:
<https://github.com/appsmithorg/appsmith/actions/runs/10234910845>
> Commit: b616a08165d404f8d4fc4a5cc8d467ce4a7476a6
> Workflow: `PR Automation test suite`
> Tags: `@tag.Sanity`
> Spec: ``
> <hr>Sun, 04 Aug 2024 08:47:52 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Enhanced telemetry data by adding a new `hostname` property, improving
tracking and analysis of telemetry events based on the specific web page
host.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-08-04 14:52:54 +05:30
Valera Melnikov
a2bfe450b6
chore: enable no-explicit-any rule (#35321)
## Description
-  Enabled the rule `@typescript-eslint/no-explicit-any`
- Suppressed errors with comment
```
// TODO: Fix this the next time the file is edited
// eslint-disable-next-line @typescript-eslint/no-explicit-any
```

Fixes #35308 

## Automation

/ok-to-test tags="@tag.All"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10181176984>
> Commit: 7fc604e24fa234da7ab2ff56e0b1c715268796ee
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10181176984&attempt=2"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.All`
> Spec:
> <hr>Wed, 31 Jul 2024 15:00:45 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No
2024-07-31 18:41:28 +03:00
Diljit
e4fc6d2a46
chore: Add page load trace with resource, paint and navigation spans (#34957) 2024-07-30 08:47:21 +05:30
Vemparala Surya Vamsi
d065a82817
chore: tiny fix to reduce getCommonTelemetryAttributes overhead (#35247)
## Description
Tiny fix to reduce getCommonTelemetryAttributes overhead, memoising the
appMode computation in this PR.


> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.All"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10140023081>
> Commit: bba9da0812aea4a07e7646b2e7245799c70f9318
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10140023081&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.All`
> Spec:
> <hr>Mon, 29 Jul 2024 08:26:36 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Introduced a memoized function for computing application mode,
enhancing performance by reducing unnecessary recalculations.

- **Improvements**
- Enhanced efficiency in telemetry attribute generation by optimizing
the application mode determination process.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-07-29 14:09:59 +05:30
Vemparala Surya Vamsi
492fb353d7
chore: adding addition telemetry to cover JSONForm widget's performance (#35229)
## Description
We need to profile a few functions in JSON forms, observed that in some
customer's apps the following functions
- clearErrors
- parseAndSaveFieldState
takes as much 10% in main thread scripting. We are adding setError just
to check if this function is performant or not as well.


Fixes #35228 

> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10114403810>
> Commit: 90f5c31b2fc05e225cb827ec680c4bd68dc1e95f
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10114403810&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Fri, 26 Jul 2024 16:46:46 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Introduced telemetry tracking around function executions to improve
observability and performance monitoring.
- Enhanced error-clearing logic in the form widget to include telemetry
tracing for better analysis.

- **Improvements**
- Added performance tracking to the `parseAndSaveFieldState` method in
the JSONFormWidget for optimized performance insights.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-07-29 09:57:54 +05:30
Vemparala Surya Vamsi
4bf6671cc4
chore: Added profiling for widget components performance (#34912)
## Description
Capturing telemetry of widget renders and only enabling the profiled
build for community users. This should cause a minor performance
overhead and in case performance degrades too much we can disable the
widget profiled telemetry by disabling the new relic flag(set this to
false `APPSMITH_NEW_RELIC_ACCOUNT_ENABLE`).

Fixes #35184  

> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10111247316>
> Commit: 38310d7341e7a2acb30491e478edaedbbc16a739
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10111247316&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Fri, 26 Jul 2024 12:55:43 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

## Summary by CodeRabbit

- **New Features**
- Introduced `WidgetProfiler` component to track rendering performance
metrics.
  - Added a new function for enhanced telemetry span management.
  
- **Improvements**
- Updated build script to allow for profiled builds based on environment
variables, improving performance analysis.
- Implemented GZIP compression for OTLP trace data transmission,
optimizing bandwidth usage.

- **Refactor**
- Removed `Sentry.withProfiler` for widget profiling, simplifying
performance monitoring.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-07-26 21:12:31 +05:30
Diljit
4839110362
chore: Register OTLP metrics provider (#35112)
## Description
> [!TIP]  
> _Add a TL;DR when the description is longer than 500 words or
extremely technical (helps the content, marketing, and DevRel team)._
>
> _Please also include relevant motivation and context. List any
dependencies that are required for this change. Add links to Notion,
Figma or any other documents that might be relevant to the PR._


Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/10070546330>
> Commit: e7ee6fafb05b7147590f864b6361a49b293f7237
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10070546330&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Wed, 24 Jul 2024 04:58:18 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Enhanced telemetry management with the integration of OpenTelemetry
metrics for real-time performance monitoring.
- New capabilities for exporting application metrics alongside existing
tracing functionality.

- **Bug Fixes**
- Improved clarity and maintainability of resource attributes and
variable naming conventions in telemetry management.

- **Chores**
- Updated dependency versions for OpenTelemetry packages, ensuring
enhanced observability and performance tracking capabilities.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-07-25 10:14:36 +05:30
Diljit
6f856b5ab5
chore: Add newrelic tracking spans to AppViewer engine and AppEditor engine (#34716)
## Description
Add new relic tracking spans to all fn calls in Appviewer and AppEditor
engine.


Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/9868467158>
> Commit: 9267930a1501b1a6eaab985c714c04a4f2a5da52
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9868467158&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Wed, 10 Jul 2024 05:32:52 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Enhanced app performance tracking with added telemetry spans for key
functions.

- **Tests**
- Updated test cases to include telemetry span tracking, ensuring better
performance monitoring and validation.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-07-11 15:37:25 +05:30
Rishabh Rathod
cb3ddf1cb3
chore: Add evalTreeWithDiff to evalWorkerAction (#34403)
## Description

These changes add evalTreeWithDiff to evalWorkerAction. Using this
method it will be possible to send the unevalTree and configTree updates
from mainThread to trigger evaluation.
- This will skip diffing complete unEvaltree

### Next steps after this PR
- [ ] Rename EvalTreeWithChanges to evalTreeWithDiff
- [ ] Generate Diff instead of updatedValuePaths for the current
evalTreeWithChanges references.
- [ ] Handle evalTreeWithDiff for
	- [ ] JSObject updates 
	- [ ] updateDependencyMap

Fixes #

## Automation

/test js

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/9684706533>
> Commit: 3de988af5da9900f4e589a008d28296d05d17f25
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9684706533&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.JS`

<!-- end of auto-generated comment: Cypress test results  -->


















## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Enhanced widget evaluation logic and improved handling of dynamic
bindings and dependencies.

- **Bug Fixes**
- Corrected type handling in various evaluation functions to improve
stability and accuracy.

- **Tests**
- Updated test cases for widget property setters to include additional
tags for better categorization.

- **Refactor**
- Streamlined function signatures and improved type safety across
evaluation utilities.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-06-27 12:08:53 +05:30
Rajat Agrawal
cf18829c7d
chore: add first load telemetry to evaluations (#33989)
## Description
This PR adds an attribute to evaluations span that tells whether the
evaluation is first evaluation on page load or a subsequent one.

This attribute will help us filter evaluations and measure gains in
update evaluations and first page load evaluations separately.


Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/9381739425>
> Commit: 4cdd01dc24c70aa29b908420e60c984d20b2494d
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9381739425&attempt=1"
target="_blank">Click here!</a>

<!-- end of auto-generated comment: Cypress test results  -->




## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **Bug Fixes**
- Added a conditional check before calling `endSpan` to handle
`parentSpan` in action execution.

- **Refactor**
- Updated types and interfaces related to telemetry data handling to
enhance type safety and clarity.
- Adjusted telemetry data processing to accommodate new
`SpanAttributes`.

- **New Features**
- Introduced filtering for telemetry span data to exclude specific
entries, improving data management.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-06-07 18:38:42 +05:30
Diljit
d880168472
chore: Add deviceType and appMode to new relic telemetry data (#33735)
## Description
Add deviceType and appMode attributes to new relic spans related to
evaluation


Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/9297145435>
> Commit: 309d8ae5904c55be9e918b7a119cd184b15cce86
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9297145435&attempt=1"
target="_blank">Click here!</a>

<!-- end of auto-generated comment: Cypress test results  -->

























## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No
2024-05-31 09:25:01 +05:30
Vemparala Surya Vamsi
a066211ef8
chore: push webworker latencies as a root span (#33115)
## Description
We are capturing the complete webworker latency as a separate root span
and pushing this OTLP telemetry data. We are also attaching this span as
a sub span to the EVAL_TREE spans as well.

Fixes #33127  

> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.All"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8965108873>
> Commit: 7176101e021c93b2c53bf3c5d500560729ed45be
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8965108873&attempt=2"
target="_blank">Click here!</a>

<!-- end of auto-generated comment: Cypress test results  -->














## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No
2024-05-06 13:24:52 +05:30
Rajat Agrawal
021b4177ea
chore: Fix bugs in logic for capturing web vitals for client (#32371)
## Description

This PR fixes logic to capture traces only when both end time and start
time are available for a span. The hypothesis is that if a span is
captured but its end time is missing, new relic will add current time as
end time. This end time may be added after a few minutes.

This is skewing the metrics for evaluation traces.

The PR also does refactor of the traces code for general better
readability.

Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!IMPORTANT]  
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8612102498>
> Commit: `64b79261b44cc96c16429bf043565cc92d9d7992`
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8612102498&attempt=1"
target="_blank">Click here!</a>
> All cypress tests have passed 🎉🎉🎉

<!-- end of auto-generated comment: Cypress test results  -->














<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Refactor**
- Unified span creation for telemetry with improved parameter handling
and attribute management.
- Enhanced span timing and nesting logic for better performance
tracking.
- **Chores**
- Simplified telemetry tracing logic across various modules by
standardizing the use of new span management functions.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-09 14:25:46 +05:30
Rajat Agrawal
8eb4b2d618
chore: Add telemetry for monitoring evaluations processing (#32222)
This PR adds more monitoring to evaluations.

> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.All"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!CAUTION]
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8503175561>
> Commit: `7bc70d14f103f671e0c60f5bcc5756be7c9bf8c7`
> Cypress dashboard: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8503175561&attempt=2&selectiontype=test&testsstatus=failed&specsstatus=fail"
target="_blank"> Click here!</a>
> The following are new failures, please fix them before merging the PR:
<ol>
>
<li>cypress/e2e/Regression/ClientSide/Widgets/Form/FormWidget_With_RichTextEditor_spec.js
</ol>
> To know the list of identified flaky tests - <a
href="https://internal.appsmith.com/app/cypress-dashboard/identified-flaky-tests-65890b3c81d7400d08fa9ee3?branch=master"
target="_blank">Refer here</a>

<!-- end of auto-generated comment: Cypress test results  -->













<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit


- **New Features**
- Enhanced tracing capabilities for performance analysis, providing
detailed telemetry for different sections in the app.
- Improved tracing functionality in tree evaluation processes with
additional telemetry parameters and profiling.

- **Refactor**
- Updated the `startNestedSpan` function to accept an optional
`parentSpan` for more flexible tracing setups.
- Integrated telemetry enhancements in data tree generation and
evaluation processes for better performance insights.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-01 11:58:07 +05:30
Rajat Agrawal
ce4d5af147
chore: Add traces for measuring data transfer time between worker thread and… (#30537) 2024-01-25 14:04:17 +05:30
Vemparala Surya Vamsi
904c727071
chore: capturing more telemetry data as per fe coder's requirements(#29153) (#29287)
## Description
Capturing evalTree telemetry data as well as from a few evaluation saga
flows.

#### PR fixes following issue(s)
Fixes #29153

#### Type of change
- Chore (housekeeping or task changes that don't impact user perception)

## Testing
>
#### How Has This Been Tested?
- [x] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Enhanced telemetry with the ability to specify start times for nested
spans.
- Introduced web worker span management for improved performance
monitoring.
  - Implemented profiling functions to trace evaluation processes.

- **Improvements**
- Added telemetry spans to key functions for better performance
insights.
- Refined control flow to include telemetry span handling in various
sagas.

- **Documentation**
- Updated interface definitions to include new telemetry-related
properties.

- **Refactor**
- Streamlined conditional logic to incorporate telemetry span
completion.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2023-12-05 11:02:03 +05:30
Vemparala Surya Vamsi
2f6f824efc
chore: frontend and backend telemetry updates for execute flow #28800 and #28805 (#28936)
## Description
1. Added frontend and backend custom OTLP telemetry to track execute
flow
2. Updated end vars in client side code to match with server sdk
intialisation code.

#### PR fixes following issue(s)
Fixes #28800 and #28805

#### Type of change
- Chore (housekeeping or task changes that don't impact user perception)

#### How Has This Been Tested?
- [x] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed
2023-11-24 13:09:02 +05:30