GithubHelp home page GithubHelp logo

svti / streamer Goto Github PK

View Code? Open in Web Editor NEW
18.0 3.0 8.0 1.75 MB

streamer 实时计算引擎

Java 34.26% Shell 4.41% CSS 2.43% HTML 4.34% JavaScript 53.21% SCSS 1.35%
kafka-sql streaming stream-processing kafka calcite streamsql stream-sql

streamer's Introduction

Streamer流计算引擎

介绍

Streamer流计算引擎是一个基于Apache Calcite的实时计算框架,没有采用大家熟知的Spark和Flink,自研的Kafka消费者,来处理 Kafka的数据,实现实时计算的目的。 

通过Calcite实现了Kafka和JDBC数据源的JOIN,可以很方便的把Kafka中的数据,当作一张无边界的表来使用。

首页

任务

详细

特性

- 目前只支持Kafka的数据源,后面考虑支持更多。
- 支持JDBC的维度表,来实现某个维度的去重,比如某日的UV。
- 支持 Console 、JDBC 、Redis和企业微信的SINK。

用法举例

CREATE TABLE kafkaTable(
   context.device.did:did string,
   context.device.factory:factory string,
   context.device.model:model string,
   context.data.time:time timestamp
)WITH(
    type='kafka08',
    kafka.zkurl='kafka:2181/kafka',
    kafka.topic='topic',
    kafka.group='test',
    kafka.reset='smallest',
    kafka.batch='10'
);

CREATE SINK jdbcSink(
)WITH(
    type='jdbc',
    driver='com.mysql.jdbc.Driver',
    url='jdbc:mysql://host/tmp?useSSL=false',
    user='tmp',
    password='password',
    sql='INSERT INTO tmp (did,factory,model,createAt,updateAt) VALUES (?,?,?,?,?) ON DUPLICATE KEY UPDATE factory =? , model =? , updateAt =? '
);

insert into jdbcSink select did,factory,model, MIN(CAST(`time` as timestamp)) as createAt , MAX(CAST(`time` as timestamp)) as updateAt , factory , model , MAX(CAST(`time` as timestamp)) as updateAt FROM kafkaTable GROUP BY did,factory,model;

streamer's People

Contributors

dependabot[bot] avatar svti avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

streamer's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.