Skip to main content

Reference

Documentation for the S2 components for Bento is available at:

Getting started

We are going to take inputs from a number of S2 streams, process the records using Bento, and output the records merged into another S2 stream.

Prerequisites

1

Generate an S2 access token

Generate an access token by logging into the dashboard and set the S2_ACCESS_TOKEN environment variable:
2

Install the S2 CLI

Install the S2 CLI and set the access token:
3

Install the Bento CLI

Install the latest version of the Bento CLI:
Ensure that the CLI supports the S2 plugin:

Setup

1

Create a new basin

Basin names are globally unique. They must be between 8 and 48 characters long and comprise lowercase letters, numbers and hyphens. They cannot begin or end with a hyphen.
2

Create source streams

Create source streams with the prefix pup/ and append some “woofs”:
We can verify that the streams have been appended with random numbers using:
The above command should output a list of 10 random numbers.
3
Create a new stream called woofs to store the processed records:

The Pipeline

1

Configuration

Create a file called woof-pipeline.yml:
2

Running the pipeline

Start the pipeline using:
Open up another terminal and see the records being appended to the woofs stream: