-
Notifications
You must be signed in to change notification settings - Fork 218
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
Update existing Rich Schema RFCs; Propose RFCs for Rich Schema's Mapping and CredDef #446
Conversation
ashcherbakov
commented
Mar 16, 2020
- Update existing Rich Schema RFCs according to the Rich Schema Common RFC;
- Propose RFCs for Rich Schema's Mapping and CredDef according to the Rich Schema Common RFC
… according to the Common one. Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
…RFC. Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
…Schema Common RFC. Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
@dhh1128 @brentzundel Can you please review? |
If a Rich Schema object is a JSON-LD object, the `content`'s `@id` field must be equal to the `id`. | ||
|
||
The only thing that we currently expect from json-ld processing is substitution of attributes by a fully-qualified ones. | ||
We may assume that contexts belonging to the current ledger only |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm curious to understand this a bit better. Does this mean that all contexts necessary to build and map a rich schema must be on the same ledger? Would this hold true for the use of schemas that are anchored in IPFS that sit alongside an IPFS implementation. If this is true, then does that mean that different implementations of sidetree could reuse contexts from "different registries"?
While I understand this question is a bit futuristic sounding, the main reason I ask is because it makes sense to design in a way that aligns with securekey's architecture which using sidetree with Fabric. For rich schemas, they wouldn't necessarily have to anchor them using the batch files in sidetree, and instead could use IPFS for this functionality.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have this assumption in Indy, where we assume all Schemas and corresponding Contexts should be on the same Ledger. BTW this assumption in Indy may be for the first MVP implementation of Rich Schema feature only.
As for the Aries side, I think I will remove this assumption.
@@ -10,10 +10,14 @@ | |||
## Summary | |||
[summary]: #summary | |||
|
|||
Every rich schema object has an associated `@context`. Contexts are JSON-LD | |||
Every rich schema object may have an associated `@context`. Contexts are JSON or JSON-LD |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How will it be known if it's a JSON vs JSON-LD object? For example, if the context is anchored in JSON-LD form, then it's acceptable that the context is IRIs that are expanded by the document loader. In the case of a JSON consumer though, I'm not certain how they would receive the necessary detail to handle processing of an IRI. Could we provide additional details on this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any Rich Schema (which is a JSON-LD object) may reference Contexts by their id
. The Context's content can be used then for substituting the attributes with IRIs within the Rich Schema object.
The question is whether the Context's content itself must be a JSON-LD as well.
As I can see from https://json-ld.org/spec/latest/json-ld/#the-context, it's not.
And as I can see from the example of Contexts that we have (@brentzundel can correct me if I'm wrong), the only requirement for the Context's format is to have a @context
property containing a map of terms to IRIs. A Context may not have @id
and @type
properties expecting from any JSON_LD object.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My understanding of the @context
objects is that simple ones are JSON objects, but there may be more advanced options that require JSON-LD.
It may be a moot question though, because the object that has a @context
is a JSON-LD object and and processing that object will include dealing with the @context
. I think its safe to assume that a JSON-LD processor will know how to deal with @context
objects.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh good points. Thanks for the clarifications
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a few questions from me at this point
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
…3C credential spec to be present in the Mapping Signed-off-by: ashcherbakov <alexander.sherbakov@dsr-corporation.com>
I'm cheerful about merging this, if others are. |
Yup looks fine from my perspective. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The questions that Kyle asked have been resolved to his satisfaction. My own review is that this looks like a reasonable improvement. I recommend that we merge.
Signed-off-by: Daniel Hardman <daniel.hardman@gmail.com>