Дана Thursday 12 November 2009 16:52:54 Aryeh Gregor написа:
> On Thu, Nov 12, 2009 at 10:43 AM, Nikola Smolenski <[email protected]> 
wrote:
> > I'd say it is, if sufficiently precise :)
>
> MediaWiki only keeps timestamps to one-second precision, so it's not.

I propose the following heuristics:

1. If appropriate timestamp doesn't exist in the database, use the newest one 
older than the requested one.

2. If it exists, and only one revision has the timestamp, use that revision.

3. If more than one revision share the same timestamp, divide the second in 
the number of revisions parts, and use the revision that falls in the 
requested timestamp.

Suppose that someone asks for Wikipedia as it looked on 2009-11-13 
18:53:11.4281. There are foutr revisions that have 2009-11-13 18:53:11 
timestamp, revisions 123456, 123457, 123459 and 123460. Each revision gets 
its quarter of the second, and since the request falls in the 2nd quarter, 
use revision 123457.

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to