refactored db's and browser
This commit is contained in:
parent
a0a3b26177
commit
89cbfb7848
12 changed files with 111 additions and 39 deletions
|
|
@ -1,5 +1,4 @@
|
|||
import { Pool } from 'pg';
|
||||
import { getLogger } from '@stock-bot/logger';
|
||||
import { QuestDBHealthMonitor } from './health';
|
||||
import { QuestDBInfluxWriter } from './influx-writer';
|
||||
import { QuestDBQueryBuilder } from './query-builder';
|
||||
|
|
@ -21,14 +20,15 @@ export class QuestDBClient {
|
|||
private pgPool: Pool | null = null;
|
||||
private readonly config: QuestDBClientConfig;
|
||||
private readonly options: QuestDBConnectionOptions;
|
||||
private readonly logger = getLogger('QuestDBClient');
|
||||
private readonly logger: any;
|
||||
private readonly healthMonitor: QuestDBHealthMonitor;
|
||||
private readonly influxWriter: QuestDBInfluxWriter;
|
||||
private readonly schemaManager: QuestDBSchemaManager;
|
||||
private isConnected = false;
|
||||
|
||||
constructor(config: QuestDBClientConfig, options?: QuestDBConnectionOptions) {
|
||||
constructor(config: QuestDBClientConfig, logger?: any, options?: QuestDBConnectionOptions) {
|
||||
this.config = config;
|
||||
this.logger = logger || console;
|
||||
this.options = {
|
||||
protocol: 'pg',
|
||||
retryAttempts: 3,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue