Skip to content

Basic helpers and tasks for building a controller

Hossein Pursultani requested to merge add-basic-controller-helpers into main

🔵 This MR is based on !16 (closed) breakdown. These changes are tested in the broader context of !16 (closed).

This MR is based on !19 (merged), !18 (merged) and !17 (merged). Do not merge it before !19 (merged).

This MR must be rebased after merging !19 (merged).

What does this MR do?

This change includes Task interface and a few implementations, including:

  • ApplyObjects: Runs ApplyObject function on a list of Objects.
  • Dereference: Loads Objects of type T that are referenced in a source Object of type S. For example all Secrets that are referenced in GitLab. It uses a Reference interface to locate the referenced Object.
  • GetObjects: Returns a list of Objects of type T that are specified with in the list of qualified names.
  • RenderTempaltes: Renders the specified templates with the given data.

Author's Checklist

For anything in this list which will not be completed, please provide a reason in the MR discussion.

Required

  • Ensure a release milestone is set.
  • MR title and description are up to date, accurate, and descriptive.
  • MR targeting the appropriate branch.
  • MR has a green pipeline on GitLab.com.
  • When ready for review, MR is labeled workflowready for review per the MR workflow.

Expected

  • Test plan indicating conditions for success has been posted and passes.
  • Documentation is created or updated.
  • Tests are added.

Related issues

Related to #2 (closed)

Edited by Hossein Pursultani

Merge request reports