Tagged: Code

Web-Powered Workflows: Fetching and Running Digdag Workflows with Callbacks

Web-Powered Workflows: Fetching and Running Digdag Workflows with Callbacks

In Digdag, workflows are typically defined in YAML files with a “.dig” extension. Developers usually write these workflows, which consist of tasks to be executed. However, tasks can also be added dynamically using the Digdag Python API or by downloading a “.dig” file from a remote HTTP server and incorporating it as a subtask. This approach is useful when a web service or app generates customized workflow files based on web app conditions, allowing the workflow logic to be managed externally. You can add webhooks to make it reactive.

Simple CGI programming

A simple HTTP server serves static HTML, Javascript, CSS, Images, etc. Sometimes you need a bit of dynamic content from the server-side. There are simple microframeworks to mega frameworks to achieve this. You could use any of these available web frameworks on the server side. But let’s say you don’t have access to any of those frameworks, and you want it to be simple and lightweight. You could try CGI.

Or you are just a web geek and want to spend an hour on old but interesting technology.