跳转至

Azure Cosmos DB

The Azure Cosmos DB connector is a Palantir-provided driver for Azure Cosmos DB.

To create a new Azure Cosmos DB source, follow the standard setup flow for Palantir-provided drivers, then use the sections below for Azure Cosmos DB-specific configuration and networking. For the complete property reference, see the official Azure Cosmos DB driver documentation ↗.

Configuration

The properties below are mandatory or recommended.

Property Required? Description Default
AccountEndpoint Mandatory The value should be the Cosmos DB account URL from the Keys blade of the Cosmos DB account. https://<URL>
AuthScheme Mandatory The type of authentication to use when connecting to Azure Cosmos DB. AccountKey
AccountKey Recommended A master key token or a resource token for connecting to the Azure Cosmos DB REST API.
InitiateOAuth Recommended Specifies the process for obtaining or refreshing the OAuth access token, which maintains user access while an authenticated, authorized user is working. REFRESH
OAuthClientId Recommended Specifies the client Id that was assigned when the custom OAuth application was created. (Also known as the consumer key.) This ID registers the custom application with the OAuth authorization server.
OAuthClientSecret Recommended Specifies the client secret that was assigned when the custom OAuth application was created. (Also known as the consumer secret). This secret registers the custom application with the OAuth authorization server.
Schema Recommended Specify the Azure Cosmos DB database you want to work with.

Networking

The table below lists the domains that the source needs to be able to access in order to successfully run.

For each domain, add a corresponding egress policy. If the source is hosted on-premises and not directly reachable from Foundry, use an agent proxy egress policy instead; the agent host itself must also be able to reach the listed domains. See using an agent as a proxy for details.

Domain Required
\ Always. AccountEndpoint connection property (may be in the format https://\:\ or may be a full URL)
login.microsoftonline.com If AuthScheme=AzureAD, AzureServicePrincipal, AzureServicePrincipalCert AND AzureEnvironment=GLOBAL (default)
login.chinacloudapi.cn If AuthScheme=AzureAD, AzureServicePrincipal , AzureServicePrincipalCert AND AzureEnvironment=CHINA
login.microsoftonline.us If AuthScheme=AzureAD, AzureServicePrincipal, AzureServicePrincipalCert AND AzureEnvironment=USGOVT or USGOVTDOD

中文翻译

# Azure Cosmos DB

<!-- BEGIN GENERATED:intro -->

Azure Cosmos DB 连接器是 Palantir 为 Azure Cosmos DB 提供的[官方驱动程序](https://palantir.com/docs/foundry/data-integration/foundry-provided-drivers/)。

要创建新的 Azure Cosmos DB 数据源,请遵循 [Palantir 官方驱动程序的标准设置流程](https://palantir.com/docs/foundry/data-integration/foundry-provided-drivers/#setup),然后参考以下各节进行 Azure Cosmos DB 的特定配置和网络设置。如需完整的属性参考,请参阅 [Azure Cosmos DB 官方驱动程序文档 ↗](https://cdn.cdata.com/help/EHK/jdbc/pg_connectionj.htm)。

<!-- END GENERATED:intro -->

<!-- BEGIN GENERATED:configuration -->

## 配置

以下属性为必填或推荐项。

| 属性 | 是否必填 | 描述 | 默认值 |
|---|---|---|---|
| [`AccountEndpoint` ↗](https://cdn.cdata.com/help/EHK/jdbc/RSBCosmosdb_p_AccountEndpoint.htm) | 必填 | 该值应为 Cosmos DB 账户的"密钥"页面中的 Cosmos DB 账户 URL。 | `https://<URL>` |
| [`AuthScheme` ↗](https://cdn.cdata.com/help/EHK/jdbc/RSBCosmosdb_p_AuthScheme.htm) | 必填 | 连接到 Azure Cosmos DB 时使用的身份验证类型。 | `AccountKey` |
| [`AccountKey` ↗](https://cdn.cdata.com/help/EHK/jdbc/RSBCosmosdb_p_AccountKey.htm) | 推荐 | 用于连接 Azure Cosmos DB REST API 的主密钥令牌或资源令牌。 | — |
| [`InitiateOAuth` ↗](https://cdn.cdata.com/help/EHK/jdbc/RSBCosmosdb_p_InitiateOAuth.htm) | 推荐 | 指定获取或刷新 OAuth 访问令牌的过程,该令牌用于在已认证授权用户工作时维持其访问权限。 | `REFRESH` |
| [`OAuthClientId` ↗](https://cdn.cdata.com/help/EHK/jdbc/RSBCosmosdb_p_OAuthClientId.htm) | 推荐 | 指定创建自定义 OAuth 应用程序时分配的客户端 ID(也称为消费者密钥)。该 ID 用于在 OAuth 授权服务器上注册自定义应用程序。 | — |
| [`OAuthClientSecret` ↗](https://cdn.cdata.com/help/EHK/jdbc/RSBCosmosdb_p_OAuthClientSecret.htm) | 推荐 | 指定创建自定义 OAuth 应用程序时分配的客户端密钥(也称为消费者密钥)。该密钥用于在 OAuth 授权服务器上注册自定义应用程序。 | — |
| [`Schema` ↗](https://cdn.cdata.com/help/EHK/jdbc/RSBCosmosdb_p_Schema.htm) | 推荐 | 指定要使用的 Azure Cosmos DB 数据库。 | — |

<!-- END GENERATED:configuration -->

<!-- BEGIN GENERATED:networking -->

## 网络配置

下表列出了数据源成功运行所需访问的域名。

请为每个域名添加相应的[出站策略](https://palantir.com/docs/foundry/administration/configure-egress/)。如果数据源部署在本地且无法从 Foundry 直接访问,请改用[代理出站策略](https://palantir.com/docs/foundry/administration/configure-egress/#agent-proxy-egress-policies);代理主机本身也必须能够访问所列域名。详情请参阅[使用代理作为代理](https://palantir.com/docs/foundry/data-connection/agent-proxy/)。

| 域名 | 必需条件 |
|--- |--- |
| \<AccountEndpoint> | 始终必需。AccountEndpoint 连接属性(格式可能为 https://\<服务器>:\<端口> 或完整 URL) |
| login.microsoftonline.com | 当 `AuthScheme=AzureAD`、AzureServicePrincipal、AzureServicePrincipalCert 且 `AzureEnvironment=GLOBAL`(默认)时 |
| login.chinacloudapi.cn | 当 `AuthScheme=AzureAD`、AzureServicePrincipal、AzureServicePrincipalCert 且 `AzureEnvironment=CHINA` 时 |
| login.microsoftonline.us | 当 `AuthScheme=AzureAD`、AzureServicePrincipal、AzureServicePrincipalCert 且 `AzureEnvironment=USGOVT` 或 USGOVTDOD 时 |

<!-- END GENERATED:networking -->