From 96fd707ed81d143854bf5b173f818449a551cba5 Mon Sep 17 00:00:00 2001 From: Lucas Hosseini Date: Wed, 27 Apr 2016 02:52:51 +0200 Subject: [PATCH 1/3] Clarify full linkage. --- _format/1.0/index.md | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/_format/1.0/index.md b/_format/1.0/index.md index 08469236d..c9697064e 100644 --- a/_format/1.0/index.md +++ b/_format/1.0/index.md @@ -377,17 +377,19 @@ In a compound document, all included resources **MUST** be represented as an array of [resource objects] in a top-level `included` member. Compound documents require "full linkage", meaning that every included -resource **MUST** be identified by at least one [resource identifier object] -in the same document. These resource identifier objects could either be -primary data or represent resource linkage contained within primary or -included resources. +resource **MUST** be identified by at least one [resource identifier object] in +the same document, representing resource linkage contained within an +*accessible* resource object. A resource object is *accessible* if it is either +primary data or it is identified by at least one [resource identifier object] in +the same document, representing resource linkage contained within an +*accessible* resource object. The only exception to the full linkage requirement is when relationship fields that would otherwise contain linkage data are excluded via [sparse fieldsets](#fetching-sparse-fieldsets). -> Note: Full linkage ensures that included resources are related to either -the primary data (which could be [resource objects] or [resource identifier -objects][resource identifier object]) or to each other. +> Note: Full linkage ensures that included resources are related (directly or +indirectly) to the primary data (which could be [resource objects] or [resource identifier +objects][resource identifier object]). A complete example document with multiple included relationships: From b1adfe8bc270dd1adbb18d563f127d22b4334cc8 Mon Sep 17 00:00:00 2001 From: Jeldrik Hanschke Date: Sat, 20 Feb 2021 20:09:42 +0100 Subject: [PATCH 2/3] target v1.1 and improve wording --- _format/1.0/index.md | 16 +++++++--------- _format/1.1/index.md | 15 +++++++++------ 2 files changed, 16 insertions(+), 15 deletions(-) diff --git a/_format/1.0/index.md b/_format/1.0/index.md index c9697064e..08469236d 100644 --- a/_format/1.0/index.md +++ b/_format/1.0/index.md @@ -377,19 +377,17 @@ In a compound document, all included resources **MUST** be represented as an array of [resource objects] in a top-level `included` member. Compound documents require "full linkage", meaning that every included -resource **MUST** be identified by at least one [resource identifier object] in -the same document, representing resource linkage contained within an -*accessible* resource object. A resource object is *accessible* if it is either -primary data or it is identified by at least one [resource identifier object] in -the same document, representing resource linkage contained within an -*accessible* resource object. +resource **MUST** be identified by at least one [resource identifier object] +in the same document. These resource identifier objects could either be +primary data or represent resource linkage contained within primary or +included resources. The only exception to the full linkage requirement is when relationship fields that would otherwise contain linkage data are excluded via [sparse fieldsets](#fetching-sparse-fieldsets). -> Note: Full linkage ensures that included resources are related (directly or -indirectly) to the primary data (which could be [resource objects] or [resource identifier -objects][resource identifier object]). +> Note: Full linkage ensures that included resources are related to either +the primary data (which could be [resource objects] or [resource identifier +objects][resource identifier object]) or to each other. A complete example document with multiple included relationships: diff --git a/_format/1.1/index.md b/_format/1.1/index.md index 76eca14ce..cb63dfa3f 100644 --- a/_format/1.1/index.md +++ b/_format/1.1/index.md @@ -609,16 +609,19 @@ array of [resource objects] in a top-level `included` member. Compound documents require "full linkage", meaning that every included resource **MUST** be identified by at least one [resource identifier object] -in the same document. These resource identifier objects could either be -primary data or represent resource linkage contained within primary or -included resources. +in the same document. This resource identifier object could either be +primary data or represent resource linkage contained within an accessible +resource. A resource is accessible if it is included in the same document +as primary data or if it is identified by a resource identifier object +in primary data or represents resource linkage contained within an accessible +resource. The only exception to the full linkage requirement is when relationship fields that would otherwise contain linkage data are excluded via [sparse fieldsets](#fetching-sparse-fieldsets). -> Note: Full linkage ensures that included resources are related to either -the primary data (which could be [resource objects] or [resource identifier -objects][resource identifier object]) or to each other. +> Note: Full linkage ensures that included resources are related (directly +or indirectly) to the primary data (which could be [resource objects] or +[resource identifier objects][resource identifier object]). A complete example document with multiple included relationships: From 6ff1fbf1ef1a54eefbd649547e8a95d608209999 Mon Sep 17 00:00:00 2001 From: Jeldrik Hanschke Date: Fri, 16 Apr 2021 19:13:28 +0200 Subject: [PATCH 3/3] Update with Gabe Sullice's proposal --- _format/1.1/index.md | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/_format/1.1/index.md b/_format/1.1/index.md index cb63dfa3f..34877ce28 100644 --- a/_format/1.1/index.md +++ b/_format/1.1/index.md @@ -607,22 +607,15 @@ requested primary resources. Such responses are called "compound documents". In a compound document, all included resources **MUST** be represented as an array of [resource objects] in a top-level `included` member. -Compound documents require "full linkage", meaning that every included -resource **MUST** be identified by at least one [resource identifier object] -in the same document. This resource identifier object could either be -primary data or represent resource linkage contained within an accessible -resource. A resource is accessible if it is included in the same document -as primary data or if it is identified by a resource identifier object -in primary data or represents resource linkage contained within an accessible -resource. +Every included resource object **MUST** be identified via a chain of +relationships originating in a document's primary data. This means that +compound documents require "full linkage" and that no resource object can be +included without a direct or indirect relationship to the document's primary +data. The only exception to the full linkage requirement is when relationship fields that would otherwise contain linkage data are excluded via [sparse fieldsets](#fetching-sparse-fieldsets). -> Note: Full linkage ensures that included resources are related (directly -or indirectly) to the primary data (which could be [resource objects] or -[resource identifier objects][resource identifier object]). - A complete example document with multiple included relationships: ```json