Skip to content

Let Composable implement the Composite design pattern. #81

Open
@vadimeisenbergibm

Description

@vadimeisenbergibm

It could be nice if Composable could implement the Composite design pattern https://en.wikipedia.org/wiki/Composite_pattern.

I want a construct similar to the Bundle concept in Juju. Take a look at the end of this short video https://vimeo.com/206253937/6530fa911d that shows at the end examples of software applications, packaged together as bundles.

The use case: I want to be able to compose a group of Kubernetes resources into logical units, that can be further composable into other logical units. Similar to primitive types and structs in a programming language, I want to be able to compose CRDs out of existing CRDs. Consider a "microservice" Composite: A Deployment, a Service, a Config Map and a Secret. I want to specify them in one CR, together with the dependencies between them. I want the operator to create the child CRs for me, handling the dependencies dynamically.

I want to be able to add properties to the Composite itself. And then I want to compose an application: a CR that will contain multiple CRs of multiple Microservices, and will handle the dependencies between them. Optionally, I may want to create the CRs in the topological order of the dependencies. And I want to allow any property to reference any property using YAML syntax (not the JSONPath as in the examples). The Operator could translate the YAML paths into JSON paths for me, or just query the CRs directly. Some CRs could be referenced CRs (not created by the operator, but created elsewhere and only referenced by the CR - the way the Composable operator operates today).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions