Skip to content

F json schema datamodel

Florian Spreckelsen requested to merge f-json-schema-datamodel into dev

Summary

For https://gitlab.indiscale.com/caosdb/customers/leibniz-zmt/management/-/issues/17 and https://gitlab.indiscale.com/caosdb/customers/leibniz-zmt/management/-/issues/24. A rudimentary parser of datamodels defined in json-schemas is introduced. It is sufficient to create flat datamodels, but it still lacks a lot.

  • inheritance: This will probably require an extension of datamodel itself, so we won't implement it
  • suggested properties: ditto
  • $defs and $ref in json schema
  • Re-use of already defined RTs or Poroperties as List properties
  • Reference properties that are different from the referenced RT. (Although this is possible for list of references)
  • Values
  • The extern keyword from the yaml parser
  • Documentation

Focus

Mainly, a new parser has been introduced. Most changes are actually tests for the new parser.

Test Environment

In principle, the new unit tests and the new integration test are sufficient. You can also use Joscha's ZMT model to verify that the parser actually fulfills the minimal requirement of creating a datamodel for exactly this schema.

Check List for the Author

Please, prepare your MR for a review. Be sure to write a summary and a focus and create gitlab comments for the reviewer. They should guide the reviewer through the changes, explain your changes and also point out open questions. For further good practices have a look at our review guidelines

  • All automated tests pass
  • Reference related Issues
  • Up-to-date CHANGELOG.md
  • Annotations in code (Gitlab comments)
    • Intent of new code
    • Problems with old code
    • Why this implementation?

Check List for the Reviewer

  • I understand the intent of this MR
  • All automated tests pass
  • Up-to-date CHANGELOG.md
  • The test environment setup works and the intended behavior is reproducible in the test environment
  • In-code documentation and comments are up-to-date.
  • Check: Are there spezifications? Are they satisfied?

For further good practices have a look at our review guidelines.

Edited by Timm Fitschen

Merge request reports

Loading