csainty / node-raven

RavenDB client for Node
csainty.github.com/node-raven
MIT License
13 stars 9 forks source link

Question about HiLoKeyGenerator #4

Open VasoBolkvadze opened 10 years ago

VasoBolkvadze commented 10 years ago

Simple question: what about concurrency?

csainty commented 10 years ago

Hey,

This library has been long left neglected. So I am not certain if the HiLoKeyGenerator still conforms to RavenDB's expectations. Were you wondering about concurrency in the javascript code, or on the server when requesting/updating docs? I expect for the later you control that with the etags, the current implementation may or may not be doing that correctly. Like I said, long abandoned :)

VasoBolkvadze commented 10 years ago

Thanks for such fast answer. I was asking about concurrency on the server. When two clients try to store new document at the same time, how it is solved that ids will be different and one document wouldn't overwrite another? Also I'm pretty sure that this library meets with current ravendb version, I think they didn't changed HTTP Api.