@quillsql/node 0.4.7 → 0.4.8
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 +1 -1
- package/dist/index.js +7 -7
- package/package.json +1 -1
- package/src/index.ts +5 -5
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -12,7 +12,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
12
12
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.DatabaseType = void 0;
|
|
15
|
+
exports.Quill = exports.DatabaseType = void 0;
|
|
16
16
|
const CachedConnection_1 = require("./db/CachedConnection");
|
|
17
17
|
const axios_1 = __importDefault(require("axios"));
|
|
18
18
|
require("dotenv/config");
|
|
@@ -29,7 +29,7 @@ var DatabaseType;
|
|
|
29
29
|
DatabaseType["bigquery"] = "bigquery";
|
|
30
30
|
DatabaseType["mysql"] = "mysql";
|
|
31
31
|
})(DatabaseType || (exports.DatabaseType = DatabaseType = {}));
|
|
32
|
-
class
|
|
32
|
+
class Quill {
|
|
33
33
|
constructor(data) {
|
|
34
34
|
const { privateKey, databaseType, databaseConnectionString, databaseConfig, cache, metadataServerURL, } = data;
|
|
35
35
|
this.baseUrl = metadataServerURL ? metadataServerURL : HOST;
|
|
@@ -173,9 +173,9 @@ class QuillClass {
|
|
|
173
173
|
});
|
|
174
174
|
}
|
|
175
175
|
}
|
|
176
|
-
exports.
|
|
177
|
-
const
|
|
178
|
-
return new
|
|
176
|
+
exports.Quill = Quill;
|
|
177
|
+
const requireQuill = ({ privateKey, databaseConnectionString, databaseConfig, cache, databaseType, metadataServerURL, }) => {
|
|
178
|
+
return new Quill({
|
|
179
179
|
privateKey,
|
|
180
180
|
databaseType,
|
|
181
181
|
databaseConnectionString,
|
|
@@ -184,9 +184,9 @@ const Quill = ({ privateKey, databaseConnectionString, databaseConfig, cache, da
|
|
|
184
184
|
metadataServerURL,
|
|
185
185
|
});
|
|
186
186
|
};
|
|
187
|
-
module.exports =
|
|
187
|
+
module.exports = requireQuill;
|
|
188
|
+
module.exports.default = requireQuill;
|
|
188
189
|
module.exports.Quill = Quill;
|
|
189
|
-
module.exports.default = Quill;
|
|
190
190
|
module.exports.getTablesBySchemaByDatabase = DatabaseHelper_1.getTablesBySchemaByDatabase;
|
|
191
191
|
module.exports.getDatabaseCredentials = DatabaseHelper_1.getDatabaseCredentials;
|
|
192
192
|
module.exports.getColumnsByTableByDatabase = DatabaseHelper_1.getColumnsByTableByDatabase;
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -44,7 +44,7 @@ export enum DatabaseType {
|
|
|
44
44
|
mysql = "mysql",
|
|
45
45
|
}
|
|
46
46
|
|
|
47
|
-
export
|
|
47
|
+
export class Quill {
|
|
48
48
|
// Configure cached connection pools with the given config.
|
|
49
49
|
public targetConnection;
|
|
50
50
|
private baseUrl: string;
|
|
@@ -265,7 +265,7 @@ export default class QuillClass {
|
|
|
265
265
|
}
|
|
266
266
|
}
|
|
267
267
|
|
|
268
|
-
const
|
|
268
|
+
const requireQuill = ({
|
|
269
269
|
privateKey,
|
|
270
270
|
databaseConnectionString,
|
|
271
271
|
databaseConfig,
|
|
@@ -280,7 +280,7 @@ const Quill = ({
|
|
|
280
280
|
databaseConfig: any;
|
|
281
281
|
metadataServerURL?: string;
|
|
282
282
|
}) => {
|
|
283
|
-
return new
|
|
283
|
+
return new Quill({
|
|
284
284
|
privateKey,
|
|
285
285
|
databaseType,
|
|
286
286
|
databaseConnectionString,
|
|
@@ -290,9 +290,9 @@ const Quill = ({
|
|
|
290
290
|
});
|
|
291
291
|
};
|
|
292
292
|
|
|
293
|
-
module.exports =
|
|
293
|
+
module.exports = requireQuill;
|
|
294
|
+
module.exports.default = requireQuill;
|
|
294
295
|
module.exports.Quill = Quill;
|
|
295
|
-
module.exports.default = Quill;
|
|
296
296
|
module.exports.getTablesBySchemaByDatabase = getTablesBySchemaByDatabase;
|
|
297
297
|
module.exports.getDatabaseCredentials = getDatabaseCredentials;
|
|
298
298
|
module.exports.getColumnsByTableByDatabase = getColumnsByTableByDatabase;
|