Is it still a good idea to create comos db collection without partition key?

前端 未结 1 1679
面向向阳花
面向向阳花 2020-12-22 08:36

One colleague said that cosmos db will stop supporting collections without a partition key. But I can\'t find any information about this statement from Microsoft.

Th

1条回答
  •  情话喂你
    2020-12-22 09:23

    One colleague said that cosmos db will stop supporting collections without a partition key. But I can't find any information about this statement from Microsoft.

    Based on the tips on the cosmos db portal,this message is confined to portal only so far.

    You still could create non-partitioned collection by using sdk:

    DocumentCollection collection = new DocumentCollection();
    collection.set("id","jay");
    ResourceResponse createColl = client.createCollection("dbs/db",collection,null);
    

    So,i think your service will not be affected by now. As for future trends, I suggest you pay more attention to Microsoft's official statement. If you have any special needs, you can submit feedback for help.

    0 讨论(0)
提交回复
热议问题