Git Product home page Git Product logo

Comments (3)

iocanel avatar iocanel commented on July 30, 2024 1

I think that I need to provide a design document that contributors can consult and so that we can have a common base for our discussions.

from dekorate.

iocanel avatar iocanel commented on July 30, 2024

I am not familiar with the provided interfaces, but some of the patterns look pretty similar to what we have in place.

For instance we have the notion of generator which is really similar to a pipeline where it might register one or more visitors which enrich parts of the generated resources. So visitors seem to be the equivalent of a step?

In my mind the goal was to have generators 100% decoupled from:

  • the annotations
  • the underlying build tool
  • the annotation processor that trigger the generation

This is done using an approach that looks like this:

  1. Processor read the annotation from the code and creates/enriches an object that is called config, which encapsulates all the info collected from the annotations and the project.

  2. Each generator reacts to the configuration types it can handle. (e.g. KubernetesGenerator reacts to KubernetesConfig created from the KubernetesApplication annotation, while the SourceToImageGenerator reacts to SourceToImageConfig created by SourceToImage annotation).

  3. Each processor can react to any number of annotations and overlapping is permitted, So different processor can contribute the same config type. For example: The kubernetes annotation processor and the spring / thorntail processor all create/enrich the KubernetesConfig.

So we already have:

  • decoupling
  • reusability

Now regarding the Better document what is produced this is kind of subjective. The thing is that we don't have a 1 by 1 relationship of annotations and generated resources, as there are a lot more factors that come into the equation:

  • The project dependencies (is it kubernetes or openshift)
  • The project framework (have we found a known framework)
  • The combination of annotations and more.

from dekorate.

iocanel avatar iocanel commented on July 30, 2024

Now we have the design.md doc which explains the internal structure reasonably good.

from dekorate.

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.