Bring Your Own Code

Most recent version: v0.0.1

See the changelog of this Action type here.

Overview

The Bring Your Own Code Action enables dynamic execution of user-provided Python code in isolated environments in an Onum pipeline. This way, you can use your own Python code to enrich or reduce your events directly.

Ports

These are the input and output ports of this Action:

Input ports
  • Default port - All the events to be processed by this Action enter through this port.

Output ports
  • Default port - Events are sent through this port if no error occurs while processing them.

  • Error port - Events are sent through this port if an error occurs while processing them.

Configuration

1

Find Bring Your Own Code in the Actions tab (under the Advanced group) and drag it onto the canvas. Link it to the required Listener and Data sink.

2

To open the configuration, click the Action in the canvas and select Configuration.

3

Enter the required parameters:

Configuration

Parameter
Description

Docker client

Choose one of the available Docker instances to execute your code.

IP

Enter the instance IP to execute your code.

Port

Enter the instance port to execute your port.

Timeout connection

Enter the milliseconds to wait for the Docker connection.

Buffer size

Size in bytes to batch events.

Code

Paste your Python File in this area. You can include any required Dependencies in the corresponding tab.

4

Finally, give your Output Field a name. Click Add field if you need to add any additional fields.

5

Click Save to complete.

Last updated

Was this helpful?