[azure] fix bug causing log splitting to not work properly#950
Merged
Conversation
Comment on lines
+650
to
+655
| return Object.assign({ | ||
| ddsource: 'azure.datafactory', | ||
| ddsourcecategory: 'azure', | ||
| service: 'azure', | ||
| ddtags: 'forwardername:testFunctionName' | ||
| }, x); |
There was a problem hiding this comment.
🟠 Code Quality Violation
Prefer object spread over `Object.assign` (...read more)
This rule encourages the use of the object spread syntax over the Object.assign method when creating a new object from an existing one where the first argument is an empty object. This is because the object spread syntax is more concise, easier to read, and can eliminate the need for null checks that are often necessary with Object.assign.
If you need to use Object.assign, make sure that the first argument is not an object literal, as this can easily be replaced with the spread syntax.
benjjs
approved these changes
Jun 25, 2025
benjjs
left a comment
There was a problem hiding this comment.
Looks good aside from the code quality recommendations. Thanks for adding the additional tests.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
There was a bug in our log forwarder which caused log splitting to not function properly. We were incorrectly assuming we had a field name when we actually had an index.
Motivation
Log splitting was not working no matter what setting were used.
Testing Guidelines
Unit tests added to test this behavior
Additional Notes
Types of changes
Check all that apply