Loops and subflows in Shuffle for large alert lists

Choosing between in-workflow loops, Filter List and subflows for large alert batches in Shuffle, and what each choice does to memory, run time, parallelism and app-run counts.

On this page

How to process large alert lists in Shuffle without slowing every playbook

A SOC team whose playbook stalls when a SIEM sends hundreds of alerts at once usually has a structure problem before it has a capacity problem. The fix is choosing the right loop structure before the playbook grows. Three options matter here: a loop over the list inside the parent workflow, the Filter List action, and a subflow, which is a separate workflow that a parent workflow calls. Each does a different job. A loop repeats steps for each item in a list. Filter List narrows a list by condition so fewer items reach later steps. A subflow packages a sequence of steps so the parent can call it, and it can be reused across playbooks. Before you commit to a design, confirm in the current Shuffle docs how each option behaves with very large inputs, since the documentation you need to check for item limits and nesting depth is the source of truth for your version.

Loop placement also drives cost, because Shuffle licensing is measured in app runs, meaning actions that actually execute. Triggers and skipped actions are not counted, according to the Shuffle pricing article. A loop that calls an enrichment app for every alert multiplies executed app runs by the alert count. If a Filter List step comes first, only matching items reach the enrichment step. As an illustrative example, 500 alerts with 80 matching a severity condition would mean roughly 80 enrichment runs instead of 500. Ask your team to count executed app runs for a representative batch on your own instance before choosing a design, and confirm how your edition meters runs for your expected volume.

Which structure fits which alert batch

Shuffle offers three ways to handle many items in one playbook, and each one changes how many app runs you consume, how long the run takes and how much work sits in a single execution. The cards below cover when each structure fits, which documented billing and runtime rules affect it, and what to check before you choose.

Small fixed lists

A plain in-workflow loop suits a short, known set of items, such as the few hashes or addresses pulled from one alert. Every action inside the loop body that executes counts as an app run, so each enrichment step is repeated for every item. Keep the loop body small, and check the execution details to confirm how many actions ran for a typical alert.

Filter before processing

Filter List removes items that need no work, such as duplicates or hosts already on an allowlist, before any enrichment app runs. Shuffle's licensing counts only actions that actually execute, and skipped actions are not counted, so early filtering ties billed runs to real work. Test your filter conditions on a sample batch, because a wrong condition can drop alerts without an obvious error.

Shuffle pricing article

Reusable per-item logic

A subflow packages the steps you run for each item, such as a lookup followed by a ticket update, and the parent playbook calls it once per item. This keeps the parent readable and gives you one place to fix the logic for every batch. Before you multiply a subflow across a large list, confirm in the Shuffle documentation how each subflow call appears in execution details and in app-run counts.

Very large batches

When a batch is large enough to strain one execution, split it into chunks and start one run per chunk, or run the playbook once per alert. In Shuffle's architecture, Orborus starts one worker for each workflow execution, and that worker starts the app containers, so memory and time are spent there. Test the largest batch you expect, watch worker resources, and set the chunk size from those results.

Shuffle architecture docs

Parallelism and runtime capacity

How much work runs in parallel depends on how many Orborus nodes run and how the runtime is deployed. A loop that finishes quickly on a single test server can queue behind other executions on a shared runtime. Shuffle's high availability guidance recommends more than one Orborus node so workflows keep running if one fails, so ask your team to confirm the concurrency settings for your runtime before you set a batch window.

Measure before committing

Before you choose a structure for production, run a representative batch in staging and record the run time, the number of actions executed and the app runs used. Compare those figures with your expected alert volume to see which structure keeps run time and app-run counts within your targets. Repeat the test after any change to the loop body, because an added enrichment step multiplies across every item.

Loop, Filter List and subflow options compared

This table compares the loop, Filter List, subflow and worker settings that shape how a playbook handles many items. Read each row against your alert volume, and use the last column as your checklist before you test in your own version.

