Skip to content

Fix broken Spring compatibility tests #45733

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 9 commits into
base: main
Choose a base branch
from

Conversation

alzimmermsft
Copy link
Member

Description

Fixes #45602

Adds additional suppression to azure-spring-data-cosmos to suppression a deprecation for removal warning.

Fixes script that generates the compatibility test matrix to use the source version of spring-cloud-azure-supported-spring.json rather than the one committed to the main branch. This fix would have prevented the broken change in azure-spring-data-cosmos from being merged to main.

All SDK Contribution checklist:

  • The pull request does not introduce [breaking changes]
  • CHANGELOG is updated for new features, bug fixes or other significant changes.
  • I have read the contribution guidelines.

General Guidelines and Best Practices

  • Title of the pull request is clear and informative.
  • There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For more information on cleaning up the commits in your PR, see this page.

Testing Guidelines

  • Pull request includes test coverage for the included changes.

@alzimmermsft alzimmermsft self-assigned this Jun 17, 2025
@alzimmermsft alzimmermsft added EngSys This issue is impacting the engineering system. azure-spring All azure-spring related issues labels Jun 17, 2025
@alzimmermsft alzimmermsft marked this pull request as ready for review June 17, 2025 16:47
@Copilot Copilot AI review requested due to automatic review settings June 17, 2025 16:47
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 pull request fixes the broken Spring compatibility tests by adding additional suppression annotations to address deprecation and removal warnings and by updating scripts to read the local supported Spring JSON file rather than fetching it remotely.

  • Added "removal" to @SuppressWarnings annotations in several test and configuration files.
  • Modified scripts to load the supported Spring versions from a local file, and updated Maven options in pipeline YAML files.

Reviewed Changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated no comments.

Show a summary per file
File Description
sdk/spring/spring-cloud-azure-autoconfigure/src/test/java/com/azure/spring/cloud/autoconfigure/implementation/aadb2c/configuration/WebOAuth2ClientTestApp.java Added suppression for "removal" warning.
sdk/spring/spring-cloud-azure-autoconfigure/src/test/java/com/azure/spring/cloud/autoconfigure/implementation/aad/configuration/AadOAuth2ClientConfigurationTests.java Updated suppression to include "removal".
sdk/spring/spring-cloud-azure-autoconfigure/src/main/java/com/azure/spring/cloud/autoconfigure/implementation/aadb2c/security/AadB2cOidcLoginConfigurer.java Updated suppression to include "removal".
sdk/spring/spring-cloud-azure-autoconfigure/src/main/java/com/azure/spring/cloud/autoconfigure/implementation/aadb2c/security/AadB2cAuthorizationRequestResolver.java Added suppression for "removal" warning.
sdk/spring/spring-cloud-azure-autoconfigure/src/main/java/com/azure/spring/cloud/autoconfigure/implementation/aad/configuration/AadOAuth2ClientConfiguration.java Updated multiple suppression annotations to include "removal".
sdk/spring/spring-cloud-azure-autoconfigure/src/main/java/com/azure/spring/cloud/autoconfigure/implementation/aad/security/AbstractOAuth2AuthorizationCodeGrantRequestEntityConverter.java Updated suppression to include "removal".
sdk/spring/spring-cloud-azure-autoconfigure/src/main/java/com/azure/spring/cloud/autoconfigure/implementation/aad/security/AadWebApplicationHttpSecurityConfigurer.java Updated suppression to include "removal".
sdk/spring/spring-cloud-azure-autoconfigure/src/main/java/com/azure/spring/cloud/autoconfigure/implementation/aad/security/AadJwtBearerGrantRequestEntityConverter.java Updated suppression to include "removal".
sdk/spring/scripts/monitor_update_monitor_matrix_json.py Changed file retrieval from an HTTP request to local file reading.
sdk/spring/scripts/compatibility_update_supported_version_matrix_json.py Changed file retrieval from HTTP request to local file read.
sdk/spring/scripts/compatibility_get_spring_cloud_version.py Modified file fetching to read from a local file.
sdk/spring/pipeline/monitor-tests-job.yml Updated Maven options to include "--fail-at-end" and added logging options.
sdk/spring/pipeline/compatibility-tests-job.yml Updated Maven options to include "--fail-at-end" and logging options.
sdk/spring/azure-spring-data-cosmos/src/main/java/com/azure/spring/data/cosmos/repository/support/ReactiveCosmosRepositoryFactory.java Updated suppression annotations to include "removal".
sdk/spring/azure-spring-data-cosmos/src/main/java/com/azure/spring/data/cosmos/repository/support/CosmosRepositoryFactory.java Updated suppression annotations to include "removal".

@alzimmermsft
Copy link
Member Author

@Netyyyy the PR should be in a good state to merge as it makes the script work better and fixes compilation issues. There are still test failures, but I don't know the code well enough to fix them.

Should I file an issue for the Spring SDK owners to follow up on?

Copy link
Contributor

github-actions bot commented Jun 27, 2025

API Change Check

APIView identified API level changes in this PR and created the following API reviews

com.azure:azure-spring-data-cosmos

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
azure-spring All azure-spring related issues EngSys This issue is impacting the engineering system.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use spring-cloud-azure-supported-spring.json from SHA running in pipeline
2 participants