Skip to content

Add new samples - ssl-bundles-server, ssl-bundles-rest-template and ssl-bundles-web-client #774

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

Merged

Conversation

moarychan
Copy link
Contributor

@moarychan moarychan commented Feb 20, 2025

Purpose

New sample for new starter spring-cloud-azure-starter-keyvault-jca, see more from Azure/azure-sdk-for-java#44259. Once the Spring Cloud Azure 5.21.0 release then update the version in the sample.

Does this introduce a breaking change?

[ ] Yes
[x] No

Pull Request Type

What kind of change does this Pull Request introduce?

[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Documentation content changes
[ ] Other... Please describe:

How to Test

Build Spring Cloud Azure 5.21.0-beta.1 and run the sample.

What to Check

Verify that the following are valid

  • ...

Other Information

@moarychan moarychan changed the title Add new sample - keyvault-ssl-bundles Add new samples - keyvault-ssl-bundles-web and keyvault-ssl-bundles-webflux Feb 27, 2025
@moarychan moarychan changed the title Add new samples - keyvault-ssl-bundles-web and keyvault-ssl-bundles-webflux Add new samples - keyvault-ssl-bundles-server and keyvault-ssl-bundles-client Mar 3, 2025
@moarychan moarychan changed the title Add new samples - keyvault-ssl-bundles-server and keyvault-ssl-bundles-client Add new samples - ssl-bundles-server, ssl-bundles-rest-template and ssl-bundles-web-client Mar 5, 2025
@moarychan moarychan marked this pull request as ready for review March 24, 2025 13:18
@moarychan moarychan requested a review from a team as a code owner March 24, 2025 13:18
@rujche rujche requested review from saragluna, rujche and Copilot March 25, 2025 01:11
Copy link

@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 adds three new sample projects (ssl‐bundles-server, ssl‐bundles-rest‐template, and ssl‐bundles-web‐client) to demonstrate how to enable SSL and mTLS using Azure Key Vault JCA with Spring Cloud Azure. The changes include new documentation, sample application classes, REST controllers, and configuration files to support the new starter.

Reviewed Changes

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

Show a summary per file
File Description
keyvault/spring-cloud-azure-starter-keyvault-jca/README.md Updated overview and instructions for the new samples.
keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-server/README.md Added detailed setup steps and instructions for the server sample.
keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/README.md Added documentation and instructions for the RestTemplate sample.
keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/src/main/resources/application.yaml Provided sample configuration for SSL bundles with Azure Key Vault.
keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/src/main/java/com/azure/spring/sample/keyvault/jca/* Added application and controller classes to demonstrate RestTemplate SSL usage.
keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-server/src/main/java/com/azure/spring/sample/keyvault/jca/KeyVaultSslBundlesServerApplication.java Added the server application bootstrap class.
README.md Updated the main project README to include the new ssl‐bundles samples.
Files not reviewed (7)
  • keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/pom.xml: Language not supported
  • keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/terraform/main.tf: Language not supported
  • keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/terraform/outputs.tf: Language not supported
  • keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/terraform/setup_env.ps1: Language not supported
  • keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/terraform/setup_env.sh: Language not supported
  • keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-rest-template/terraform/variables.tf: Language not supported
  • keyvault/spring-cloud-azure-starter-keyvault-jca/ssl-bundles-server/pom.xml: Language not supported
Comments suppressed due to low confidence (1)

README.md:89

  • Typo in the repository path: 'azure-securtiy-keyvault-jca' should be corrected to 'azure-security-keyvault-jca'.
| run-with-command-line-server-side | ✅ [link](keyvault/azure-securtiy-keyvault-jca/run-with-command-line-server-side)      | ✅ [link](https://github.com/Azure-Samples/azure-spring-boot-samples/tree/spring-boot-2.x/keyvault/azure-securtiy-keyvault-jca/run-with-command-line-server-side)                     |

</project>
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: Don't introduce unnecessary change.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

IDE updates automatically, let's keep these changes since it will be updated next time if there's no empty line on the end.

products:
- azure-key-vault
name: Enable RestTemplate SSL from Azure Key Vault SSL Bundles in Spring Boot web Application
description: This sample demonstrates how to enable RestTemplate SSL via Azure KeyVault SSL bundles in Spring Boot web application.
Copy link
Contributor

Choose a reason for hiding this comment

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

Where will this header be used?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not sure, maybe it's for easy recommendation or indexing.

Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor

@rujche rujche left a comment

Choose a reason for hiding this comment

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

LGTM.

@moarychan moarychan merged commit a63e00f into Azure-Samples:main Mar 26, 2025
7 checks passed
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