Giter Site home page Giter Site logo

vz-metrics-adapter's Introduction

Vizceral Metrics Adapter

This project acts as the literal translation layer between the data presented from each foundation by app-metrics-nozzle so that it can be be transformed it into the data model expected by vizceral-app-metrics-ui

Configuration

Configuration is relatively straight forward using contsants and variables at the top of index.py

The Notice thresholds for information/warning/danger graph decorations can be modified by tweaking the following constants:

# Constants for warning checks
THRESHOLD_CPU_DANGER      = 75
THRESHOLD_CPU_CRIT        = 50
THRESHOLD_CPU_WARN        = 25

THRESHOLD_RPS_DANGER      = 1000
THRESHOLD_RPS_CRIT        = 500
THRESHOLD_RPS_WARN        = 100

# The next 2 sets of thresholds are expressed as % used
THRESHOLD_MEM_DANGER      = 90
THRESHOLD_MEM_CRIT        = 75
THRESHOLD_MEM_WARN        = 60

THRESHOLD_DISK_DANGER     = 90
THRESHOLD_DISK_CRIT       = 80
THRESHOLD_DISK_WARN       = 75

# Add a notice to the node if not in the state defined below
THRESHOLD_RUNNING_STATE   = "RUNNING"

The configuration for each foundation one wishes to visualize (or for each installation of app-metrics-nozzle) is set like so:

# First Foundation
pcf_one = {}
pcf_one["name"] = "pcf-secondary"
pcf_one["displayName"] = "Secondary PCF"
pcf_one["json_url"] = "https://app-metrics-nozzle.apps.your-pcf.com/api/apps"
pcf_one["exclude_orgs"] = []
pcf_one["only_orgs"] = ["second-foundation"]

# Second Foundation (which is really just the first, repeated with different filters)
pcf_two = {}
pcf_two["name"] = "pcf-primary"
pcf_two["displayName"] = "Primary PCF"
pcf_two["json_url"] = "https://app-metrics-nozzle.apps.your-pcf.com/api/apps"
pcf_two["exclude_orgs"] = ["system", "second-foundation"]
pcf_two["only_orgs"] = []

Note that exclude_orgs and only_orgs can be used to selectively include/exclude certain ORGs to reduce some of the "clutter" in the visualization.

Finally, ensure that every Foundation one defines has been packed into the array which will be iterated over to build the final data model:

# Pack the list of foundations to process into the hash "foundations"
foundations[pcf_one["name"]] = pcf_one
foundations[pcf_two["name"]] = pcf_two

#
# END Configuration
#

Once fully configured, push an instance to your PCF/CF and then ensure one has deployed vizceral-app-metrics-ui to sit infront of the adapter.

vz-metrics-adapter's People

Contributors

4n3w avatar dav1dc-pcf avatar

Stargazers

 avatar  avatar  avatar  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.