Build a streaming app using a Python API

This tutorial is part of the Learning path: Get started with IBM Streams.

Level Topic Type
100 Introduction to IBM Streams Article
101 Create your first IBM Streams app without writing code Tutorial
201 Ingest data from Apache Kafka Code pattern
301 Build a streaming app using a Python API Code pattern
302 Access streaming data with REST services Tutorial
401 Score streaming data with a machine learning model Code pattern

Summary

In this developer code pattern, we will create a Jupyter Notebook that contains Python code that uses the streamsx API to build a streaming application. The app will be built using IBM Streams on IBM Cloud Pak® for Data.

Description

The Python API streamsx allows you to build streaming apps that use IBM Streams, a service that runs on IBM Cloud Pak for Data. The IBM Cloud Pak for Data platform provides additional support, such as integration with multiple data sources, built-in analytics, Jupyter Notebooks, and machine learning. Scalability is increased by distributing processes across multiple computing resources.

In this code pattern, we will build a streaming application by creating a Jupyter Notebook using the streamsx Python API. The app will process a stream of data containing mouse-click events from users as they browse a shopping website.

Flow

Flow

  1. User runs Jupyter Notebook in IBM Cloud Pak for Data.
  2. Clickstream data is inserted into streaming app.
  3. Streaming app using the streamsx Python API is executed in the IBM Streams service.
  4. User accesses IBM Streams service job to view events.

Instructions

Find the detailed steps for this pattern in the README file. The steps will show you how to:

  1. Clone the repo.
  2. Add IBM Streams service to IBM Cloud Pak for Data.
  3. Create a new project in IBM Cloud Pak for Data.
  4. Add a data asset to your project.
  5. Add a notebook to your project.
  6. Run the notebook.
  7. View job status in IBM Streams service panel.
  8. Cancel the job.

This is part of a learning path that guides you through the steps to build IBM Streams applications. This series covers the various ways to create streaming apps and how to navigate the platforms that support them. Complete the series with Score streaming data with a machine learning model.