OptionWhat it does and when it fitsEffect on app runs and parallelismWhat to confirm in your version
In-workflow loopRuns the same actions once per list item inside one execution. Fits short lists where each step needs the previous result.Each executed action counts as an app run, so run count grows with list length. Parallelism depends on the loop's concurrency behavior.Whether iterations run in parallel or in sequence, and any item limit in the loop settings.
Loop concurrency or item limitCaps how many iterations run at once. Fits large lists that call rate-limited APIs.Lowers peak parallel app containers. Total app runs for the same items should stay the same.Whether the setting exists, where it sits in the loop node, and its default value.
Filter List actionReduces a list using conditions before later steps. Fits triage that drops duplicates, closed or low-priority alerts.The filter itself is one step. Fewer items downstream means fewer later app runs.Whether the filter step counts as an app run in your edition and how it handles nested fields.
Filter conditionsKeeps only items matching field comparisons such as equals or contains. Fits narrowing alerts before enrichment.Filtering before the loop is usually the cheapest way to lower app runs, since skipped actions are not counted.Operator behavior on your real alert JSON, including items where the field is missing or empty.
Subflow inputPasses chosen values from a parent workflow to a child workflow. Fits enrichment logic reused across playbooks.Each subflow run is its own execution, and its actions count as app runs in addition to the parent's.Whether a single item or a whole list can be passed, and the input size limits.
Subflow output handlingReturns child results to the parent for branching. Fits a parent that needs an enrichment verdict before acting.Output handling adds steps for each call. Calls repeated inside a parent loop multiply that overhead.How the parent waits for the child, and where child failures appear in the parent execution.
Subflow per itemStarts one child execution for each list item. Fits cases needing separate logs and retries per item.Highest parallelism and overhead, with many executions per batch.Any limit on concurrent executions and how to track child runs in the executions view.
Orborus worker capacityThe runtime starts a worker for each execution and the app containers it needs. This sets the ceiling on parallel loops and subflows.Parallelism is capped by available runtime capacity, not only by playbook design.Orborus concurrency settings, the number of Orborus nodes, and the capacity of each runtime location.

How app runs change what a large batch costs

Shuffle prices its paid tiers on one metric, app runs, so the structure of a loop affects the bill as much as the runtime does. An app run is an action that actually executes in a workflow. Triggers and skipped actions are not counted, and the Shuffle pricing article states that users, apps and workflows are unlimited. A loop that calls an enrichment action once per alert therefore counts one app run per alert per action in the loop body, while a condition that skips an action counts nothing for that item. Every action inside a loop is a multiplier, not a single step.

Before choosing between an in-workflow loop, Filter List and a subflow, model app-run volume from your own alert data. Take a typical daily batch, count the items that reach each action after filtering, and multiply by the number of executing actions per item. Illustrative example: if 2,000 alerts arrive per day and an enrichment action runs for every one, that is 2,000 runs before any further steps. If a Filter List first removes alerts already known to be benign and only 300 reach the enrichment step, the same action now runs 300 times. The filter itself should be checked for whether it runs as an app run, since that determines whether filtering saves anything at all. Repeat the count for peak days, not averages, because licensed capacity is consumed by the busiest batch.

Confirm the limits for your own edition before you commit to a design. Shuffle states that limits between the open-source and enterprise editions are actively enforced since v2.1.1, and the Shuffle configuration docs describe the enforcement, but the app-run allowance attached to each paid tier is set by the vendor and changes with the plan. Ask the vendor in writing how app runs are counted for loops, subflows and retries, and whether a subflow's internal actions count separately from its parent. Then ask what happens when a run limit is reached mid-batch, because a partly processed alert queue is a failure mode you need to plan for.

Building a batch playbook step by step

