@malloydata/db-postgres 0.0.19 → 0.0.20-dev230110224239

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.
@@ -48,6 +48,7 @@ export declare class PostgresConnection implements Connection, StreamingConnecti
48
48
  rowLimit?: number;
49
49
  }): AsyncIterableIterator<QueryDataRow>;
50
50
  manifestTemporaryTable(sqlCommand: string): Promise<string>;
51
+ close(): Promise<void>;
51
52
  }
52
53
  export declare class PooledPostgresConnection extends PostgresConnection implements PooledConnection {
53
54
  private pool;
@@ -59,5 +60,6 @@ export declare class PooledPostgresConnection extends PostgresConnection impleme
59
60
  runSQLStream(sqlCommand: string, options?: {
60
61
  rowLimit?: number;
61
62
  }): AsyncIterableIterator<QueryDataRow>;
63
+ close(): Promise<void>;
62
64
  }
63
65
  export {};
@@ -310,6 +310,9 @@ class PostgresConnection {
310
310
  await this.runPostgresQuery(cmd, 1000, 0, false);
311
311
  return tableName;
312
312
  }
313
+ async close() {
314
+ return;
315
+ }
313
316
  }
314
317
  exports.PostgresConnection = PostgresConnection;
315
318
  class PooledPostgresConnection extends PostgresConnection {
@@ -364,6 +367,9 @@ class PooledPostgresConnection extends PostgresConnection {
364
367
  }
365
368
  releaseClient();
366
369
  }
370
+ async close() {
371
+ await this.drain();
372
+ }
367
373
  }
368
374
  exports.PooledPostgresConnection = PooledPostgresConnection;
369
375
  //# sourceMappingURL=postgres_connection.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@malloydata/db-postgres",
3
- "version": "0.0.19",
3
+ "version": "0.0.20-dev230110224239",
4
4
  "license": "GPL-2.0",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -18,7 +18,7 @@
18
18
  "prepublishOnly": "npm run build"
19
19
  },
20
20
  "dependencies": {
21
- "@malloydata/malloy": "^0.0.19",
21
+ "@malloydata/malloy": "^0.0.20-dev230110224239",
22
22
  "@types/pg": "^8.6.1",
23
23
  "pg": "^8.7.1",
24
24
  "pg-query-stream": "4.2.3"