本文介绍了PHP的MySQL全文搜索:Lucene,狮身人面像,还是?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这当然与全文搜索引擎的比较-Lucene,Sphinx,Postgresql,MySQL?受益于超过一个可用系统的经验(似乎有很多:我使用了lucene,但没有使用狮身人面像",反之亦然).

This is admittedly similar to (but not a duplicate of) Comparison of full text search engine - Lucene, Sphinx, Postgresql, MySQL?, however what I am looking for are specific, supported, recommendations from the benefit of experience with more than one of the available systems (there seems to be a lot of: "I've used lucene, but not sphinx", and vice a versa).

设置:标准LAMP(MySQL 5.0,PHP 5).

The setup: Standard LAMP (Mysql 5.0, PHP 5).

MySQL:表使用InnoDB引擎解决外键约束

MySQL: tables are using the InnoDB engine for foreign key constraints

我们正在寻找索引数据,而不是页面.要建立索引的数据可以使用多种语言(utf-8字符集)

We are looking at indexing data, not pages. data to be indexed may be in multiple languages (utf-8 charset)

我遇到的许多比较(例如 http://blog.evanweaver.com/articles/2008/03/17/rails-search-benchmarks/)不是完全适用(雪貂是lucene端口,但与Zend_Search_Lucene不同)或他们正在推动自己的系统/实现(并非完全公正).

A number of the comparisons I've come across (like http://blog.evanweaver.com/articles/2008/03/17/rails-search-benchmarks/) are either not entirely applicable (ferret is a lucene port but not the same as Zend_Search_Lucene) or they are pushing their own systems/implementations (not exactly unbiased).

我遇到的其他一些人(例如 http://whatstheplot.com/blog/标签/lucene/ http://pagetracer.com/2008/02/15/sphinx-and-lucene-search-engines-first-impressions/)为两个系统的性能提供了截然不同的结果.

Some others I've come across (such as http://whatstheplot.com/blog/tag/lucene/ and http://pagetracer.com/2008/02/15/sphinx-and-lucene-search-engines-first-impressions/) provide very different results for performance of the two systems.

此外,在我已阅读的大部分内容中,几乎所有被忽略的是 Xapian .也许这也值得考虑吗?

Also, all but ignored in much of what I've read is Xapian. Might this be worth consideration as well?

所以...我希望在座的一些人对这个问题有一定的经验,可以为您提供一些建议或为我指明正确的方向.

So... I'm hoping that some of you here on SO have some experience with this question and could help with some recommendations or point me in the right direction.

推荐答案

Sphinx的一个优点是您可以在客户端和MySQL服务器之间插入"它,并且只会干扰"专门解决它的查询,从MySQL透明地反弹其他对象-参见例如本文.不管这对您的用例来说是一个优势,您最好说一下!

One advantage of Sphinx is that you can "interpose" it between your clients and the MySQL server, and it will only "interfere" on queries specifically addressing it, transparently bouncing the others off MySQL -- see e.g this article. Whether that's an advantage in your use case, you're best placed to say!

对不起,没有Xapian或Lucene的真实经验-仍然在阅读有关如何部署它们的信息,这听起来(对我来说!)似乎只有在您确定了实质性优势的情况下才值得.否则,Sphinx的简单易用"部署(作为客户端和MySQL服务器之间的代理")对我来说是一个巨大的巨大胜利!

Sorry, no real-life experience with Xapian or Lucene -- still, reading about how to deploy them, makes it sound like (to me!) as if it might be worth it only if you identified substantial advantages. Otherwise, Sphinx's "easy as pie" deployment, as a "proxy" between your clients and your MySQL server, feels like a big, substantial win to me!

这篇关于PHP的MySQL全文搜索:Lucene,狮身人面像,还是?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-12 12:27