Re: Logging the click data
Vivek Pal <[email protected]> Wed, 7 Jun 2017 03:42:47 +0530
| Newsgroups | gmane.comp.search.xapian.devel |
|---|---|
| Message-ID | <CAGxcUfwgJof9m2w1QamUQpc6wwK7yU4Leoips75MFbP3jF6LRw@mail.gmail.com> |
> There's a lot of flexibility already, because the log format is just > omegascript. So I don't think you need to implement a new command to > achieve this. (Although you might need a command to generate the query > id. It depends on how you're going to do that.) Ok, I'll try adapting the existing log command to achieve the kind of logging we want. And, about the command to generate unique query ids, I've been thinking to tackle this as a kind of hashing problem where we'll basically provide the query text as input to generate a unique id as output. Although, coming up with a 100% collision-free hashing algorithm for this task is something worth considering first. Other caveats include max length of the generated unique id string and whether we should truncate leading whitespaces from the query text to avoid "essentially same" queries from being recorded in different entries in the log file. What do you suggest? Thanks, Vivek