Mapping APIs

In the last chapter, we learned about the document life cycle of Elasticsearch and executed single and multiple document APIs. We introduced a commission-free ETF from TD Ameritrade and used this information to practice document APIs. We also reindexed the documents from the multiple mapping types index for migration.

In this chapter, we are going to learn about mapping APIs. In Elasticsearch, mapping is a data model that describes the structure of a document. It allows you to specify fields, field types, relationships between documents, data conversion rules, and so on. Schema-less only means that documents can be indexed without specifying the schema in advance, because the schema is dynamically derived from the first document index structure based on the built-in mapping rules in Elasticsearch. If you have a good search database design plan, you should use explicit static mapping because dynamic mapping may not be perfect for your design. We will start with dynamic mapping first with a sample document and go through the different settings and variety. By the end of this chapter, you will have covered the following topics:

  • Dynamic mapping
  • Meta fields in mapping
  • Field datatypes
  • Mapping parameters
  • Refreshing mapping changes for static mapping
  • Typeless APIs working with old custom index types

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.119.167.248