Skip to content
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

[BUG]azure-spring-cloud-starter-eventhubs-kafka2.4.0 example china tenant id not working #21336

Closed
3 tasks
Tracked by #23402
dark12345678 opened this issue May 12, 2021 · 4 comments
Closed
3 tasks
Tracked by #23402
Assignees
Labels
azure-spring All azure-spring related issues azure-spring-eventhubs Spring event hubs related issues. bug This issue requires a change to an existing behavior in the product in order to be resolved. Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. good first issue This issue tracks work that may be a good starting point for a first-time contributor

Comments

@dark12345678
Copy link

dark12345678 commented May 12, 2021

Describe the bug
A clear and concise description of what the bug is.
this issue happened when i run the azure-spring-cloud-starter-eventhubs-kafka example which one in the sdk in china region, the tenant id is working when i run the keyvault example, so i am not sure why not working in the eventhubs kafka side. as i think the different is the keyvault can set the azure.keyvault.authority-host: https://login.partner.microsoftonline.cn and i haven't found any info for this in the AzureEnvironment properities.

kafka example
application yml file parts:
client-id: cccc (this is sp role which has added to the namespace IAM role assignment as Contributor role, has full access)
subscription-id: ccccc
client-secret: ccccc
tenant-id: ccccc
resource-group: cccc
environment: AzureChina
region: China North 2
eventhub:
namespace: cccc

2021-05-12 22:10:07.942 ERROR 36604 --- [onPool-worker-1] c.azure.identity.ClientSecretCredential : Azure Identity => ERROR in getToken() call for scopes [https://management.core.chinacloudapi.cn/.default]: AADSTS90002: Tenant 'xxxxxxxxxxxxxxxxxxx' not found. This may happen if there are no active subscriptions for the tenant. Check to make sure you have the correct tenant ID. Check with your subscription administrator.
Trace ID: vvvvvvv
Correlation ID: vvvvvvvv
Timestamp: 2021-05-12 14:10:08Z

Exception or Stack Trace
Add the exception log and stack trace if available

To Reproduce
Steps to reproduce the behavior:
1、download the full azure sdk(the version i download date is 2021/05/12)
2、update the pom for the sample azure-sdk-masterl\sdk\spring\azure-spring-boot-samples\azure-spring-cloud-sample-eventhubs-kafka, change the 2.5.0-beta.1 to 2.4.0
3、set up the application yml with the related info(what i am ues is a china north 2 region and tenant)
4、mvn clean install -DskipTests
5、mvn spring-boot:run

Code Snippet
Add the code snippet that causes the issue.

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.
image

for the event hub namespace( IAM )i have added the service principle role to the list(which clientid and secret is for this sp)

Setup (please complete the following information):

  • OS: [e.g. iOS] windows 10
  • IDE : [e.g. IntelliJ] intellij
  • Version of the Library used azure-spring-cloud-starter-eventhubs-kafka2.4.0
  • example info: the newest pom which one contains 2.5.0-beta.1 as not include in the marven repo, so i change to 2.4.0 version

Additional context
Add any other context about the problem here.
i also set up another way to call the event hub base on the SAS policy with kafka protocol, that's work for the event hub and no need to add any dependency.
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

  • Bug Description Added
  • Repro Steps Added
  • Setup information Added
@ghost ghost added needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels May 12, 2021
@stliu stliu added azure-spring All azure-spring related issues azure-spring-eventhubs Spring event hubs related issues. labels May 13, 2021
@ghost ghost removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label May 13, 2021
@stliu stliu added the good first issue This issue tracks work that may be a good starting point for a first-time contributor label May 13, 2021
@stliu
Copy link
Member

stliu commented May 13, 2021

Thanks @dark12345678 for reporting this, and @yiliuTo would u please take a look of this ?
And @dark12345678 , by the way, opensource contribution / PR is always welcome :D

@backwind1233 backwind1233 self-assigned this May 14, 2021
@yiliuTo
Copy link
Member

yiliuTo commented May 14, 2021

@dark12345678 thanks for the reporting, there is a bug with the configuration we provide to set cloud environment, we will fix it soon.

@saragluna saragluna added this to the [2021] June milestone May 17, 2021
@yiliuTo yiliuTo linked a pull request May 17, 2021 that will close this issue
@yiliuTo yiliuTo modified the milestones: [2021] June, [2021] July Jun 1, 2021
@yiliuTo yiliuTo modified the milestones: [2021] July, [2021] August Jul 1, 2021
@stliu stliu added bug This issue requires a change to an existing behavior in the product in order to be resolved. and removed question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Aug 6, 2021
@yiliuTo yiliuTo added the Client This issue points to a problem in the data-plane of the library. label Aug 11, 2021
@yiliuTo yiliuTo removed this from the [2021] September milestone Aug 27, 2021
@yiliuTo yiliuTo added this to the Backlog milestone Aug 27, 2021
@stliu
Copy link
Member

stliu commented Sep 30, 2021

this is duplicated by #21593

@backwind1233
Copy link
Contributor

backwind1233 commented Nov 19, 2021

close this issue, track in Release Spring Cloud for Azure 4.0.0-beta.1
the issue will be resolved after the 4.0.0-beta.1 libraries released.

Repository owner moved this from Todo to Done in Spring Cloud Azure Nov 19, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Apr 12, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
azure-spring All azure-spring related issues azure-spring-eventhubs Spring event hubs related issues. bug This issue requires a change to an existing behavior in the product in order to be resolved. Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. good first issue This issue tracks work that may be a good starting point for a first-time contributor
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

6 participants