Skip to content

docs(db-mongodb): note on indexing localized fields & per-locale growth #13469

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 19, 2025

Conversation

chenxi-debugger
Copy link
Contributor

Closes #13464

Adds a note to the Indexes docs for localized fields:

  • Indexing a localized: true field creates one index per locale path (e.g. slug.en, slug.da-dk), which can grow index count on MongoDB.
  • Recommends defining explicit indexes via collection-level indexes for only the locale paths you actually query.
  • Includes a concrete example (index slug.en only).

Docs-only change.

DanRibbens
DanRibbens previously approved these changes Aug 14, 2025
Copy link
Contributor

@DanRibbens DanRibbens left a comment

Choose a reason for hiding this comment

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

Thanks for the PR!

GermanJablo

This comment was marked as resolved.

@GermanJablo GermanJablo enabled auto-merge (squash) August 19, 2025 12:41
@GermanJablo GermanJablo changed the title docs(db-mongodb): note on indexing localized fields & per-locale growth (closes #13464) docs(db-mongodb): note on indexing localized fields & per-locale growth Aug 19, 2025
@GermanJablo GermanJablo merged commit 379ef87 into payloadcms:main Aug 19, 2025
15 checks passed
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.

Localized text field with index/unique creates one index per locale
3 participants