部署期间如何配置Cosmos Db集合 [英] How to configure a Cosmos Db collection during deployment

查看:43
本文介绍了部署期间如何配置Cosmos Db集合的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用Azure 在GlobalDocumentDB模式下部署Cosmos Db数据库时资源管理器模板,据我所知,无法在部署期间在数据库中配置集合.

When deploying a Cosmos Db database in GlobalDocumentDB mode using the Azure resource manager template there is no way to configure collections in the database during deployment that I can tell.

在ARM模板部署期间,有任何一种方法(按优先顺序排列)

During a ARM template deployment is there any way to either (in order of preference)

  1. 以我忽略的方式直接在Cosmos Db数据库中配置集合.
  2. 在模板中执行一系列REST请求以配置数据库.
  3. 在模板中执行一个REST请求,以使用HttpTrigger来访问Azure功能,该功能将配置数据库.

推荐答案

您应该可以使用这些模板.

You should be able to use these Templates.

  • Containers:
    https://docs.microsoft.com/en-us/azure/templates/microsoft.documentdb/2015-04-08/databaseaccounts/apis/databases/containers
  • Collections:
    https://docs.microsoft.com/en-us/azure/templates/microsoft.documentdb/2015-04-08/databaseaccounts/apis/databases/collections
  • All Microsoft.DocumentDB Resource Types:
    https://docs.microsoft.com/en-us/azure/templates/microsoft.documentdb/allversions

这些页面在05/01/2019&适用于API版本2015-04-08.

These pages were published on 05/01/2019 & are for API version 2015-04-08.

这篇关于部署期间如何配置Cosmos Db集合的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