gpt4 book ai didi

java - 用于访问 Azure Data Lake 的客户端 ID、身份验证 token 端点、客户端 key 是什么?

转载 作者:行者123 更新时间:2023-11-30 12:05:23 25 4
gpt4 key购买 nike

我正在编写一个测试应用程序来从 AzureData Lake 读取文件。我已经创建了帐户和资源,并上传了文件。我正在尝试使用以下代码创建客户端(如文档 https://learn.microsoft.com/en-us/azure/data-lake-store/data-lake-store-get-started-java-sdk 中所述)。我到底从哪里获得这些值?谢谢

String clientId = "FILL-IN-HERE";
String authTokenEndpoint = "FILL-IN-HERE";
String clientKey = "FILL-IN-HERE";

AccessTokenProvider provider = new ClientCredsTokenProvider(authTokenEndpoint, clientId, clientKey);
// full account FQDN, not just the account name
String accountFQDN = "FILL-IN-HERE";
ADLStoreClient client = ADLStoreClient.createClient(accountFQDN, provider);

最佳答案

您似乎正在使用 Azure Active Directory authentication使用 Azure 数据湖。

登录Azure门户->单击Azure Active Directory->单击应用程序注册->找到您的应用程序(或创建一个新应用程序)

客户端ID

enter image description here

clientKey(单击“证书和 secret ”->单击“新客户端 secret ”->单击“添加”)客户端 secret 是 clientKey。

enter image description here

authTokenEndpoint点击端点

enter image description here

引用这个document了解更多详情。

关于java - 用于访问 Azure Data Lake 的客户端 ID、身份验证 token 端点、客户端 key 是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56349040/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com