{"id":5382,"date":"2018-09-27T03:20:46","date_gmt":"2018-09-27T03:20:46","guid":{"rendered":"https:\/\/www.devopsschool.com\/blog\/?p=5382"},"modified":"2025-05-04T06:08:22","modified_gmt":"2025-05-04T06:08:22","slug":"understanding-elasticsearch-keywords-and-terminology","status":"publish","type":"post","link":"https:\/\/www.devopsschool.com\/blog\/understanding-elasticsearch-keywords-and-terminology\/","title":{"rendered":"Understanding Elasticsearch Keywords and Terminology"},"content":{"rendered":"<p><a href=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/Elasticsearch-Keywords-and-Terminology.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5395\" src=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/Elasticsearch-Keywords-and-Terminology.jpg\" alt=\"\" width=\"638\" height=\"479\" srcset=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/Elasticsearch-Keywords-and-Terminology.jpg 638w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/Elasticsearch-Keywords-and-Terminology-300x225.jpg 300w\" sizes=\"auto, (max-width: 638px) 100vw, 638px\" \/><\/a><\/p>\n<p><strong>Understanding Elasticsearch Keywords and Terminology<\/strong><\/p>\n<table id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__ubaae077f-4c94-4bdc-bf3c-3d8240733aaa\" summary=\"List of Elasticsearch concepts and terminology essential for configuring Elasticsearch with PeopleSoft\">\n<thead>\n<tr id=\"\">\n<th id=\"d4198003e53\" scope=\"col\">\n<p id=\"\">Elasticsearch Terminology<\/p>\n<\/th>\n<th id=\"\" scope=\"col\">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u94da2319-c595-4a2d-bc26-429bdf98a7ea\">Description<\/p>\n<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr id=\"\">\n<th headers=\"d4198003e53 \" scope=\"row\">\n<p id=\"\">Cluster<\/p>\n<\/th>\n<td headers=\" \">\n<p id=\"\">\u201cA cluster is a collection of one or more nodes (servers) that together holds your entire data and provides federated indexing and search capabilities across all nodes. A cluster is identified by a unique name which by default is \u2018elasticsearch\u2019. This name is important because a node can only be part of a cluster if the node is set up to join the cluster by its name.\u201d<\/p>\n<p id=\"\">\u201cMake sure that you don\u2019t reuse the same cluster names in different environments, otherwise you might end up with nodes joining the wrong cluster. For instance you could use logging-dev, logging-stage, and logging-prod for the development, staging, and production clusters.\u201d<\/p>\n<\/td>\n<\/tr>\n<tr id=\"\">\n<th headers=\"d4198003e53 \" scope=\"row\">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__uadae837b-5db4-41f2-8565-a98de3bde4fe\">Node<\/p>\n<\/th>\n<td headers=\" \">\n<p id=\"\">\u201cA node is a single server that is part of your cluster, stores your data, and participates in the cluster\u2019s indexing and search capabilities. Just like a cluster, a node is identified by a name. You can define any node name you want if you do not want the default. This name is important for administration purposes where you want to identify which servers in your network correspond to which nodes in your Elasticsearch cluster.\u201d<\/p>\n<\/td>\n<\/tr>\n<tr id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u6ec258dd-1a4f-436d-a809-c72a82b6695f\">\n<th headers=\"d4198003e53 \" scope=\"row\">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u813f8c25-04ef-436e-be76-a144c9ce8501\">Index<\/p>\n<\/th>\n<td headers=\" \">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__uf817f9a6-be00-47c7-ac29-087176f7b695\">\u201cAn index is a collection of documents that have somewhat similar characteristics. In a single cluster, you can define as many indexes as you want.\u201d<\/p>\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__uc5304964-e703-45b4-b5d5-2dc9e22a9aa0\">An index is an equivalent of a relational database.<\/p>\n<\/td>\n<\/tr>\n<tr id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__uc9bdf2c8-bf9f-4429-8710-6137c66a908f\">\n<th headers=\"d4198003e53 \" scope=\"row\">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u79e26b8e-0acb-4dfd-94bb-a842c54fc13a\">Type<\/p>\n<\/th>\n<td headers=\" \">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u80f56b46-38c4-44f7-94ca-d59e764f56dd\">\u201cWithin an index, you can define one or more types. A type is a logical category\/partition of your index whose semantics is completely up to you. In general, a type is defined for documents that have a set of common fields.\u201d<\/p>\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u78a3482b-715a-4967-8354-47f4986358b5\">A type is an equivalent to a database table or view.Because Lucene, which Elasticsearch is built on, has no concept of document types, this is stored within an&nbsp;_type&nbsp;field. What happens internally is that&nbsp;when searching for a specific type of document, Elasticsearch applies a filter on this field.<\/p>\n<\/td>\n<\/tr>\n<tr id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__udce9ff47-a690-4f0c-ae70-591ae938df36\">\n<th headers=\"d4198003e53 \" scope=\"row\">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u85241b84-db8c-4bfd-9187-154807a01e84\">Alias<\/p>\n<\/th>\n<td headers=\" \">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__ua129b915-d2fd-4eee-b054-3c067b5f0d66\">Alias is a reference to an Elasticsearch index. An alias can be mapped to more than one index.<\/p>\n<\/td>\n<\/tr>\n<tr id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__udb62e5b7-97b6-4641-a00b-e05474639f6b\">\n<th headers=\"d4198003e53 \" scope=\"row\">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u20b96f66-d26c-4761-a89d-619290428301\">Document<\/p>\n<\/th>\n<td headers=\" \">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u0a2d3f59-c133-4ae3-92b9-2b2a48588626\">\u201cA document is a basic unit of information that can be indexed. This document is expressed in JavaScript Object Notation (JSON) format.\u201d<\/p>\n<p>A document is a basic unit of information that can be indexed. It consists of fields, which are key\/value pairs, where a value can be of various types, such as strings, dates, objects, etc. A document corresponds to an object in an object-oriented programming language, and a document type corresponds to a class. An example of a document could be a single user or product. Documents are expressed as JSON objects, and you can store as many documents within an index as you want.<\/p>\n<p>Now that we have walked through a few concepts, let\u2019s complete the analogy to relational databases. Where an index corresponds to a database and a type corresponds to a table, a document can be thought of as being the equivalent of a row in a database table. The fields of a document correspond to columns, and a mapping corresponds to the schema for a table.<\/td>\n<\/tr>\n<tr id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__ua5cccdd6-cbed-4add-ad2d-0c00cd1589d9\">\n<th headers=\"d4198003e53 \" scope=\"row\">\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u7841c5b4-6b01-45b4-9e90-e3db8fe8ee6b\">Shards and Replicas<\/p>\n<\/th>\n<td headers=\" \">\n<p id=\"\">\u201cElasticsearch provides the ability to subdivide your index into multiple pieces called shards. When you create an index, you can simply define the number of shards that you want. Each shard is in itself a fully-functional and independent \u2018index\u2019 that can be hosted on any node in the cluster.<\/p>\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__u9473edc9-a4fa-46cd-8f12-bfb81fcad046\">Elasticsearch allows you to make one or more copies of your index\u2019s shards into what are called replica shards, or replicas for short.<\/p>\n<p id=\"u41ee3d57-e8b3-4177-aae1-ca64d68f4505__ub593d93a-3bdf-42f6-8ebd-d593b0926c96\">After the index is created, you may change the number of replicas dynamically anytime but you cannot change the number of shards after-the-fact.\u201d<\/p>\n<\/td>\n<\/tr>\n<tr>\n<th headers=\"d4198003e53 \" scope=\"row\">Mappings<\/th>\n<td headers=\" \">A document type has a mapping that is similar to the schema of a table in a relational database. It describes the fields that a document of a given type may have along with their data types, such as string, integer, date, etc. Also included is information on how fields should be indexed and how they should be stored by Lucene. It is, however, optional if you wish to specify this.<\/p>\n<p>Thanks to dynamic mapping, it is optional to define a mapping before adding documents to an index. If no mapping is defined, it will be inferred automatically when a document is added, based on its data.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><a href=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/elastic-architecture-example-keywords-terminology.jpeg\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-5592\" src=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/elastic-architecture-example-keywords-terminology.jpeg\" alt=\"\" width=\"3536\" height=\"1920\" srcset=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/elastic-architecture-example-keywords-terminology.jpeg 3536w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/elastic-architecture-example-keywords-terminology-300x163.jpeg 300w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/elastic-architecture-example-keywords-terminology-768x417.jpeg 768w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/elastic-architecture-example-keywords-terminology-1024x556.jpeg 1024w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2018\/09\/elastic-architecture-example-keywords-terminology-660x358.jpeg 660w\" sizes=\"auto, (max-width: 3536px) 100vw, 3536px\" \/><\/a><\/p>\n<p><strong>Reference<\/strong><\/p>\n<ol>\n<li>https:\/\/www.elastic.co\/guide\/en\/elastic-stack-glossary\/current\/terms.html<\/li>\n<li>https:\/\/www.elastic.co\/guide\/en\/elasticsearch\/reference\/current\/glossary.html<\/li>\n<li>https:\/\/www.elastic.co\/guide\/en\/elasticsearch\/reference\/current\/_basic_concepts.html<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>Understanding Elasticsearch Keywords and Terminology Elasticsearch Terminology Description Cluster \u201cA cluster is a collection of one or more nodes (servers) that together holds your entire data and provides federated indexing and search capabilities across all nodes. A cluster is identified by a unique name which by default is \u2018elasticsearch\u2019. This name is important because a&#8230;<\/p>\n","protected":false},"author":1,"featured_media":8189,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_kad_post_transparent":"","_kad_post_title":"","_kad_post_layout":"","_kad_post_sidebar_id":"","_kad_post_content_style":"","_kad_post_vertical_padding":"","_kad_post_feature":"","_kad_post_feature_position":"","_kad_post_header":false,"_kad_post_footer":false,"_kad_post_classname":"","_joinchat":[],"footnotes":""},"categories":[5936],"tags":[4666,5064,1629],"class_list":["post-5382","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-elastic","tag-elasticsearch","tag-keywords","tag-terminology"],"_links":{"self":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/5382","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/comments?post=5382"}],"version-history":[{"count":5,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/5382\/revisions"}],"predecessor-version":[{"id":8190,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/5382\/revisions\/8190"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/media\/8189"}],"wp:attachment":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/media?parent=5382"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/categories?post=5382"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/tags?post=5382"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}