-
Notifications
You must be signed in to change notification settings - Fork 177
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
fix(MWPW-155964):Lana log error type changed to info. #2818
Conversation
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## stage #2818 +/- ##
==========================================
+ Coverage 95.87% 96.19% +0.32%
==========================================
Files 173 215 +42
Lines 46333 53992 +7659
==========================================
+ Hits 44421 51940 +7519
- Misses 1912 2052 +140 ☔ View full report in Codecov by Sentry. |
libs/martech/martech.js
Outdated
@@ -118,14 +118,14 @@ export const getTargetPersonalization = async () => { | |||
const responseStart = Date.now(); | |||
window.addEventListener(ALLOY_SEND_EVENT, () => { | |||
const responseTime = calculateResponseTime(responseStart); | |||
window.lana.log(`target response time: ${responseTime}`, { tags: 'errorType=info,module=martech' }); | |||
window.lana.log(`target response time: ${responseTime}`, { tags: 'module-martech', errorType: 'i' }); |
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.
is module-martech
tag existing? wouldn't martech
be clear enough, yet smaller?
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.
yes, I will make this change.
libs/martech/martech.js
Outdated
}, { once: true }); | ||
|
||
let manifests = []; | ||
let propositions = []; | ||
const response = await waitForEventOrTimeout(ALLOY_SEND_EVENT, timeout); | ||
if (response.error) { | ||
window.lana.log('target response time: ad blocker', { tags: 'errorType=info,module=martech' }); | ||
window.lana.log('target response time: ad blocker', { tags: 'errorType-info,module-martech' }); |
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.
isn't this not consistent with the above? shouldn't it be
{ tags: 'module-martech', errorType: 'i' }
too?
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.
It should be, if the log was informational but since this is clearly inside the error block i have left the errorType to default which is "error".
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.
mm to me "error" is a problem on our side, the fact the browser uses adblocker does not really fall into that category, but i guess i'm fine :)
This pull request is not passing all required checks. Please see this discussion for information on how to get all checks passing. Inconsistent checks can be manually retried. If a test absolutely can not pass for a good reason, please add a comment with an explanation to the PR. |
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.
key-value pairs are not supported in the tags. Please refer to https://wiki.corp.adobe.com/display/WCMSOps/LANA+-+Log+Always+Never+Assume#LANALogAlwaysNeverAssume-Parameters for the correct parameters to pass to LANA.
I was wrong, see comment below.
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.
This format should work, per the documentation. Please validate in Splunk that these messages now come in as info
type.
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.
Hi @sharath-kannan ! I think the Jira ticket aimed to correct all the LANA logs that are not being used properly, not just the ones from martech.
Okay,I will correct all the lana logs that are used incorrectly in milo and update my PR. Hope using "module-" will be fine for now? |
I would recommend making the tags as concise as possible, but a dash character is fine within a comma-delimited list. The restricted characters are documented on the wiki [1] in the note above the table. |
@sharath-kannan : can you please update your branch with latest code base( I guess it doesn't have video block changes, as corresponding nala tests are failing) |
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.
It's not clear why we're doing this. Did the LANA interface change? At the time this was correct.
video-metadata is a deprecated component so there is no issue here.
Unfortunately, the information provided at the time was incorrect. Key-value pairs have never been supported in |
Validated the change done in splunk logs |
* lana log error type changed * modified lana logs * added a few unit tests for lana logs * Updated tag in utils.js * linting error fixed * linting error fix 2 * unit test fix * added unit test for vimeo
Resolves: MWPW-155964
Test URLs: