-
Notifications
You must be signed in to change notification settings - Fork 146
feat(rum-core): allow sending route-change transactions with no spans via config
#1665
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
base: main
Are you sure you want to change the base?
Conversation
🤖 GitHub commentsJust comment with:
|
🔍 Preview links for changed docs |
vigneshshanmugam
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rest looks good.
docs/reference/configuration.md
Outdated
| * **Type:** Boolean | ||
| * **Default:** `false` | ||
|
|
||
| This allows the agent to send all `route-change` transactions regardless if it contains any spans or not. This is usefull if you want to keep track of all the navigations your app is doing. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Need to call out how sampling plays a role in here as well.
docs/reference/configuration.md
Outdated
| :::: | ||
|
|
||
|
|
||
| ### `sendAllRouteChanges` [send-all-route-changes] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There might be a request to add the same logic to user-click events as well, lets make this flag generic? reportAllTraces something along these lines ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
At 1st I thought maybe to filter by transaction type. I don't have a strong opinion. Do we want a single or more fine grained control?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My suggestion is recordEmptyTransactions. Empty meaning with no spans. WDYT?
|
|
||
|
|
||
| ### `sendAllRouteChanges` [send-all-route-changes] | ||
| ### `recordEmptyTransactions` [record-empty-transactions] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: reportTransactionsWithoutSpans? - fine with Empty as well. Just provided as a suggestion.
The route change transaction is a type of transaction that can be interesting eve if it does not contain spans. Can be used to track the journey of the users across the instrumented web application. Is specifically useful for single page applications (SPA) where the URL can change without performing any HTTP request (hence no spans) because of the app caching data or because there is no need to fetch data.
The change introduces a new flag in configuration named
sendAllRouteChangeswhich defaults tofalsekeeping the current behavior. Apps that wants to record all transactions of typeroute-changecan set this config totrue.