Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/renderedtext/grpc_health_check

Healthchecks for Elixir GRPC server apps
https://github.com/renderedtext/grpc_health_check

Last synced: 27 days ago
JSON representation

Healthchecks for Elixir GRPC server apps

Awesome Lists containing this project

README

        

# GrpcHealthCheck

GrprHealthCheck implements the official Grpc health checking interface in
Elixir. It can be used to check if Elixir based Grpc servers are up and running.

More on Grpc health checks:
- [Official doc](https://github.com/grpc/grpc/blob/master/doc/health-checking.md)
- [Interface definition
source](https://github.com/grpc/grpc/blob/master/src/proto/grpc/health/v1/health.proto)
- [Ruby native
implementation](https://github.com/grpc/grpc/tree/master/src/ruby/pb/grpc/health/v1)

## Installation

Add this to your list of dependencies in `mix.exs`:

```elixir
def deps do
[
{:grpc_health_check, github: "renderedtext/grpc_health_check"}
]
end
```

And also add the health check server to your supervision tree:

```elixir
services = [
...,
GrpcHealthCheck.Server
]

children = [
supervisor(GRPC.Server.Supervisor, [{services, port}])
]

Supervisor.start_link(children, opts)
```

If you're not running the GRPC workers as a part of a supervision tree, run the
server alongside the rest of your GRPC workers.

## Usage

The health check server will be running with you application.

Running `mix healthcheck` will run the health check client and call the health
check service.