couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dave Cottlehuber (Commented) (JIRA)" <>
Subject [jira] [Commented] (COUCHDB-1405) error generating document id with utc_random
Date Thu, 09 Feb 2012 10:53:00 GMT


Dave Cottlehuber commented on COUCHDB-1405:

I think this is caused by the way erlang handles time drift in erts, basically a trade-off
between reliable handling of erlang timers, vs accurate system clock. This is crucial in real-time
telephony apps, for example, when running on an underlying non-RT OS.

@André can you try this again, after adding the +c flag to the emulator startup in couchdb.bat:

%ERL% -sasl errlog_type error +c -s couch

If you're running CouchDB as a service you'll need to fiddle with erlsrv instead
near the bottom.

NB this is very likely to impact timers in other bits of CouchDB, so avoid in production until
one of the other devs chimes in. We could definitely add support to install different emulator
parameters if a virtual machine infrastructure is detected if thats a suitable solution. Another
alternative is to get the uuid generator to retrieve OS time rather than erlang's interpretation
of the current state.

For more info read "Disable compensation for sudden
changes of system time" also ref COUCHDB-204 and COUCHDB-539. 

> error generating document id with utc_random
> --------------------------------------------
>                 Key: COUCHDB-1405
>                 URL:
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Database Core
>    Affects Versions: 1.1.1
>         Environment: Windows 7, 64-bit, running as virtual pc in hyper-v
>            Reporter: André Bögge
>              Labels: Hyper-V
> I use the utc_random algorithm for generating document ids. So it's possible for me to
calculate time and date out of the id in my client application. After running CouchDB for
about a month i got a difference between system time and calculated time of id of about half
an hour. I restarted the database and even then i got a difference about 1 minute.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message