GithubHelp home page GithubHelp logo

junyangz / kafka-rolling-restart Goto Github PK

View Code? Open in Web Editor NEW

This project forked from opencore/kafka-rolling-restart

0.0 1.0 0.0 8 KB

An Ansible role to perform a rolling restart of a Kafka cluster including waiting for under-replicated-partitons to be caught up.

License: Apache License 2.0

kafka-rolling-restart's Introduction

Role Name

A very simple role to perform a rolling restart of a Kafka cluster that waits for the cluster to recover before restarting the next cluster node.

Requirements

No special requirements for the Ansible node. Nodes that this role is run against are expected to have the kafka-topics tool installed an run a kafka service.

Role Variables

Variable Name Description Default Value
ZOOKEEPER_CONNECT Not currently in use kafka-topics
NUMBER_OF_RETRIES The number of times to check whether all under-replicated partitions have been fixed. 20
DELAY_BETWEEN_RETRIES Seconds to wait between retries. 60
KAFKA_SERVICE_NAME Name of the Kafka service to be restarted. kafka
KAFKA_TOPICS_COMMAND Name (and path if necessary) of the kafka-topics tool - this is mostly to distinguish between Apache and Confluent Kafka. /opt/apps/kafka/bin/kafka-topics.sh

Dependencies

None.

Example Playbook

For this role to work properly, it is very important to include serial: 1 in your playbook. Otherwise it will not be a rolling restart, as multiple hosts will be restarted at the same time, potentially leading to downtime.

- hosts: kafka
  serial: 1
  roles:
    - kafka-rolling-restart

License

Apache 2.0

kafka-rolling-restart's People

Contributors

junyangz avatar soenkeliebau avatar

Watchers

 avatar

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.