Using YAML files to create and manage resources declaratively

Managing Decodable resources declaratively involves storing resource definitions in YAML files and applying them to create and manage connections, pipelines, streams, and secrets. By doing this, you can use standard development practices such as source control, which makes scripting Decodable workflows simpler.

Consolidating all resources for a specific workflow into a single file also simplifies management by removing the need to navigate through multiple UI elements. If you have multiple Decodable accounts, it is also easier to copy sets of resources between your accounts.

Applying a set of resources is idempotent and atomic: if anything goes wrong, no changes are made. If an apply succeeds, you can be sure that the new state is valid, and your Decodable resources are in sync with your YAML file(s). The apply command response indicates which resources were created, updated, or remained unchanged.

The following table outlines different use cases where Declarative (YAML) and the user interface (UI) are preferable.

Use Case Declarative (YAML) Decodable Web (UI)

Version control and collaboration

When changes need to be tracked, reviewed, and collaborated on efficiently.

For quick one-off changes or when version control is not a concern.

Perform atomic bulk operations

When managing multiple resources simultaneously or deploying across environments in bulk.

For individual resource management or ad-hoc changes.

Experimental changes

For enforcing consistent configurations across environments.

For quick prototyping or situations where flexibility is key.

Learning curve

For users familiar with YAML syntax and seeking more control and automation capabilities.

For users with limited technical expertise, time constraints, or who prefer a graphical interface.

Monitor user activity in your account

Maintain a log of user activity for bulk, atomic actions when used with source control and CI/CD.

The data reported in the _events and _metrics streams are sufficient for your audit and user log needs.

Prerequisites

You’ll need the Decodable CLI (version 1.12.0 or later). See the CLI Downloads page.

You should have a good understanding of Decodable resources and how they interact with each other. At a minimum, you should know that:

  • Connections connect Decodable to external systems, bringing data into or out of a Decodable stream.

  • Streams transport data within Decodable. When you create a connection, you are creating a link between an external resource and a Decodable stream.

  • Pipelines transform data within Decodable. For example, you can use a pipeline to filter and mask sensitive information before sending it downstream. Creating a pipeline is an optional step within the Decodable ecosystem, and not every workflow requires one.

  • Secrets store sensitive credentials. Any credentials required to establish a connection are securely stored as secrets. When configuring a connection, you reference the appropriate secret containing the necessary credentials for accessing the targeted system.

Get started

To get started with creating resources declaratively, see Using declarative definitions or Example: Create an Apache Kafka connection declaratively.