Skip to content
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

[DOCS] Reuse multi-level join warning #82976

Merged
merged 1 commit into from
Jan 25, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions docs/reference/mapping/types/parent-join.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,14 @@ The `join` data type is a special field that creates
parent/child relation within documents of the same index.
The `relations` section defines a set of possible relations within the documents,
each relation being a parent name and a child name.

// tag::multi-level-join-warning[]
WARNING: We don't recommend using multiple levels of relations to replicate a
relational model. Each level of relation adds an overhead at query time in terms
of memory and computation. For better search performance, denormalize your data
instead.
// end::multi-level-join-warning[]

A parent/child relation can be defined as follows:

[source,console]
Expand Down Expand Up @@ -426,9 +434,7 @@ PUT my-index-000001

==== Multiple levels of parent join

WARNING: Using multiple levels of relations to replicate a relational model is not recommended.
Each level of relation adds an overhead at query time in terms of memory and computation.
You should de-normalize your data if you care about performance.
include::parent-join.asciidoc[tag=multi-level-join-warning]

Multiple levels of parent/child:

Expand Down