Cribl LogStream ā€“ Docs

Cribl LogStream Documentation

Questions? We'd love to help you! Meet us in #Cribl Community Slack (sign up here)
Download entire manual as PDF - v2.4.5


What Are Pipelines

After your data has been matched by a Route, it gets delivered to a Pipeline. A Pipeline is a list of Functions that work on the data.


As with Routes, the order in which the Functions are listed matters. A Pipeline's Functions are evaluated in order, topā€‘>down.

Accessing Pipelines

Select Pipelines from LogStream's (or a Worker Group's) top menu. To configure a new Pipeline, click +Ā AddĀ Pipeline.

How Do Pipelines Work

Events are always delivered to the beginning of a Pipeline via a Route. The data in the Stats column shown below are for the last 15 minutes.

Pipelines and Route inputs


You can pressĀ the ] (right-bracket) shortcut key to toggle between the Preview pane and an expanded Pipelines display. This works when no field has focus.

Within the Pipeline, events are processed by each Function, in order. A Pipeline will always move events in the direction that points outside of the system. This is on purpose, to keep the design simple and avoid potential loops.

Pipeline Functions


You can streamline the above display by organizing related Functions into FunctionĀ groups.

Pipeline Settings

Click the gear icon at top right to open the Pipeline's Settings. Here, you can attach the Pipeline to a Route. InĀ the Settings' Async function timeout (ms) field, you can enter a buffer to adjust for Functions that might take much longer to execute than normal. (An example would be a Lookup Function processing a large lookup file.)

Pipeline Settings

Advanced Mode (JSONĀ Editor)

Click Advanced Mode to edit the Pipeline's definition as JSON text. In this mode's editor, you can directly edit multiple values. You can also use the Import and Export buttons here to copy and modify existing Pipeline configurations.

Advanced Pipeline Editing

Pipeline Actions

Click a Pipeline's Actions (...) menu to display options for copying or deleting the Pipeline.

Pipeline > Actions menu

Copying a Pipeline displays the confirmation message and the (highlighted) Paste button shown below.

Paste button for copied Pipeline

Pasting prompts you to confirm, or change, a modified name for the new Pipeline. The result will be an exact duplicate of the original Pipeline in all but name.

Saving/renaming a pasted Pipeline

Types of Pipelines

You can apply various Pipeline types at different stages of data flow. All Pipelines have the same basic internal structure (a series of Functions) ā€“ the types below differ only in their position in the system.

Pre-processing, processing, and post-processing Pipelines

Pre-Processing Pipelines

These are Pipelines that are attached to a Source to condition (normalize) the events before they're delivered to a processing Pipeline. They're optional.

Typical use cases are event formatting, or applying Functions to all events of an input. (E.g., to extract a message field before pushing events to various processing Pipelines.)

You configure these Pipelines just like any other Pipeline, by selecting Pipelines from the top menu. You then attach your configured Pipeline to individual Sources, using the Source's Preā€‘Processing > Pipeline drop-down.

Fields extracted using pre-processing Pipelines are made available to Routes.

Processing Pipelines

These are "normal" event processing Pipelines, attached directly to Routes.

Post-Processing Pipelines

These Pipelines are attached to a Destination to normalize the events before they're sent out. AĀ post-processing Pipeline's Functions apply to all events exiting to the attached Destination.

Typical use cases are applying Functions that transform or shape events per receiver requirements. (E.g., to ensure that a _time field exists for all events bound to a Splunk receiver.)

You configure these Pipelines as normal, by selecting Pipelines from the top menu. You then attach your configured Pipeline to individual Destinations, using the Destination's Postā€‘Processing > Pipeline drop-down.

You can also use a Destination's Postā€‘Processing options to add SystemĀ Fields like cribl_input, identifying the LogStream Source that processed the events.

Best Practices for Pipelines

Functions in a Pipeline are equipped with their own filters. Even though filters are not required, we recommend using them as often as possible.

As with Routes, the general goal is to minimize extra work that a Function will do. The fewer events a Function has to operate on, the better the overall performance.

For example, if a Pipeline has two Functions, f1 and f2, and if f1 operates on source 'foo' and f2 operates on source 'bar', it might make sense to apply source=='foo' versus source=='bar' filters on these two Functions, respectively.

Updated about a month ago


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.