Skip to content

Conversation

Avery-Dunn
Copy link
Contributor

Replaces usage of com.fasterxml.jackson with com.azure.json, as per #909

This PR changes to claims-related classes which are similar to those done in #918:

  • Adjust classes to implement azure-json's JsonSerializable interface
  • Remove jackson-databind's JSON annotations from those classes
  • Add new unit tests to show the new methods handle JSON properly

@Avery-Dunn Avery-Dunn requested a review from a team as a code owner May 5, 2025 23:33
@Avery-Dunn Avery-Dunn requested a review from Copilot May 7, 2025 18:42
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates claims-related classes to replace Jackson JSON processing with azure-json while adding new test cases to ensure proper JSON serialization and deserialization.

  • Implements the JsonSerializable interface for claims classes
  • Removes Jackson JSON annotations and replaces them with azure-json APIs
  • Adds unit tests to validate JSON conversions and error handling

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
msal4j-sdk/src/test/java/com/microsoft/aad/msal4j/ClaimsTest.java Added new tests to verify JSON serialization of claims with azure-json APIs
msal4j-sdk/src/main/java/com/microsoft/aad/msal4j/RequestedClaimAdditionalInfo.java Migrated JSON serialization/deserialization to azure-json
msal4j-sdk/src/main/java/com/microsoft/aad/msal4j/RequestedClaim.java Updated JSON conversion methods using azure-json; adjusted factory method for claim parsing
msal4j-sdk/src/main/java/com/microsoft/aad/msal4j/ClaimsRequest.java Replaced Jackson processing with azure-json implementations in serialization and parsing logic

@Avery-Dunn Avery-Dunn merged commit aa30533 into avdunn/json-removal May 8, 2025
3 checks passed
@Avery-Dunn Avery-Dunn deleted the avdunn/json-claimsrequest branch June 3, 2025 17:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants