OptimumCode / json-schema-validator

The JSON schema validation library that works with https://github.com/Kotlin/kotlinx.serialization

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support remote schema loading

OptimumCode opened this issue · comments

The main JSON schema might reference other schemas. The library should provide the ability to provide those schemas.

From my point of view, this should be done in the following way:

  1. The json-schema-validator project should have an interface (e.g. SchemaProvider) that allows to resolve such schemas
  2. The json-schema-validator project should have a simple implementation that:
    1. Configured with pre-loaded schemas
    2. Provides those schemas by the URI
  3. Another project should be created (e.g. json-schema-remote-provider) and should contain an implementation that can load those schemas from the remote URI