[英]Faceted search: ElasticSearch/Solr or a simple database query?
Forgive this super basic question, from a search newbie. 原谅来自搜索新手的这个超级基本问题。
I want to implement a site that makes use of faceted search. 我想实现一个利用多面搜索的网站。 For example, it's a site with a database of hotels, and I want to allow users to search for hotels within a price range, with a swimming pool, with either three or four stars.
例如,这是一个包含酒店数据库的网站,我希望允许用户搜索价格范围内带有三星级或四星级游泳池的酒店。
Clearly I can return results to users with a simple database query. 显然,我可以通过简单的数据库查询将结果返回给用户。
Should I use ElasticSearch or Solr to implement this instead of using a database query? 我应该使用ElasticSearch还是Solr来实现此目的,而不是使用数据库查询? If so, why?
如果是这样,为什么?
Yes you should use ES or Solr. 是的,您应该使用ES或Solr。 Reasons: primarily performance and the ability to change (think config) 'types of faceting' easily.
原因:主要是性能和轻松更改(考虑配置)“构面类型”的能力。
Faceting is no small feat and although you could do it with a RDBMS, to do it fast requires hard thinking. 构面并不是一件容易的事,尽管您可以使用RDBMS来完成,但要快速完成,就需要认真思考。 Why do it yourself if you can use the gazillions of hours Solr / ES (+ Lucene) teams have worked to optimize it.
如果您可以使用Solr / ES(+ Lucene)团队花了数百万小时的时间来优化它,那么为什么自己动手做呢。
As for the 'types of faceting' I mentioned: 至于“刻面类型”,我提到:
Seriously, don't even consider doing the above with a RDBMS. 认真地说,甚至不要考虑使用RDBMS进行上述操作。 You'll go insane.
你会发疯的。
Hope that helps, and yes I'm familiar with the domain :) 希望能对您有所帮助,是的,我对域名很熟悉:)
Additional questions, just ask. 其他问题,只问。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.