Giter VIP home page Giter VIP logo

flink-intro's Introduction

#Flink-intro

Run docker containers

Prerequisites

docker >= 1.12.5(tested)

docker-compose >= 1.10

Flink docker image

This code requires Flink version 1.2-SNAPSHOT (as of 19.01). To build flink docker image one has to build flink binary version oneself. To do that checkout flink and follow instructions in official docs to build it. Than copy ${FLINK_DIR}/flink-dist/target/flink-1.2-SNAPSHOT-bin/flink-1.2-SNAPSHOT into ${FLINK_INTRO_DIR}/infrastructure/flink/archive.

Than inside ${FLINK_INTRO_DIR}/infrastructure/flink run:

    docker build -t flink .

Run containers

You can start containers by invoking:

    docker-compose -f ${FLINK_INTRO_DIR}/infrastructure/docker-compose.yml up -d

Then configure your /etc/hosts file at least for jobmanager, kafka and grafana approprietly. You can check container ip by running (example for jobmanager):

    docker inspect infrastructure_jobmanager_1

Create fat jars

Invoke:

    sbt assembly

There are 5 interesting modules:

  • flink-event-generator - generates events and stores them in kafka
  • flink-sql - example of using sql
  • flink-cep - example of using cep
  • flink-queryable-job - example of queryable job
  • flink-state-server - server for querying flink-queryable-job

flink-event-generator, flink-sql, flink-cep and flink-queryable-job take kafka address as parameter e.g. '-k kafka:9092'. Moreover for flink-event-generator one can specify the max time between generating two events e.g. '-m 1000'

flink-intro's People

Contributors

dawidwys avatar

Watchers

 avatar

Forkers

dreew23

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.