GithubHelp home page GithubHelp logo

isabella232 / layer-apache-flume-base Goto Github PK

View Code? Open in Web Editor NEW

This project forked from juju-solutions/layer-apache-flume-base

0.0 0.0 0.0 55 KB

Base layer for Apache Flume agents

License: Apache License 2.0

Python 100.00%

layer-apache-flume-base's Introduction

Overview

This is the base layer for the Apache Flume charms. It will handle installing the Apache Flume libraries and any dependencies, and provides helpers to configure Flume.

Usage

To create a charm layer using this base layer, you need only include it in a layer.yaml file:

includes: ['layer:flume-base']

This will implicitly include the reactive base layer, which you can see for more information on using layers in charms.

Reactive States

This layer will set the following states:

  • flume-base.installed This will be set when the Apache Flume libraries are installed. Once this is set, you can configure Flume using the method:

    • configure_flume(template_data=None) This will render the Flume config from the template file templates/flume.conf.j2 and will pass in the keys and values in the template_data dict, if given, along with a config variable containing all of the charm config options.

An example using this layer:

from charmhelpers.core import hookenv
from jujubigdata.utils import DistConfig
from charms.layer.flume_base import Flume

@when('flume-base.installed', 'flume-sink.ready')
def configure(sink):
    flume = Flume(DistConfig())
    flume.configure_flume({
        'agents': sink.agents(),
    })
    flume.start()
    hookenv.status_set('active', 'Ready')

Contact Information

Resources

layer-apache-flume-base's People

Contributors

johnsca avatar ktsakalozos avatar kwmonroe avatar pengale 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.