This sequence takes a playbook from a large alert list to a tested batch workflow that processes items in controlled groups, filters before costly actions, and fails in a visible way. Each step ends with a check so you know the design holds before it runs against live alerts.

  1. Confirm version and edition in use

    Before designing anything, record the Shuffle version and edition your instance runs, along with how your team's app run usage is metered. The v2.3.0 release was published on GitHub on September 28, 2026, and the docs recommend the latest Docker tag for stable releases. Since v2.1.1, limits between the open-source and enterprise editions are enforced, and licensing is based on app runs, which count actions that actually execute. Check the Shuffle version on your server and confirm the edition with your administrator. Done when you can state the version, edition and the metering assumptions in writing, because every later cost and limit decision depends on them.

  2. Define the input shape and batch size

    Write down what one alert item looks like in the input, including the fields you need and which are optional. Decide how many items one execution will take, and whether a large list is split into batches by a previous step or by the trigger. Ask your platform owner what memory and run time limits apply to your workers, since large single executions carry more risk than smaller batches. Done when you have a short sample of the expected JSON, a field list, and a written batch size limit you can test against.

  3. Add a Filter List step before costly actions

    Place a Filter List step ahead of enrichment, blocking or ticket creation so that only items meeting your conditions reach expensive apps. Use Liquid or conditions to keep items that need work and drop duplicates or known-benign entries. Each filtered-out item avoids a downstream app run, which keeps your metered usage down. Done when a test run with a mixed sample shows only the intended items passing the filter, and the execution details show the reduced count reaching later actions.

  4. Move reused per-item logic into a subflow

    If the same per-item sequence, such as enrichment followed by a verdict, is needed in more than one playbook or in several places, move it into a subflow and call it with the item as input. Keep the subflow's input and output fields explicit so callers can rely on them. Keep single-use logic inline to avoid extra indirection. Done when the subflow runs independently with one sample item and returns the fields the parent workflow expects, with no references to variables from the parent.

  5. Set loop limits and error handling

    Configure the loop so it has a defined item source and a stopping condition, then add handling for failed iterations so one bad item does not silently stop the batch. Use success flags in app results and conditions on failure to route problem items to a separate branch or a notification step. Confirm the loop's behavior when the list is empty. Done when a deliberately malformed item produces a visible failure branch and the remaining items still complete, which you can verify in the execution list.

  6. Test with a sample batch

    Run the workflow manually with a sample batch that includes valid items, duplicates, empty fields and one malformed record. Use the workflow run debugger to inspect the input and output of each step, and confirm that the Filter List and loop counts match your expectations. Check that app runs are counted only for executed actions. Done when the test batch produces the expected number of processed items, the expected failure path, and no unintended app executions in the execution details.

  7. Check execution details before enabling triggers

    Review the execution details for the test run, including per-step timing, the number of loop iterations, subflow results and any error output. Compare the observed behavior with the design you wrote in the earlier steps. Confirm the runtime location and the apps used are the ones you intend in your environment. Done when you have a short written record of the test results and any changes made, and the workflow is ready for a trigger to be enabled by someone who owns it.

How memory and parallelism behave as batches grow

The documented runtime model decides how a large alert list behaves, so start there before choosing a pattern. The Shuffle backend holds workflow definitions and execution records in OpenSearch and exposes the API on port 5001. Orborus, the runtime component, polls the backend for jobs. For each workflow execution it starts a worker, and that worker starts the app containers that perform each action. The architecture documentation describes this chain, which means every execution consumes runtime capacity on the node where its worker runs, and the number of executions Orborus can start at once is a capacity question you must test on your own hardware.

An in-workflow loop keeps the items inside one execution. The worker holds the list, iterates over it and records each action result in that same execution, so a long list grows the data carried by one worker and one execution record. Because the loop runs within a single worker, parallel progress depends on what that worker does with each iteration, and the number of app runs grows with the list. A subflow is different: each call creates its own workflow execution, with its own worker and its own record. That separation can spread load across Orborus capacity and keeps the parent execution small, but every subflow start adds scheduling and container overhead. The documentation does not publish per-item memory figures, per-worker limits or the point at which either pattern degrades, so treat those as items to confirm by testing.

Build a test that matches your real batch sizes before committing to a design. Run the same list through a loop version and a subflow version on a staging instance that mirrors your Orborus layout, and record execution duration, peak memory on the worker host, Orborus queue wait time and the app-run count from the execution details. Confirm with Shuffle how concurrency settings for Orborus are applied in your release, and whether app-run counts differ between the two designs before you estimate license needs. Use the Shuffle architecture docs as the reference for the component roles while you write the test plan.

