本文介绍了什么时候在 Sitecore 7 构建中绝对使用 SOLR 而不是 Lucene?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的客户没有预算来设置和维护 SOLR 服务器以在其生产环境中使用.如果我正确理解了 Sitecore 7 内容搜索 API,那么配置使用 Lucene 并不是什么大问题.大部分配置类似,代码相同,以后可以换一个SOLR服务器.

My client does not have the budget to setup and maintain a SOLR server to use in their production environment. If I understand the Sitecore 7 Content Search API correctly, it is not a big deal to configure things to use Lucene instead. For the most part the configuration will be similar and the code will be the same, and a SOLR server can be swapped in later.

网站建设有

  • 多面搜索页面
  • 在登陆页面和其他页面上列出将利用 Content Search API 的组件
  • 具有自定义构面的存储桶

该网站有大约 5,000 个页面和组件,不包括媒体库项目.单纯使用 Lucene 有什么顾虑吗?

The site has around 5,000 pages and components not including media library items. Are there any concerns about simply using Lucene?

主要问题是,在您的架构或设计阶段,您何时知道绝对应该选择 SOLR 而不是 Lucene?导致您建议这样做的主要迹象是什么?

The main question is, when, during your architecture or design phase do you know that you should definitely choose SOLR over Lucene? What are the major signs that lead you recommend that?

推荐答案

我认为,如果您正在与预算有限的客户打交道,那么 Lucene 将完美地工作,并且在您正在做的事情的规模上表现出色.Lucene 中的实现完全支持您提到的所有内容.

I think if you are dealing with a customer on a limited budget then Lucene will work perfectly well and perform excellently for the scale of things you are doing. All the things you mention are fully supported by the implementation in Lucene.

在 Sitecore 场景中,如果满足以下条件,我会开始考虑 Solr:

In a Sitecore scenario I would begin to consider Solr if:

  • 您需要索引大量项目 - id 说 5 万以上 - Lucene 对这些数字很满意,但 Solr 改进了查询缓存,并且专为这些大量项目而设计.
  • 搜索层的弹性对业务至关重要(即网站完全由搜索驱动) - Solr 通过 SolrCloud 提供更强大的复制/分片和故障转移系统.
  • 在其他应用程序中重新调整搜索层的用途很重要(非 Sitecore) - Solr 是一个搜索应用程序,因此可以使用 XML/JSON 等通过 HTTP 访问,这使得与外部系统的集成更容易.
  • 您需要一些 Lucene 所没有的特定 Solr 附加功能.

.. 但正如您所说,如果您想在稍后阶段将 Lucene 换成 Solr,我们已经努力确保该过程尽可能简单.这里值得注意的几点:

.. but as you say if you want swap out Lucene for Solr at a later phase, we have worked hard to make sure that the process as simple as possible. Worth noting a few points here:

  • 虽然您的 LINQ 查询将保持不变,但您的配置会略有不同,并且需要注意端口跨度.
  • 了解 Solr 作为应用程序的工作原理以及架构的工作原理很重要,但那里有一些很棒的书籍和丰富的知识.
  • Solr 的分析器和评分机制略有不同(较新),因此您的搜索结果可能会略有不同(有时客户可能会对此感到震惊:P)

.. 但我认为这些是您可以随着时间的推移积累起来并与客户一起评估的东西.我相信这里还有更多要点,如果他们想到它们,其他人可以加入.希望这会有所帮助:)

.. but I think these are things you can build up to over time and assess with the customer. Im sure there are more points here and others can chime in if they think of them. Hope this helps :)

这篇关于什么时候在 Sitecore 7 构建中绝对使用 SOLR 而不是 Lucene?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-29 11:03
查看更多