@axinom/mosaic-db-common 0.31.0-rc.8 → 0.31.0

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.
package/dist/index.d.ts CHANGED
@@ -6,7 +6,6 @@ export * from './messaging';
6
6
  export * from './middleware';
7
7
  export * from './migrations';
8
8
  export * from './monitoring';
9
- export * from './pg-types-extension';
10
9
  export * from './replication';
11
10
  export * from './zapatos';
12
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,sBAAsB,CAAC;AACrC,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,aAAa,CAAC;AAC5B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC"}
package/dist/index.js CHANGED
@@ -22,7 +22,6 @@ __exportStar(require("./messaging"), exports);
22
22
  __exportStar(require("./middleware"), exports);
23
23
  __exportStar(require("./migrations"), exports);
24
24
  __exportStar(require("./monitoring"), exports);
25
- __exportStar(require("./pg-types-extension"), exports);
26
25
  __exportStar(require("./replication"), exports);
27
26
  __exportStar(require("./zapatos"), exports);
28
27
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,wCAAsB;AACtB,2CAAyB;AACzB,8CAA4B;AAC5B,8CAA4B;AAC5B,+CAA6B;AAC7B,+CAA6B;AAC7B,+CAA6B;AAC7B,uDAAqC;AACrC,gDAA8B;AAC9B,4CAA0B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,wCAAsB;AACtB,2CAAyB;AACzB,8CAA4B;AAC5B,8CAA4B;AAC5B,+CAA6B;AAC7B,+CAA6B;AAC7B,+CAA6B;AAC7B,gDAA8B;AAC9B,4CAA0B"}
@@ -10,5 +10,5 @@ import { Metric } from 'prom-client';
10
10
  * @param timeoutInMilliSeconds The maximum time the connectivity check will run during metric collection. Defaults to `1000ms`.
11
11
  * @returns A `Gauge` metric with a name `ax_postgres_<pgPoolType>_connectivity`.
12
12
  */
13
- export declare const CreatePostgresPoolConnectivityMetric: (pgPool: Pool, pgPoolType: 'dbOwnerPool' | 'envOwnerPool' | 'loginPool', timeoutInMilliSeconds?: number) => Metric<string>;
13
+ export declare const createPostgresPoolConnectivityMetric: (pgPool: Pool, pgPoolType: 'dbOwnerPool' | 'envOwnerPool' | 'loginPool', timeoutInMilliSeconds?: number) => Metric<string>;
14
14
  //# sourceMappingURL=postgres-metrics.d.ts.map
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.CreatePostgresPoolConnectivityMetric = void 0;
3
+ exports.createPostgresPoolConnectivityMetric = void 0;
4
4
  const prom_client_1 = require("prom-client");
5
5
  const createTimeout = (timeoutInMilliSeconds) => new Promise((_, reject) => setTimeout(() => reject(), timeoutInMilliSeconds));
6
6
  /**
@@ -13,7 +13,7 @@ const createTimeout = (timeoutInMilliSeconds) => new Promise((_, reject) => setT
13
13
  * @param timeoutInMilliSeconds The maximum time the connectivity check will run during metric collection. Defaults to `1000ms`.
14
14
  * @returns A `Gauge` metric with a name `ax_postgres_<pgPoolType>_connectivity`.
15
15
  */
16
- const CreatePostgresPoolConnectivityMetric = (pgPool, pgPoolType, timeoutInMilliSeconds = 1000) => {
16
+ const createPostgresPoolConnectivityMetric = (pgPool, pgPoolType, timeoutInMilliSeconds = 1000) => {
17
17
  return new prom_client_1.Gauge({
18
18
  name: `ax_postgres_${pgPoolType}_connectivity`,
19
19
  help: `Connection status from the service to the database via the ${pgPoolType}`,
@@ -31,5 +31,5 @@ const CreatePostgresPoolConnectivityMetric = (pgPool, pgPoolType, timeoutInMilli
31
31
  },
32
32
  });
33
33
  };
34
- exports.CreatePostgresPoolConnectivityMetric = CreatePostgresPoolConnectivityMetric;
34
+ exports.createPostgresPoolConnectivityMetric = createPostgresPoolConnectivityMetric;
35
35
  //# sourceMappingURL=postgres-metrics.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@axinom/mosaic-db-common",
3
- "version": "0.31.0-rc.8",
3
+ "version": "0.31.0",
4
4
  "description": "This library encapsulates database-related functionality to develop Mosaic based services.",
5
5
  "author": "Axinom",
6
6
  "license": "PROPRIETARY",
@@ -52,5 +52,5 @@
52
52
  "publishConfig": {
53
53
  "access": "public"
54
54
  },
55
- "gitHead": "0084d2e6178cb09c709e990af6f0267db691d4be"
55
+ "gitHead": "e583a1076964626d1d0b1f9fb507d1defc307102"
56
56
  }
package/src/index.ts CHANGED
@@ -6,6 +6,5 @@ export * from './messaging';
6
6
  export * from './middleware';
7
7
  export * from './migrations';
8
8
  export * from './monitoring';
9
- export * from './pg-types-extension';
10
9
  export * from './replication';
11
10
  export * from './zapatos';
@@ -16,7 +16,7 @@ const createTimeout = (timeoutInMilliSeconds: number): Promise<void> =>
16
16
  * @param timeoutInMilliSeconds The maximum time the connectivity check will run during metric collection. Defaults to `1000ms`.
17
17
  * @returns A `Gauge` metric with a name `ax_postgres_<pgPoolType>_connectivity`.
18
18
  */
19
- export const CreatePostgresPoolConnectivityMetric = (
19
+ export const createPostgresPoolConnectivityMetric = (
20
20
  pgPool: Pool,
21
21
  pgPoolType: 'dbOwnerPool' | 'envOwnerPool' | 'loginPool',
22
22
  timeoutInMilliSeconds = 1000,
@@ -1,7 +0,0 @@
1
- import 'pg';
2
- declare module 'pg' {
3
- interface ClientConfig {
4
- lock_timeout?: string;
5
- }
6
- }
7
- //# sourceMappingURL=pg-types-extension.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"pg-types-extension.d.ts","sourceRoot":"","sources":["../src/pg-types-extension.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,CAAC;AAIZ,OAAO,QAAQ,IAAI,CAAC;IAClB,UAAU,YAAY;QACpB,YAAY,CAAC,EAAE,MAAM,CAAC;KACvB;CACF"}
@@ -1,4 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- require("pg");
4
- //# sourceMappingURL=pg-types-extension.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"pg-types-extension.js","sourceRoot":"","sources":["../src/pg-types-extension.ts"],"names":[],"mappings":";;AAAA,cAAY"}
@@ -1,9 +0,0 @@
1
- import 'pg';
2
-
3
- // TODO: this file can be dropped when @types/pg packages starts supporting
4
- // lock_timeout. Last checked @types/pg version: 8.10.9
5
- declare module 'pg' {
6
- interface ClientConfig {
7
- lock_timeout?: string;
8
- }
9
- }