DOT (Graphviz) rendering for Choreo.Dataflow pipeline diagrams.
Produces dataflow-oriented visualisation:
- Sources — house shape (data enters)
- Sinks — inverted house (data exits)
- Transforms — 3D boxes (processing)
- Buffers — cylinders (queues / topics)
- Conditionals — diamonds (branching decisions)
- Merges — trapezium (joining streams)
Edge styles:
- Normal — solid grey
- Error — dashed red
- Retry — dotted orange
- Dead letter — dashed grey
Layout is left-to-right by default so data flows from left to right. Clusters are rendered as bounded rectangles with optional fill colours.
Further reading
Summary
Functions
Renders a dataflow to a DOT string.
Functions
@spec to_dot( Choreo.Dataflow.t(), keyword() ) :: String.t()
Renders a dataflow to a DOT string.
Options
:theme—:default,:dark, or aChoreo.Themestruct
Examples
iex> flow = Choreo.Dataflow.new()
iex> flow = flow
...> |> Choreo.Dataflow.add_source(:in, label: "Input")
...> |> Choreo.Dataflow.add_transform(:proc, label: "Process")
...> |> Choreo.Dataflow.add_sink(:out, label: "Output")
...> |> Choreo.Dataflow.connect(:in, :proc, data_type: "raw")
...> |> Choreo.Dataflow.connect(:proc, :out, data_type: "result")
iex> dot = Choreo.Dataflow.Render.DOT.to_dot(flow)
iex> String.contains?(dot, "digraph")
true
iex> String.contains?(dot, "Input")
true
iex> String.contains?(dot, "Output")
true