Skip to content

Latest commit

 

History

History
61 lines (41 loc) · 1.91 KB

README.md

File metadata and controls

61 lines (41 loc) · 1.91 KB

fdb-prometheus-exporter Docker Pulls go build Go Report Card GoDoc

A FoundationDB Prometheus metrics exporter

Building

Requirements

  • go >= 1.13
git clone [email protected]:PierreZ/fdb-prometheus-exporter.git

go install

Using it

fdb-prometheus-exporter is env-var driven, you can customize:

  • FDB_API_VERSION
  • FDB_CLUSTER_FILE
  • FDB_CREATE_CLUSTER_FILE
  • FDB_EXPORT_WORKLOAD
  • FDB_METRICS_LISTEN
  • FDB_METRICS_EVERY

Deployments

Docker-Compose

An example using Docker-compose is available:

cd deployment/docker-compose
docker-compose up --build

# Metrics will be available at
curl localhost:8081/metrics | grep fdb | grep -v "#"

Kubernetes

An example to deploy fdb-prometheus-exporter on Kubernetes is available. It has been tested with the official FDB Operator.

# After deploying the sample-cluster
kubectl apply -f ./deployment/kubernetes/fdb-metrics-pod.yaml

# You can view metrics through kubctl proxy
kubectl port-forward fdb-prometheus-exporter 8080:8080

# To destroy it
kubectl delete -f ./deployment/kubernetes/fdb-metrics-pod.yaml

You can also find a Batch job for go-ycsb to spawn some workloads.

# spawn ycsbn workload a to f as a K8S Batch
kubectl apply -f ./deployment/kubernetes/go-ycsb-batch.yaml