cardboard
cardboard copied to clipboard
[wip] autogenerate numeric ids
I might be overthinking this, but just stashing some ideas wrt #139.
The idea here is that I can ask for my next auto id add set the feature's id to be that?
Yeah the code is definitely not together yet, but the idea would be that every feature needs to be assigned a number that is unique in the dataset. In order to do that in a distributed system, that script in here is "reserving" a chunk of ids, then it would hand those out to new features. Once it runs out, it reserves another block of 1000 numbers.
gotcha. So 0-999 goes to server a, 1000-1999 goes to server b. Than I either get 0 or 1000 when I request my first id.
What is the value of an auto incrementing id if you can't be sure id:0 is older than id:1000?
What is the value of an auto incrementing
auto-incrementing is not actually the goal -- the goal is just uniqueness within a single dataset.