Skip to content

fix spring OAuth2 class serialize #15414

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

Open
wants to merge 6 commits into
base: 3.3
Choose a base branch
from
Open

fix spring OAuth2 class serialize #15414

wants to merge 6 commits into from

Conversation

wzkris
Copy link

@wzkris wzkris commented May 28, 2025

What is the purpose of the change?

fix issues #15123

Checklist

  • Make sure there is a GitHub_issue field for the change.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Write necessary unit-test to verify your logic correction. If the new feature or significant change is committed, please remember to add sample in dubbo samples project.
  • Make sure gitHub actions can pass. Why the workflow is failing and how to fix it?

@codecov-commenter
Copy link

codecov-commenter commented May 28, 2025

Codecov Report

Attention: Patch coverage is 67.50000% with 13 lines in your changes missing coverage. Please review.

Project coverage is 60.72%. Comparing base (98e5789) to head (bbf26d5).
Report is 6 commits behind head on 3.3.

Files with missing lines Patch % Lines
...o/spring/security/oauth2/OAuth2SecurityModule.java 84.00% 2 Missing and 2 partials ⚠️
...g/security/oauth2/AuthorizationGrantTypeMixin.java 0.00% 1 Missing ⚠️
...ecurity/oauth2/BearerTokenAuthenticationMixin.java 0.00% 1 Missing ⚠️
...curity/oauth2/ClientAuthenticationMethodMixin.java 0.00% 1 Missing ⚠️
...bo/spring/security/oauth2/ClientSettingsMixin.java 0.00% 1 Missing ⚠️
...rity/oauth2/OAuth2AuthenticatedPrincipalMixin.java 0.00% 1 Missing ⚠️
...y/oauth2/OAuth2ClientAuthenticationTokenMixin.java 0.00% 1 Missing ⚠️
.../spring/security/oauth2/RegisteredClientMixin.java 0.00% 1 Missing ⚠️
...bbo/spring/security/oauth2/TokenSettingsMixin.java 0.00% 1 Missing ⚠️
...g/security/oauth2/UnmodifiableCollectionMixin.java 66.66% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##                3.3   #15414      +/-   ##
============================================
- Coverage     60.74%   60.72%   -0.02%     
+ Complexity    10931    10923       -8     
============================================
  Files          1887     1897      +10     
  Lines         86219    86282      +63     
  Branches      12923    12929       +6     
============================================
+ Hits          52370    52396      +26     
- Misses        28377    28409      +32     
- Partials       5472     5477       +5     
Flag Coverage Δ
integration-tests 33.16% <0.00%> (+0.02%) ⬆️
samples-tests 29.18% <0.00%> (-0.02%) ⬇️
unit-tests 58.88% <67.50%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.module.SimpleModule;
import com.fasterxml.jackson.datatype.jsr310.JavaTimeModule;
import org.springframework.security.jackson2.CoreJackson2Module;
import org.springframework.security.jackson2.SecurityJackson2Modules;
Copy link
Member

Choose a reason for hiding this comment

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

If user do not import spring-security-oauth2-authorization-server, will something errors happend here

Copy link
Author

Choose a reason for hiding this comment

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

This class is in the spring-security-core module

@wzkris wzkris requested a review from AlbumenJ May 30, 2025 08:27
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