Skip to content

Conversation

@rclark
Copy link
Contributor

@rclark rclark commented Jun 9, 2016

I might be overthinking this, but just stashing some ideas wrt #139.

@mcwhittemore
Copy link
Contributor

The idea here is that I can ask for my next auto id add set the feature's id to be that?

@rclark
Copy link
Contributor Author

rclark commented Jun 9, 2016

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.

@mcwhittemore
Copy link
Contributor

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?

@rclark
Copy link
Contributor Author

rclark commented Jun 9, 2016

What is the value of an auto incrementing

auto-incrementing is not actually the goal -- the goal is just uniqueness within a single dataset.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants