# grpc-js-health-check

> Implementation for gRPC health check using @grpc/grpc-js

Latest version **1.2.2** (published 2023-12-13) · ISC license · 0 weekly downloads

## Install

```sh
npm install grpc-js-health-check
pnpm add grpc-js-health-check
yarn add grpc-js-health-check
bun add grpc-js-health-check
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.2.2 |
| Published | 2023-12-13 |
| First published | 2020-12-15 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 16 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Minh Ho |
| Maintainers | khacminhrt |
| Keywords | gprc health check, grpc, health check |

## Links

- npm: https://www.npmjs.com/package/grpc-js-health-check
- Repository: https://github.com/khacminh/grpc-js-healthcheck
- Homepage: https://github.com/khacminh/grpc-js-healthcheck#readme
- Issues: https://github.com/khacminh/grpc-js-healthcheck/issues
- npm.io page: https://npm.io/package/grpc-js-health-check

## Dependencies (3)

- [lodash](https://npm.io/package/lodash.md) ^4.17.21
- [@grpc/grpc-js](https://npm.io/package/@grpc/grpc-js.md) ^1.9.13
- [@grpc/proto-loader](https://npm.io/package/@grpc/proto-loader.md) ^0.7.10

## Alternatives

- [jsforce](https://npm.io/package/jsforce.md) — 851.2K weekly downloads
- [react-native-qrcode-svg](https://npm.io/package/react-native-qrcode-svg.md) — 693.5K weekly downloads
- [@salesforce/plugin-data](https://npm.io/package/@salesforce/plugin-data.md) — 394.9K weekly downloads
- [@backstage/plugin-search-common](https://npm.io/package/@backstage/plugin-search-common.md) — 308.5K weekly downloads
- [@chain-registry/types](https://npm.io/package/@chain-registry/types.md) — 38.4K weekly downloads

## Recent versions

- 1.2.2 (latest) — 2023-12-13
- 1.2.1 — 2023-12-13
- 1.2.0 — 2023-12-13
- 1.1.0 — 2023-03-10
- 1.0.2 — 2021-05-27
- 1.0.1 — 2020-12-15
- 1.0.0 — 2020-12-15

## README

# grpc-js-health-check

Implementation for gRPC health check using [@grpc/grpc-js](https://www.npmjs.com/package/@grpc/grpc-js)

This package is drop-in replacement for [grpc-health-check](https://www.npmjs.com/package/grpc-health-check)

## Example

```js
const { servingStatus, Implementation, service } = require('grpc-js-health-check');

const statusMap = {
  '': servingStatus.SERVING,
  'ServiceFoo': servingStatus.NOT_SERVING,
  'ServiceBar': servingStatus.SERVING,
};
const healthImpl = new Implementation(statusMap);

// add to gRPC server
server.addService(service, healthImpl);

// set service status
healthImpl.setStatus('ServiceFoo', servingStatus.SERVING);
```

> For more example, please take a look on the [test](https://github.com/khacminh/grpc-js-healthcheck/tree/main/test)

## Change notes

### Version 1.2.x

- Implement `watch` method
- Update the dependencies
- Dependencies:
  - @grpc/grpc-js: 1.9.13
  - @grpc/proto-loader: 0.7.10

### Version 1.1.x

- Update the dependencies
- Dependencies:
  - @grpc/grpc-js: 1.8.12
  - @grpc/proto-loader: 0.7.5

### Version 1.0.x

- First release, this package is drop-in replacement for [grpc-health-check](https://www.npmjs.com/package/grpc-health-check)
- Dependencies:
  - @grpc/grpc-js: 1.2.2
  - @grpc/proto-loader: 0.5.5

---
_Source: https://npm.io/package/grpc-js-health-check · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
