Azure / azure-sdk-for-java

This repository is for active development of the Azure SDK for Java. For consumers of the SDK we recommend visiting our public developer docs at https://docs.microsoft.com/java/azure/ or our versioned developer docs at https://azure.github.io/azure-sdk-for-java.
MIT License
2.32k stars 1.97k forks source link

[FEATURE REQ] Support auth by customer defined TokenCredencial for all scenarios #40897

Open rujche opened 3 months ago

rujche commented 3 months ago

Is your feature request related to a problem? Please describe. When migrate auth in Spring tests, the pipeline shows that some integration test failed because related feature not support auth by customer defined TokenCredential bean.

  1. Link to PR: https://github.com/Azure/azure-sdk-for-java/pull/40800
  2. Link to pipeline: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=3914516&view=logs&j=b6747878-dc75-581a-bba2-ee42aac9c86f&t=9578c5f5-3931-5ca2-47db-3cca71421dc5&l=16070
  3. Screenshot of test failure of pipeline:

    image

Describe the solution you'd like Develop new feature: Make related scenario support customer-defined TokenCredential. Make all existing integration tests passed in pipeline.

Information Checklist Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report

rujche commented 3 months ago

Sharing: About ServiceBusMultiBindersIT, @ConditionalOnMissingBean not take effect because there are 2 ApplicationContexts: Here is the screenshot about how to find the 2 ApplicationContexts:

image image