Open simonharrer opened 8 months ago
Hi, As promised in our previous conversation, here are some thoughts on this topic:
datacontract-cli
is a reasonable candidate for such functionality.models
section needs its own clear and stable specification, because it in fact becomes a DSL within already existing overall Data Contracts specification.I would not have models and schema, it will lead to contradictions between the two quite quickly if people are not careful. Either that or the validation tooling needs to ensure that each entity in one matches the other. I think import / export tooling is a much better idea.
Would it be possible to remove schema but retaining the flexibility via the tooling by allowing for further customization of Server
types?
Import/Export tooling can replicate the flexibility of schema
while keeping the clarity of logical data models, by customizing application of the Model
based on the Server
. However with Schema
now gone (and I support @pixie79 in not having both), there's no longer a way to explicitly contract on the resulting schema if the Server type isn't supported by the specification and the datacontract-cli
.
See: https://github.com/datacontract/datacontract-cli/issues/416
Status Quo
There is the top-level element
schema
that references a technical schema like SQL, BigQuery, Avro, JsonSchema, etc.Motivation
We introduced the top-level element
models
that encodes an abstract, high-level version of the data model. Mappingmodels
to the technical schema, and back, is being implemented in tooling like the Data Contract CLI (cli.datacontract.com).Proposal
Mark
schema
as deprecated for the next version and remove it in the version after that.Alternatives
schema
and see what users will do with it.