[elephant-devel] Re: Derived Indicies

Ian Eslick eslick at media.mit.edu
Sun Mar 23 22:12:20 UTC 2008


Do you count fast in 10's of ms or 100's?  :)  -Ian

On Mar 23, 2008, at 5:27 PM, Alex Mizrahi wrote:
> IE> unnecessary.  If you have messages indexed by time than you can  
> simply
> IE> walk the index and filter by user until you have a web page  
> worth of
> IE> messages.
>
> worst case behaviour is very bad -- to prove that there are no  
> messages, it
> will have to scan all of them..
> what's even worse, this worst case is quite frequent -- many users  
> actually
> have empty inboxes.
>
> IE>   A scan, even of an index, may not be fast enough so you could  
> do an
> IE> intersection of user-to values with an ordered list of recent  
> messages.
>
> you mean reading oids from user-to index and scanning/filtering
> modification-time index with them?
> this will mean same worst case.
> of course sufficiently smart system can see which list is less, but  
> still
> with thousands of messages and thousands of users this is going to  
> be quite
> slow.
>
> IE> This should perform similarly to a SQL engine which many ORM  
> systems
> IE> use for queries like this.
>
> i thought in SQL DBMS expression like "create index tree11_idx on
> tree11(qi,value)"
> builds ordered list (btree) of pairs pretty much as in derived index  
> i've
> described, and this will make lookups on both values fast.
>
>
>
> _______________________________________________
> elephant-devel site list
> elephant-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/elephant-devel




More information about the elephant-devel mailing list