Search optimised database
Inspired by System Design Interview: Design Ticketmaster w/ a Ex-Meta Staff Engineer
It usually builds an inverted index for fast querying, like:
{
"word1": [doc1, doc2, doc3],
"word2": [doc2, doc3, doc4],
"word3": [doc1, doc3, doc4]
}
- Tokenization: Tokenization is the process of breaking a piece of text into individual words. This allows you to map from words to documents in the inverted index.
- Stemming: Stemming is the process of reducing words to their root form. This allows you to match different forms of the same word. For example, "running" and "runs" would both be reduced to "run".
Technologies
Sources
- System Design Interview: Design Ticketmaster w/ a Ex-Meta Staff Engineer inspired this note
Referenced by
- Search systemsGrowing
Postgres is fine to begin with for basic search. Select where like term. When would somethint else be more relevant ? Wildcard search are slow tho, it'll scan the whole db. But…