4 ms·
Sure it's easy to make HTTP requests to an HTTP REST-like API. That's not the complexity. Look at the data structures, how many fields a simple thing like a Pod
by kissgyorgy 6y ago
Sure it's easy to make HTTP requests to an HTTP REST-like API. That's not the complexity. Look at the data structures, how many fields a simple thing like a Pod have. It's actually insanely complex, and if you are using Kubernetes, you have to understand most of them.
The author show the structure of every endpoint:
/api/[version]/namespaces/[namespace]/[resource]/[name]
How is that simple?
- fierro 6y agonot sure how anything more simple would be useful. We aren't writing Hello Worlds here.
- qbasic_forever 6y agoLook at what Kubernetes can do... it's beyond even an operating system, it's like if systemd controlled a whole datacenter. It handles everything too--networking, storage, processes, jobs, etc. Of course that's going to be a complex thing with a large surface area. The fact you can just curl into the API server with a consistent and discoverable (all OpenAPI) API is pretty darn amazing.
- takeda 6y ago> Look at what Kubernetes can do... With such criteria even a passenger jet is simple.
- wutbrodo 6y agoThe claim was that the _API_ is simple relative to the system's capabilities, including being discoverable and standardized (w openapi). If passenger jets had a comparable API you could use to ramp up to the level of competence that you can on k8s, that would be pretty amazing.
- matt-attack 6y agoWhat is a discoverable API?
- aliswe 6y agoI guess this means that you're able to learn how the API works by using the API to download metadata. In fact, one can generate a complete API client by pointing a script to a running kubernetes instance, which will generate all code for interacting with exactly that version. And the resulting client is huuuge. (That generation thingy is for some .net clients)
- qbasic_forever 6y agoThere's a full open API schema served by the API server. Tools can read it and build specific interfaces or validate requests before even sending them. And in general k8s is really just a big database of objects. Once you learn the core objects like pod, deployment, service, etc. it becomes very natural to interact with anything else--just find what object it is and interact with its attributes.
- echelon 6y agoThat's remarkably easy to understand and encodes all of the things you can do in the k8s universe. Deployments, Pods, CronJobs, Services, Secrets... Every type of resource. Ignoring the version, that's just three nouns you need to know and you're good to go. Pretty damned simple.
- brown9-2 6y agoThere is simplicity in knowing that if you know how to fetch one type of resource, you can learn how to fetch them all.