Streams

In Usage Engine, streams are created inside solutions. A stream consists of collector, processor, and forwarder functions that provide specific functionality and are linked to automated data flows of varying complexity. 

Sections in this page:

Adding a stream to a solution

When you have created a solution and opened it, you can create new streams or import existing streams. When the solution does not contain any streams, you will see the Import example streams page, where you can read about and select to import an example stream or use the Create stream and Import stream buttons for creating or importing an existing stream.

firststream.png
New solution with no streams

Creating a stream

To create a stream:

  1. In the Solution page, click on the Create stream button.
    The New stream dialog opens.

    New stream.png
    New Stream dialog box
  2. Enter the name of the new stream in the New stream name field and click on the Create Stream button.

The Stream editor will open in Edit mode where you can design your stream using the Functions in the Function library, see Stream editor for more information.

createstream_fullview.png
The Stream editor

Note!

When creating streams, depending on your subscription package, you will be presented with an option to configure your stream according to the number of records it needs to process. This is to support the concept of Performance and Scalability when handling streams in Usage Engine.

After clicking Create Stream, you must select the number of records to be processed per stream execution or stream run. Each stream is configured to process a maximum of 10 million records per execution. If you want to process more than 10 million records you can configure one or more stream replicas. This will enable you to process a larger number of records without compromising on the performance of Usage Engine. You can choose the number of replicas you wish to create.

There are some prerequisites that you need to ensure before configuring replicas. For more information about this see Performance and scalability.

Importing an existing stream

The streams are stored in *.json format and you can either export the *.json file or copy the content and import into another solution or into the same solution.

To import an existing stream into your solution:

  1. Export or copy the contents of the *.json file for the stream you want to import into another solution by clicking on the Export button in the Stream editor and either click on the Export button or the Copy to clipboard button.

Hint!

You can also export the stream from the Solution page by right-clicking on the More button and selecting the Export option.

  1. Open the solution into which you want to import the stream.

  2. Click on the Import stream button.
    The Import stream dialog opens.

    Import stream.png
    Import stream input box
  3. If you exported the *.json file, drag 'n' drop it in the Click or drag JSON file here to import area.

Hint!

You can also click the Click or drag JSON file here to import area, select the exporteded file, and click Upload.

  1. If you copied the content of the *.json file, paste it into the Or paste JSON section.

  2. Click on the Import button.

The stream will be imported and listed in the Solution page.

Note!

If a stream with the same name already exists in the solution, the name of the imported stream will be appended with “(Copy)”.

Importing an example stream

The example streams have been created for you to import so that you can explore how to use Usage Engine. You will see the Import example streams page when you create a new solution, or if you open a solution and click on the Import example stream button.

example_streams_CE.png
Import example streams page

To import an example stream, click on the Import stream button for the example you want to import. The stream will be imported and and opened in Edit mode in the Stream editor.

Viewing streams in a solution

When you open a solution that contains streams, you will see a list of all the streams in the solution.

Streams_ list_in_Solution_C.png
Streams list in Solution page

Toolbar

In the toolbar in the Solution page you have a search field that you can use to search for a specific stream based on its name, and you have four buttons for importing an example stream, importing an existing stream, setting display options, and creating a stream.

Solution overview toolbar.png
The toolbar in the Solution page

This section has the following subsections: