Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenAPI: Validation schemas #6145

Open
manusa opened this issue Jul 17, 2024 · 1 comment
Open

OpenAPI: Validation schemas #6145

manusa opened this issue Jul 17, 2024 · 1 comment
Labels
Milestone

Comments

@manusa
Copy link
Member

manusa commented Jul 17, 2024

Description

Part of #6130

The legacy model generation approach using Go had as its main outcome the kube-schema.json and validation-schema.json files.

The purpose of the kube-schema.json file was to serve as the base spec for the jsonschema2pojo process to generate the resulting Java types.

Both files were added to the respective kubernetes-model-xxx artifact and made available downstream.

We don't have any record of a project taking advantage of the kube-schema.json artifact being consumed downstream (some parsers won't even load it). Is there anyone using this?

We do have notion of Eclipse JKube consuming the validation-schena.json file. This was originally implemented ad-hoc for this project (fabric8io/kubernetes-model#229, fabric8io/fabric8-maven-plugin#1029, fabric8io/fabric8-maven-plugin#66).

However, this file is not standard and uses some nasty workarounds for the validations. It also uses the Kubernetes object Kind as the identifier for the validation schema which is an issue if two resources share the same kind but belong to different groups (apiVersion).

As part of the new Model Generation approach, we need to replace this functionality in both projects.

Tasks

  • Output a validation JSON schema (or alternative) that can be consumed by any project (if possible)
  • Replace the ResourceValidator logic in Eclipse JKube to take advantage of the new schema or methodology

Original issues

@manusa manusa added the component/kubernetes-model Deals with the kubernetes-model label Jul 17, 2024
@manusa manusa added this to the 7.0.0 milestone Jul 17, 2024
Copy link

stale bot commented Oct 19, 2024

This issue has been automatically marked as stale because it has not had any activity since 90 days. It will be closed if no further activity occurs within 7 days. Thank you for your contributions!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant