fix array fqdn bug and add unit tests for JsonNodeMapper#37
Merged
vasanthm7 merged 9 commits intolowes:mainfrom Sep 15, 2025
Merged
fix array fqdn bug and add unit tests for JsonNodeMapper#37vasanthm7 merged 9 commits intolowes:mainfrom
vasanthm7 merged 9 commits intolowes:mainfrom
Conversation
added 2 commits
August 4, 2025 16:45
…r top-level arrays
ankur4u007
previously requested changes
Aug 21, 2025
Member
ankur4u007
left a comment
There was a problem hiding this comment.
Just few comments, LGTM otherwise.
.../test/kotlin/com/lowes/auditor/client/infrastructure/frameworks/mapper/JsonNodeMapperTest.kt
Show resolved
Hide resolved
.../src/main/kotlin/com/lowes/auditor/client/infrastructure/frameworks/mapper/JsonNodeMapper.kt
Outdated
Show resolved
Hide resolved
added 6 commits
August 21, 2025 15:13
Contributor
Author
|
comments addressed, ready for final review |
Contributor
Author
|
added some explicit list order tests as suggested by Kunal |
Closing this since its been reviewed
vasanthm7
approved these changes
Sep 15, 2025
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.
Description
I noticed a bug while working on adding element metadata to make the data more searchable. I am raising a PR for this before continuing so it will be easier to review.
The bug specifically applies to top-level arrays, which is probably why it wasn't noticed sooner, but could be a problem if using this library to audit collections. The index was being added to the fqdn twice, creating confusing data and potential comparison issues. This PR enhances the JsonNodeMapper to improve handling of JSON arrays and ensure accurate FQDN generation with proper array indices. The changes include:
The changes maintain backward compatibility while adding more robust handling of complex nested structures.
Type of change
Checklist: