Skip to main content

One post tagged with "X-Definition"

View All Tags

Why we started writing KubeVela definitions in Go

· 30 min read
Vaibhav Agrawal
KubeVela Contributor

If you have written an X-Definition, you have written CUE. Components, traits, policies, and workflow steps all carry their logic as a CUE template, and that template is where your platform's real behaviour lives. It is what the KubeVela controller evaluates every time an Application renders. Change a definition and you change how every app on the platform gets delivered.

Which makes the authoring experience matter more than it first appears. A definition is some of the most consequential code a platform team writes, and it is written in a language most platform teams touch nowhere else. We felt that every time we added one, and eventually went looking for a different way to write them.

As of v1.11.0, KubeVela ships one. Defkit is a Go SDK for authoring X-Definitions: you write Go, and it compiles to CUE.