如何更改谷歌云数据存储种类名称? [英] How to change google cloud datastore kind name ?

查看:130
本文介绍了如何更改谷歌云数据存储种类名称?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在使用google cloud datastore来存储数据,很遗憾,起初并没有遵循命名惯例来命名kinds,现在我们想更改数据存储区中已经存在的种类的名称.

We are using google cloud datastore to store data and unfortunately initially haven't followed name convention for naming kinds and now we want to change names of already existing kinds in datastore.

我们已经积累了很多数据,并且涉及到生成该数据的大量计算,因此再次填充完整数据以重命名一种类型对我们来说不是一种选择.

We have already accumulated a lot of data and a lot of computation was involved generating that data so populating that complete data again just to rename a kind isn't an option for us.

试图找出答案,但是没有运气.那么,有什么我想念的东西可以帮助实现这一目标吗?

Have tried finding it out but with no luck. So is there something which I have missed and can be helpful in achieving it ?

推荐答案

您无法在数据存储区中重命名kind,因为种类名称是与数据存储区中每个元素的键一起嵌入的.您将不得不写一个 脚本将所有数据迁移到新的kind.

You cannot rename a kind in datastore, Because the kind name is embedded with the key of each element in the datastore. You will have to write a script to migrate all the data to the new kind.

这篇关于如何更改谷歌云数据存储种类名称?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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