Code Monkey home page Code Monkey logo

Comments (4)

elanv avatar elanv commented on July 3, 2024 1

Do you mean pruning function?
If so, since version 1.15 it seems to be supported by k8s apiserver.

note: https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/#pruning-versus-preserving-unknown-fields

I tested this feature in 1.15, but there were another problem. controller-tools included in kubebuilder is not able to create a "structural schema" intact. To use the pruning feature, the openapi validation schema must be defined as "structural schema". There are two issues with structural schema that are problematic.

kubernetes-sigs/controller-tools#304 (resolved recently)
kubernetes-sigs/controller-tools#279

from flink-on-k8s-operator.

elanv avatar elanv commented on July 3, 2024 1

controller-tools 0.2.4 included in kubebuilder v2.2.0 supports the generation of CRD V1 and structural schema, which allows you to use preserveUnknownFields. If you are using k8s 1.15 this issue seems to be resolved.

I have tested generating CRD with controller-tools 0.2.4, deploying CRD to k8s 1.15 cluster and deploying CR with unknown field, and api-server-validation works well.

from flink-on-k8s-operator.

functicons avatar functicons commented on July 3, 2024

This doesn't seem to be supported by Kubebuilder kubernetes-sigs/kubebuilder#1174. Still not aware of how to solve it.

from flink-on-k8s-operator.

functicons avatar functicons commented on July 3, 2024

Thanks, will check!

from flink-on-k8s-operator.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.