How a batch moves through the Shuffle runtime

The batch starts at the trigger, which hands the alert list to the backend API. Filter List narrows the items, then either an in-workflow loop or a subflow call fans them out as separate executions. Orborus polls the backend for each job, starts a worker, and the worker launches app containers for every app action. Results go back to OpenSearch, which is the store you check when a run is slow or incomplete. Check how many app runs each path produces, and whether the workers have capacity for the parallel items.

Alert batch flow from trigger through the backend, Orborus, workers and app containers.

Security and operational risks in large batch playbooks

Large alert lists multiply every mistake in a playbook. A loop that touches a thousand alerts reuses the same credentials, copies the same data and spends the same app runs a thousand times, so each risk below needs a control set before the workflow goes live.

Credential reuse across iterations

A loop or subflow reads the saved app authentication on every pass, so one over-privileged API key ends up driving every alert in the batch. Shuffle stores app credentials encrypted in OpenSearch, but encryption at rest does not limit what a running iteration can do. Check that each app authentication has the narrowest read or write scope the task needs, and that any high-impact action such as blocking or session revocation sits behind a separate, scoped credential.

Shuffle configuration docs

Alert data retained in results

Every iteration writes its input and output into the execution record, so raw alert fields such as user names, IP addresses and file paths can persist in OpenSearch long after the incident closes. This matters most for regulated data and for batches containing personal data. Ask which fields each action really needs, drop the rest with a formatting step before the loop writes results, and confirm the retention period and who can read execution details on your instance.

Runaway loops and app-run counts

Shuffle licensing counts app runs, meaning actions that actually execute, so a loop over an unfiltered list can consume run allowance much faster than the analyst expects. A bad upstream query that returns ten thousand alerts instead of fifty is enough to cause this. Put a hard cap or a pre-loop count check on the list size, filter out duplicates and closed items first, and alert on unusually large executions before the loop starts.

Shuffle pricing article

Unclear handling of partial batches

When 300 of 1,000 items fail, an unstructured loop can report success while most alerts were never enriched. Each iteration should return an explicit success flag, and the parent workflow should count successes and failures before it closes the batch. Decide in advance whether a partial failure reopens the batch, routes failed items to a queue for an analyst, or stops the run, and test that path with a deliberately broken input.

Worker capacity during large runs

A large batch occupies worker and app container capacity for its full duration, which can delay unrelated playbooks that share the same Orborus nodes. The effect is larger when several batches start together. Confirm the concurrency setting for each runtime location, schedule heavy batches outside peak alert periods where possible, and watch queue depth during the first production runs.

Shuffle architecture docs

Questions teams ask before tuning large alert playbooks

What drives the cost of tuning a Shuffle playbook for large alert lists?

The cost follows the number of workflows, the number of alert types they handle, and how much of the current logic has to be rebuilt rather than adjusted. Most of the effort sits in analysis: measuring how many items each run receives, which apps each item calls, and where the existing playbook waits or fails. Cost also rises with the number of target systems behind each enrichment call, because each one needs its authentication, error handling and test data. Ask for the fee to be split into discovery, redesign, testing and handover, so you can see which part changes if the alert volume or the number of playbooks changes. Because Shuffle licensing is priced on app runs, a redesign that cuts unnecessary action executions also lowers your recurring run usage, so ask the partner to estimate that effect in the scope.

How long does a redesign of a large alert playbook usually take?

Duration depends on how many playbooks are involved, how many alert sources feed them, and how much real execution history exists to test against. Teams with clear run data and a small number of playbooks move faster than teams that must first reconstruct what their workflows do. The main drivers are the number of distinct branches, whether items must be grouped or processed in parallel, and how many external systems need test instances. Testing against representative alert exports usually takes longer than building the new flow. No duration figure is supplied for this topic, so ask any partner to state the phases, the dependencies on your staff and test environments, and the acceptance criteria in writing before work starts.

Can our own team redesign loops and subflows without a partner?

