@thzero/library_server_fastify 0.17.23 → 0.17.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +2 -2
  2. package/routes/health.js +0 -42
package/package.json CHANGED
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "name": "@thzero/library_server_fastify",
3
3
  "type": "module",
4
- "version": "0.17.23",
4
+ "version": "0.17.24",
5
5
  "version_major": 0,
6
6
  "version_minor": 17,
7
- "version_patch": 23,
7
+ "version_patch": 24,
8
8
  "version_date": "01/23/2024",
9
9
  "description": "An opinionated library of common functionality to bootstrap a Fastify based API application.",
10
10
  "author": "thZero",
package/routes/health.js DELETED
@@ -1,42 +0,0 @@
1
- import LibraryCommonnConstants from '@thzero/library_common/constants.js';
2
- import LibraryServerConstants from '@thzero/library_server/constants.js';
3
-
4
- import BaseRoute from './index.js';
5
-
6
- class HealthRoute extends BaseRoute {
7
- constructor(prefix) {
8
- super(prefix ? prefix : '');
9
- }
10
-
11
- get id() {
12
- return 'health';
13
- }
14
-
15
- async init(injector, app, config) {
16
- await super.init(injector, app, config);
17
- // this._serviceHealth = injector.getService(LibraryServerConstants.InjectorKeys.SERVICE_HEALTH);
18
- this._inject(app, injector, LibraryServerConstants.InjectorKeys.SERVICE_HEALTH, LibraryServerConstants.InjectorKeys.SERVICE_HEALTH);
19
- }
20
-
21
- get id() {
22
- return 'plans';
23
- }
24
-
25
- _initializeRoutes(router) {
26
- router.get(this._join(''),
27
- // eslint-disable-next-line
28
- async (request, reply) => {
29
- // const service = this._injector.getService(LibraryServerConstants.InjectorKeys.SERVICE_HEALTH);
30
- const response = (await router[LibraryServerConstants.InjectorKeys.SERVICE_HEALTH].health(request.correlationId)).check(request);
31
- // https://github.com/fastify/fastify-compress/issues/215#issuecomment-1210598312
32
- return this._jsonResponse(reply, response);
33
- }
34
- );
35
- }
36
-
37
- get _version() {
38
- return 'v1';
39
- }
40
- }
41
-
42
- export default HomHealthRouteeRoute;