Replies: 5 comments 3 replies
-
+1 to increase compatibility and not break the API. A nice 1.0.1 patch release. |
Beta Was this translation helpful? Give feedback.
-
Same here, even though we need to make thorough tests to ensure downcast will not break other schema features, which I'm afraid it will |
Beta Was this translation helpful? Give feedback.
-
I created a branch with the modified schema (I also added a .json file to ease testing; it should be removed if/when we merge the branch): https://github.com/neuroglia-io/serverless-workflow-specification/tree/fix-allof-inheritance/schema Dear implementers, please let us know how this schema behaves for you. |
Beta Was this translation helpful? Give feedback.
-
@JBBianchi |
Beta Was this translation helpful? Give feedback.
-
Ok, I need to make the generator work with the branched schema. Once I have this, we can merge both at the same time (to minimize the window in which the java generator does not work on main) |
Beta Was this translation helpful? Give feedback.
-
Currently, we use a combination of
$ref
andproperties
to inherit from internal definitions, as described in this JSON Schema blog post.For example, each task inherits from
taskBase
, as shown in theset
task:I believe this approach relies on a feature introduced (or at least refined) in JSON Schema draft 2020-12. While this version is already a few years old, it is not yet widely supported by some tools. I have encountered compatibility issues in two different contexts:
A possible workaround would be to use
allOf
to inherit from a schema instead. For theset
task, this would look like:This change should not affect tools that already support the current approach but could improve compatibility—particularly with VS Code, which is required for draft PR.
Would this be an acceptable improvement for broader tool support? I'm curious to hear your thoughts!
Beta Was this translation helpful? Give feedback.
All reactions