-
Notifications
You must be signed in to change notification settings - Fork 21
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
[Issue #3764] add search query params to new relic #4039
base: main
Are you sure you want to change the base?
Conversation
…t not setting yet
2fda842
to
a807453
Compare
export const metadata: Metadata = { | ||
icons: [`${environment.NEXT_PUBLIC_BASE_PATH}/img/favicon.ico`], | ||
}; | ||
|
||
type NRType = typeof newrelic; |
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.
moved this stuff to a types file
@@ -64,16 +64,19 @@ export interface SearchAPIResponse extends APIResponse { | |||
fieldChanged?: string; | |||
} | |||
|
|||
export const validSearchQueryParamKeys = [ |
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.
wanted to be able to use these values for whitelisting / iteration, so switched up a bit of the typing here
@@ -66,6 +66,7 @@ | |||
"@types/js-cookie": "^3.0.6", | |||
"@types/lodash": "^4.17.13", | |||
"@types/newrelic": "^9.14.6", | |||
"@types/new-relic-browser": "^1.230.5", |
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.
used implicitly to provide a type for window.newrelic
Summary
Fixes #3764
Time to review: 15 mins
Changes proposed
Context for reviewers
Note that custom attributes are being cleared when navigating away from the search page, but not quickly enough for them to not show up on the route transition events on navigation. Not sure if this is a deal breaker.
Also note that I've discovered that trying to run the app with new relic enabled but without an app name or license key results in the application hanging indefinitely. We should fix this in a future ticket.
Further note that given the somewhat vague requirements in the ticket I've just tried to make sure here that all the necessary data is making it into new relic, as much as possible. I created a basic dashboard view of a query to show the new parameters, but anything other work on this should probably go in another ticket. I attempted to make the query more flexible, by querying for all attributes with the
search_param
prefix, so far with no luck;.Documentation updates are in order, but need to wait for #4005 with larger documentation updates to come in first
Related docs
Test steps
npm run build -- --no-lint && NEW_RELIC_APP_NAME="Simpler Grants Next DEV" NEW_RELIC_LICENSE_KEY="<license key from 1password>" npm run start:nr
Additional information