stream

Elegant stream processing pipeline written entirely in Golang

Github星跟踪图

Flogo Stream

Edge devices have the potential for producing millions or even billions of events at rapid intervals, often times the events on their own are meaningless, hence the need to provide basic streaming operations against the slew of events.

A native streaming action as part of the Project Flogo Ecosystem accomplishes the following primary objectives:

  • Enables apps to implement basic streaming constructs in a simple pipeline fashion
  • Provides non-persistent state for streaming operations
    • Streams are persisted in memory until the end of the pipeline
  • Serves as a pre-process pipeline for raw data to perform basic mathematical and logical operations. Ideal for feeding ML models

Some of the key highlights include:

? Simple pipeline construct enables a clean, easy way of dealing with streams of data
Stream aggregation across streams using time or event tumbling & sliding windows
? Join streams from multiple event sources
? Filter out the noise with stream filtering capabilities

Getting Started

We’ve made building powerful streaming pipelines as easy as possible. Develop your pipelines using:

  • A simple, clean JSON-based DSL
  • Golang API

See the sample below of an aggregation pipeline (for brevity, the triggers and metadata of the resource has been omitted). Also don’t forget to check out the examples in the repo.

  "stages": [
    {
      "ref": "github.com/project-flogo/stream/activity/aggregate",
      "settings": {
        "function": "sum",
        "windowType": "timeTumbling",
        "windowSize": "5000"
      },
      "input": {
        "value": "=$.input"
      }
    },
    {
      "ref": "github.com/project-flogo/contrib/activity/log",
      "input": {
        "message": "=$.result"
      }
    }
  ]

Try out the example

Firstly you should install the install the Flogo CLI.

Next you should download our aggregation example agg-flogo.json.

We'll create a our application using the example file, we'll call it myApp

$ flogo create -f agg-flogo.json myApp

Now, build it...

$ cd myApp/
$ flogo build

Activities

Flogo Stream also provides some activities to assist in stream processing.

  • Aggregate : This activity allows you to aggregate data and calculate an average or sliding average.
  • Filter : This activity allows you to filter out data in a streaming pipeline.

License

Flogo source code in this repository is under a BSD-style license, refer to LICENSE

主要指标

概览
名称与所有者project-flogo/stream
主编程语言Go
编程语言Go (语言数: 1)
平台
许可证BSD 3-Clause "New" or "Revised" License
所有者活动
创建于2018-08-01 12:45:12
推送于2023-06-15 16:34:07
最后一次提交2023-06-15 22:04:02
发布数9
最新版本名称v0.3.0 (发布于 )
第一版名称v0.1.0 (发布于 )
用户参与
星数66
关注者数18
派生数33
提交数142
已启用问题?
问题数6
打开的问题数4
拉请求数39
打开的拉请求数3
关闭的拉请求数1
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?