我已将 JSON 文件转换为 CSV 格式,现在使用 aerospike 加载器在 Aerospike 中加载 CSV。我可以为简单的结构执行此操作,但是如何修改 allDatatype.json 的内容以在 Aerospike 中加载嵌套的 CSV 文件?
https://github.com/aerospike/aerospike-loader/tree/master/example
JSON 文件
{
"centers" : {
"ER" : {
"admin":{
"users" : {
"emp1" : {
"password" : "abcdefgh",
"username" : "pankaj-roy"
},
"emp2" : {
"password" : "12345678",
"username" : "niketan-shah"
}
}
}
}
}
}
Run Code Online (Sandbox Code Playgroud)
CSV文件
centers.ER.admin.users.emp2.username,centers.ER.admin.users.emp2.password, centers.ER.admin.users.emp1.username,centers.ER.admin.users.emp1.password
niketan-shah,12345678,pankaj-roy,abcdefgh
Run Code Online (Sandbox Code Playgroud) 我有一些包含数据的包数据如下:
packageid-->string
status--->string
status_type--->string
scans--->record(repeated)
scanid--->string
status--->string
scannedby--->string
Run Code Online (Sandbox Code Playgroud)
每天,我有10万包的数据.每天的总包数据大小变为100 MB(大约),1个月后变为3GB.对于每个包,可以进行3-4次更新.因此,每次更新软件包(例如,仅更改状态字段)时,我是否必须覆盖软件包表?
假设我在表中有3个包的数据,现在第二个包的更新来了,我是否必须覆盖整个表(删除和添加整个数据需要每个包更新2个事务)?对于10万个包裹,总交易量将为10 ^ 5*10 ^ 5*2/2.
在没有覆盖表的情况下,还有其他原子更新方法吗?(好像该表包含100万个条目,然后包更新到来,然后覆盖整个表将是一个开销.)