import { Pool } from 'pg'; import { Metric } from 'prom-client'; import { DbLogger } from '../common'; /** * Creates a `Gauge` metric with the name `ax_postgres__connectivity` which can be added to a metric Registry. * This metric will have a value of `1` if the Database can be reached via the corresponding Pool (within the given timeout), * or a value of `0` otherwise. * * @param pgPool The Postgres Pool to use for checking the connectivity. The connectivity test will be done at the point of metric collection. * @param pgPoolType The Postgres Pool to check connectivity for. * @param timeoutInMilliSeconds The maximum time the connectivity check will run during metric collection. Defaults to `10000ms`. * @returns A `Gauge` metric with a name `ax_postgres__connectivity`. */ export declare const createPostgresPoolConnectivityMetric: (logger: DbLogger, pgPool: Pool, pgPoolType: "dbOwnerPool" | "envOwnerPool" | "loginPool", timeoutInMilliSeconds?: number) => Metric; //# sourceMappingURL=postgres-metrics.d.ts.map