> > You should use seconds since the epoch.
> 
> How would I find all the indices then? I would have to check 86400 possible
> index names per day!
> 
> That's why I went for a day-based scheme... it's a reasonable compromise I'd
> say. Especially when the exponential inserting is in place.

Sorry, I should have been more specific. You should use seconds since the
epoch at midnight of the current day.

So today I use 986446800 and tomorrow I use 986533200 (values generated by
`date +%s`). I know this looks ugly compared to the other format.

However, remember that these values are going to be computer-generated.

The benefit of this method comes when you're trolling through different
days. If you write a daemon to troll an index and get all the keys from
multiple days, with an mmddyy sort of format you have to know when to stop
incrementing the dd field and increment the mm field and reset the dd
field. So you have to use a calendar. With the seconds since the epoch
method you just add 86400 for each day.

> When do you think you'll have it ready? Which scheme will you use?

I'll be using the scheme above. I could do this today, perhaps. It's quite
pretty easy to code.



_______________________________________________
Devl mailing list
Devl at freenetproject.org
http://lists.freenetproject.org/mailman/listinfo/devl

Reply via email to