Yes, if you have someone who knows the playbooks, can read execution details, and can run a test instance that mirrors production apps and credentials. Internal teams usually struggle with three things: deciding when a subflow adds clarity versus overhead, measuring memory and run time on realistic batches, and keeping test data out of production systems. The team also needs time to maintain the result after handover. A partner is most useful when the design must be reviewed by security or compliance staff, when many playbooks share patterns, or when your staff has no capacity to run the test cycles. Decide which parts you want to keep in-house, such as ownership of the final workflows, and write that split into the scope.

What must our team provide before a tuning engagement starts?

Provide the playbooks in export form, a sample of alert exports that reflects real volume and variety, and the execution history that shows item counts and failure points. You will also need a test instance of Shuffle that matches your production version and has app authentication configured with non-production credentials, along with access to test or sandbox versions of the systems each app calls. Confirm the Shuffle version you run, since the docs say versions older than v2.1.1 are no longer supported after January 31, 2026. Also provide the runtime locations and their capacity, the names of the people who approve changes, and any data handling rules that limit which alert fields may leave your environment. Missing items usually extend the discovery phase.

How should we compare a DeployOpen quote for this work?

Compare quotes against the same written scope, not the headline total. Each quote should list the playbooks covered, the alert volumes used for testing, the test environments required, the deliverables such as exported workflows and a design note, and the retest or handover steps. Check whether the quote assumes your team provides exports, credentials and test instances, and what happens if those are late. Ask how the partner will measure success, such as run counts and execution times before and after, and whether those measurements use your data or a sample. DeployOpen works on fixed scope agreed in writing before work starts, and does not publish a price list, so a quote follows from that scope and should be compared line by line.

Does a redesign change how many app runs we are billed for?

It can. Shuffle licensing counts app runs, meaning actions that actually execute in a workflow, and does not count triggers or skipped actions. A loop that calls an enrichment app once per item produces one app run per item, while a design that filters items first can reduce the number of executed actions. Subflows add structure but do not by themselves reduce the actions executed, so the effect depends on what each branch calls. Ask for a before and after count of app runs on a representative batch, and confirm with Shuffle how your current edition's limits apply to your run volume, since the open-source and enterprise limits are enforced from version 2.1.1 onward.

What risks come with changing a playbook that handles many alerts?

The main risks are dropped items, duplicated actions, and silent failures that look like success. A loop that stops on one bad item can leave the rest of a batch unprocessed, and a parallel design can call the same external system faster than it accepts requests. Memory use can grow when a single execution holds large result sets. Test with the failure cases too: empty lists, malformed fields, and an upstream timeout. Confirm that every failed branch raises a visible status and notification, and that the old playbook stays available for rollback until the new one has run through a full comparison period.

How DeployOpen scopes and tests batch playbooks

DeployOpen starts every batch-processing engagement with a written, fixed scope agreed before any build work begins. For a playbook that loops over large alert lists, that scope names the workflows in question, the alert volumes they must handle at peak and in a normal day, the apps each step calls, and the environment where the work will run. It also states what is out of scope, such as changes to the detection sources that feed Shuffle. A quote follows from that written scope, so the buyer can see exactly what is being paid for before committing.

The first working phase is a review of the current playbooks against those alert volumes. The review checks where each workflow loops in-workflow, where it uses Filter List before a loop, and where it hands items to subflows, along with the app-run count each path generates, since app runs are the metric Shuffle licenses on. It also looks at how the Orborus runtime and worker containers behave under that load, and whether the design assumes a single runtime location. The output is a short list of changes with reasons, which the client approves before anything is rebuilt. Test batches then run in a non-production Shuffle instance, using sample alert sets sized to the volumes in scope and a set of replayed failures, so the team can compare run times, failure behavior and app-run counts between the old and new designs. Confirm with DeployOpen which test data is synthetic and which, if any, is copied from production, and how that copy is handled under your data rules.

Handover covers the workflows, the test results, the exported workflow files, the decisions behind each loop or subflow choice, and a runbook for the on-call analyst. Ongoing tuning is available as a retainer for clients who expect alert volumes or detection content to change. Ask DeployOpen to define in writing what a retainer includes, how often changes are reviewed and how changes are tested before they reach production, since those terms vary by engagement.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.