Skip to content

Conversation

erfansaberi
Copy link
Contributor

Hi. I updated the description for the dynamic: false setting in the "Define explicit mapping" section of the Elasticsearch documentation.

Previously, the documentation stated:

Disables dynamic mapping for the index. Documents containing fields not defined in the mapping will be rejected.

This was misleading. In reality, when dynamic is set to false, fields not defined in the mapping are saved in the document but are not indexed or searchable. The document is still accepted.

The updated description now reads:

Disables dynamic mapping for the index. Fields not defined in the mapping will be saved but not indexed and not searchable.

This change aligns the documentation with Elasticsearch's actual behavior and clarifies the difference between false and strict values. If the intent is to reject documents that contain unmapped fields, the dynamic: strict setting should be used instead.

Copy link

cla-checker-service bot commented May 11, 2025

💚 CLA has been signed

@erfansaberi erfansaberi reopened this May 11, 2025
@bmorelli25 bmorelli25 closed this May 20, 2025
@bmorelli25 bmorelli25 reopened this May 20, 2025
@bmorelli25 bmorelli25 requested a review from a team as a code owner May 20, 2025 21:22
Copy link
Contributor

@leemthompo leemthompo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch, thanks for the fix @erfansaberi! I made one suggestion to help make your explanation more precise :)

@erfansaberi
Copy link
Contributor Author

erfansaberi commented May 21, 2025

Thanks for the great suggestion, @leemthompo — just applied it! The changes look ready to merge, but I don’t have access to merge it, please let me know if everything looks good or if I’m missing anything.

@leemthompo leemthompo enabled auto-merge (squash) May 27, 2025 14:56
@leemthompo leemthompo merged commit b4421f3 into elastic:main May 27, 2025
4 checks passed
@erfansaberi erfansaberi deleted the patch-1 branch May 31, 2025 17:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants