# 模块

原文链接 : [https://www.elastic.co/guide/en/elasticsearch/reference/current/modules.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules.html)

译文链接 : [http://www.apache.wiki/display/Elasticsearch/Modules](http://www.apache.wiki/display/Elasticsearch/Modules)

贡献者 : [阿叩](/display/~luanqing)，[ApacheCN](/display/~apachecn)，[Apache中文网](/display/~apachechina)

MarkDown文件：[Modules.md](https://github.com/aqlu/elasticsearch_translate/blob/master/Modules.md)

## 模块

本章节负责介绍Elasticsearch包含的各个模块的功能，每个模块的配置都可以通过如下方式进行配置：

_静态的_ 

  _这些配置项必须基于节点来进行设置，在启动节点前可以通过`elasticsearch.yml`配置文件、环境变量、命令行参数方式来进行配置。他们必须明确地在集群中的每个节点上进行设置。_

_动态的_ 

  _这些配置可以通过群集的[cluster-update-settings](https://www.elastic.co/guide/en/elasticsearch/reference/current/cluster-update-settings.html) API进行动态更新。_

本节介绍的模块有：

[Cluster-level routing and shard allocation（集群级别的路由与分片分配）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-cluster.html)）

  _用来控制在何处、何时、以及如何给节点分配分片。_

[Discovery（发现）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-discovery.html)

  构成一个_集群的节点彼此之间是如何发现的。_

[Gateway（网关）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-gateway.html)

  _集群启动恢复前需要多少个节点加入。_

[HTTP](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-http.html)

  _用来控制配置`HTTP REST`接口。_

[Indices（索引）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-indices.html)

  _所有跟索引相关的设置。_

[Network（网络）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-network.html)

  _控制默认的网络设置。_

[Node client（节点客户端）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-node.html)

  _一个加入集群的Java客户端节点，但不能保存数据或作为主节点。_

[Painless](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-scripting-painless.html)

  _Elasticsearch内置的脚本语言，遵循尽可能的安全设计。_

[Plugins（插件）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-plugins.html)

  _通过插件来扩展Elasticsearch的功能。_

[Scripting（脚本）](/pages/viewpage.action?pageId=4260408)

  _通过Lucene表达式、Groovy、Python、以及Javascript来自定义脚本。你也可以使用内置的脚本语言[Painless](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-scripting-painless.html)。_

[Snapshot/Restore（快照/还原）](/pages/viewpage.action?pageId=9405386)

  _通过快照与还原模块来备份你的数据。_

[Thread pools（线程池）](/pages/viewpage.action?pageId=9405389)

  _Elasticsearch专用的线程池的信息。_

[Transport（传输）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-transport.html)

  _Elasticsearch内部各节点之间的网络传输层通信配置。_

[Tribe nodes](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-tribe.html)

  _Tribe节点能加入一个或多个集群，并作为它们之间的联合客户端。_

[Cross cluster Search（跨集群搜索）](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-cross-cluster-search.html)

  _跨集群搜索功能可以通过一个不加入集群、并且能作为它们之间的联合客户端来实现一个以上集群的搜索。_