arekdygas commented on issue #1152: Inconsistent sum and sumsqr aggregates of floating point numbers URL: https://github.com/apache/couchdb/issues/1152#issuecomment-364258099 Integers work ok in CouchDB 2.1.1 (single node with 8 shards). Out of curiosity I did some tests in JS engine used by Chrome: -0.1-0.2+0.1+0.2 = -2.7755575615628914e-17 0.1+0.2-0.1-0.2 = 2.7755575615628914e-17 other combinations = 0 which are exact results from my test case. I don't really know how CouchDB internally works, but I think it reads aggregates from shards and then calculates final aggregate. That would explain this issue, if shards results are returned in random order. But it looks that in Cloudant they are always returned in the same order, making the result the same across multiple requests.
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
