Skip to main content
Use case · Integration

PLC data to Kafka and InfluxDB

Read Siemens S7 and Modbus controllers, clean up units and field names, and forward the events to the systems IT already runs.

Adapter library with PLC4X, Kafka and other connectors
Apache StreamPipes, demo data

The situation

IT wants machine data in Kafka topics and a time-series database, in a schema they can rely on. OT wants nothing installed on the controllers and no connections opened into the plant network.

StreamPipes reads the controllers with its PLC4X adapters, lets you fix names, units and types once in the adapter, and publishes the result to Kafka, InfluxDB or both. The extension service that does the reading can sit next to the machines.

How it works in StreamPipes

  1. 1

    Connect the controller

    Create a PLC4X S7 or Modbus TCP adapter, define the addresses to read and the polling interval, and preview incoming events before you start.

  2. 2

    Harmonize the schema

    Rename fields, set measurement units and convert them, and attach metadata such as the machine or line, all in the adapter configuration.

  3. 3

    Publish

    Build a pipeline that ends in a Kafka Publisher and an InfluxDB sink. Add a Numerical Filter or Field Mapper in between if consumers need a subset.

  4. 4

    Keep a copy

    Persist the stream as a dataset with a retention policy, so the plant keeps its own history for charts and audits.

What it looks like

Schema editor with measurement unit configuration
Measurement units and conversions are set once in the adapter.
Pipeline element configuration dialog
Configure sinks against the stream's schema.
Dataset retention configuration dialog
Retention keeps local history under control.

Try it on your machine.

One command starts StreamPipes with Docker. The quickstart takes you from there to a first dashboard.

docker composerelease 0.98.0
mkdir -p streampipes-0.98.0 && cd streampipes-0.98.0 \
&& curl -fsSLO https://raw.githubusercontent.com/apache/streampipes/0.98.0/installer/compose/docker-compose.yml \
&& curl -fsSLO https://raw.githubusercontent.com/apache/streampipes/0.98.0/installer/compose/.env \
&& docker compose up -d