elasticsearch/elasticsearch — pull request #5613 by pickypg (2014-03-31 04:37:53+00:00)
Title: Fixing questionable PNRG behavior

Closes #5454 and #5578

This strengthens and simplifies the PNRG used by `random_score` by more closely mirroring the `Random.nextFloat()` method, rather than a mix of that, `nextInt` and `nextDouble`. The `docBase` or `docId` are no longer used as they were biasing the result (particularly if it was `0`, which consistently made it the highest scoring result in tests), which partially defeats the purpose of random scoring.