grange-server

command module
v0.0.0-...-0437b18 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 3, 2016 License: Apache-2.0 Imports: 17 Imported by: 0

README

grange-server

A read-only range server frontend to grange. See there for documentation of concepts and query language.

Cluster and group data is specified in YAML files.

Installation

  1. Setup your go environment if needed

     mkdir $HOME/go
     export GOPATH=$HOME/go
    
  2. Install grange-server and erg client

     go get -v -u github.com/square/grange-server
     go get -v -u github.com/square/erg
    

Usage

Put some range YAML files in clusters/, then:

$GOPATH/bin/grange-server --port=8888 $GOPATH/src/github.com/square/grange-server/grange.gcfg

Simple expansion (with erg client):

erg -v 1..2

Find all clusters that have type key set to "mysql":

erg -v '%{has(TYPE;mysql)}'

Features

  • Read-only serving of cluster YAML files on disk.
  • -parse option to dry-run parse source files and not start the server. Will return non-zero exit code if any warnings were emitted.
  • Reloads configuration file in response to HUP signal. Allows dynamic log level and cluster changes.
  • Can report HTTP response metrics to statsd.

Format

See the clusters directory for sample YAML files. At minimum, your directory should contain a GROUPS.yaml. See grange.gcfg for a sample configuration.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL