Closed wanddynosios closed 2 years ago
The json-schema
gem has been reverted to version 2.8.0. The link for JSON schema draft 6 is https://json-schema.org/draft-06/schema.
This change will be included in the next capi-release (CAPI 1.128.0).
Note: As a workaround, changing the JSON schema to "draft-4" should mitigate the problem (this is also the version guaranteed to work: "Platforms MUST support at least JSON Schema draft v4.").
Issue
After Upgrading to cf-deployment v17.1.0 (CAPI 1.123.0), our service-broker schemas (via AWS Servicebroker) which use json-schema draft-06 do not work anymore:
Context
CC has updated its json-schema gem to 2.8.1.
In this update, the gem has changed the syntax for the latest json-schema to "http://json-schema.org/draft/schema#". This was apparently because json-schema.org has released it in violation of the usual naming-scheme, and the gem adapted to that (see changelog).
json-schema.org later fixed that and named the schema in accordance to the scheme: "http://json-schema.org/draft-06/schema#". The "draft/schema#"-version is now undefined, as the link does not provide the schema. The gem however has not adapted to this change (since 2018).
To accommodate this change, CC has adapted the "wrong" naming scheme, so it is now pinned to an invalid version without any chance of upgrading.
Steps to Reproduce
Try to apply any service-schema with draft-06 (in CC 1.123.0)
Expected result
There is no breaking change and the apply works with draft-06 as before.
Current result
see above.
Possible Fix
I would suggest switching to another json-schema-validator, as per this suggestion.