All Projects → locaweb → heartcheck

locaweb / heartcheck

Licence: MIT license
A simple way to check if everything is good in your app

Programming Languages

ruby
36898 projects - #4 most used programming language
shell
77523 projects

Projects that are alternatives of or similar to heartcheck

Exabgp
The BGP swiss army knife of networking
Stars: ✭ 1,713 (+7686.36%)
Mutual labels:  health-check
Samples
Sample applications using App.Metrics
Stars: ✭ 19 (-13.64%)
Mutual labels:  health-check
docktor
Health checking and security implementations for running Docker containers and images
Stars: ✭ 42 (+90.91%)
Mutual labels:  health-check
Appmetrics
App Metrics is an open-source and cross-platform .NET library used to record and report metrics within an application.
Stars: ✭ 1,986 (+8927.27%)
Mutual labels:  health-check
Kafka Health Check
Health Check for Kafka Brokers.
Stars: ✭ 214 (+872.73%)
Mutual labels:  health-check
statoo
`statoo` is a super simple http GET tool for checking site health
Stars: ✭ 28 (+27.27%)
Mutual labels:  health-check
Health Checks Api
Standardize the way services and applications expose their status in a distributed application
Stars: ✭ 78 (+254.55%)
Mutual labels:  health-check
py-healthcheck
Write simple healthcheck functions for your Flask or Tornado apps.
Stars: ✭ 92 (+318.18%)
Mutual labels:  health-check
check netapp ontap
🍀 Check NetApp Ontap 🍀
Stars: ✭ 38 (+72.73%)
Mutual labels:  health-check
dnsdisco
DNS service discovery library
Stars: ✭ 25 (+13.64%)
Mutual labels:  health-check
Firemotd
🔥 Fire Framework Linux MoTD Generator 🔥
Stars: ✭ 156 (+609.09%)
Mutual labels:  health-check
Graceful Server
Tiny (~5k), KISS, dependency-free Node.JS library to make your API more graceful
Stars: ✭ 173 (+686.36%)
Mutual labels:  health-check
express-actuator
Express middleware with endpoints to help you monitor and manage applications
Stars: ✭ 71 (+222.73%)
Mutual labels:  health-check
Simple Go Server
A simple golang web server with basic logging, tracing, health check, graceful shutdown and zero dependencies
Stars: ✭ 136 (+518.18%)
Mutual labels:  health-check
node-healthchecks-api
The Node.js implementation of the Health Checks API by Hootsuite
Stars: ✭ 25 (+13.64%)
Mutual labels:  health-check
Amon
Amon is a modern server monitoring platform.
Stars: ✭ 1,331 (+5950%)
Mutual labels:  health-check
microservice-graph-explorer
Navigate and explore all of the microservices in your application in real time using the real application connections.
Stars: ✭ 71 (+222.73%)
Mutual labels:  health-check
polaris-java
Lightweight Java SDK used as Proxyless Service Governance Solution
Stars: ✭ 84 (+281.82%)
Mutual labels:  health-check
redis-healthy
It retrieves metrics, periodically, from Redis (or sentinel) and send them to Logstash
Stars: ✭ 62 (+181.82%)
Mutual labels:  health-check
kafka-health-check
Health Check for Apache Kafka
Stars: ✭ 30 (+36.36%)
Mutual labels:  health-check

Heartcheck

Heartcheck is a monitoring tool for Rack applications. It provides a DSL to declare service checks and an URI that returns the status for each service. With this gem you can monitor if your app has access to the database, a cache service, an API, etc.

Build Status Code Climate Ebert

Installation

Add this line to your application's Gemfile:

gem 'heartcheck'

And then execute:

$ bundle

Or install it yourself as:

$ gem install heartcheck

Usage

First generate the config file for the framework you are using:

$ heartcheck rails
$ heartcheck padrino
$ heartcheck sinatra

Then edit the generated file by adding your checks on it and restart your server. Now you should be able to make a HTTP request for /monitoring and get a JSON response that contains the status for each monitored service.

The following environment variables are needed by heartcheck:

HEARTCHECK_APP_NAME=MyApplicationName

Using built-in checks

Firewall check

Heartcheck.setup do |config|
  config.add :firewall do |c|
    c.add_service(host: 'domain.com', port: 80)
    c.add_service(host: 'domain.com', port: 80, timeout: 5) # Default timeout is 2 seconds
    c.add_service(url: 'https://domain.com')
    c.add_service(url: 'https://domain.com', proxy: 'http://proxy.domain.com')
  end
end

HTTP Routes

Basic health check

To get the status for all services, make a HTTP request for the following URI:

/monitoring

It will return a JSON response and a status for each service.

Functional status

Functional services are services essential for your application. You can get their status using the following route:

/monitoring/functional

Info route

This route returns custom information about your app. You can configure it to return whatever information you want:

/monitoring/info

Dev status

Returns some debugging information:

/monitoring/dev

Very basic health check

Returns a simple ok if the app is running. It does not execute any configured checks:

/monitoring/health_check

General info and dependencies

Returns general application info and a list of dependencies' URIs, but executes no checking:

/monitoring/inspect

Response formatting

An optional formatter may be set for the monitoring response. We provide the default format using a list of hashes and one with a single Hash. Please check Heartcheck.use_hash_formatter!

Plugins

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/locaweb/heartcheck.

Docker

Heartcheck can be setup with Docker and Docker Compose on macOS or Linux systems, so that you don't need to install ruby and it's dependencies via rbenv or rvm.

Just do your setup locally by running:

./scripts/heartcheck setup

Run ./scripts/heartcheck -h to see available options, such as bash, rspec, etc.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].