@golemio/pid 2.7.10-dev.914708721 → 2.7.10-rc.926084951
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.
|
@@ -19,6 +19,7 @@ const integration_engine_1 = require("@golemio/core/dist/integration-engine");
|
|
|
19
19
|
const ContainerToken_1 = require("@golemio/core/dist/integration-engine/ioc/ContainerToken");
|
|
20
20
|
const golemio_validator_1 = require("@golemio/core/dist/shared/golemio-validator");
|
|
21
21
|
const tsyringe_1 = require("@golemio/core/dist/shared/tsyringe");
|
|
22
|
+
const DEFAULT_API_LIMIT = 5000;
|
|
22
23
|
let GrafanaLokiDataSourceProvider = exports.GrafanaLokiDataSourceProvider = GrafanaLokiDataSourceProvider_1 = class GrafanaLokiDataSourceProvider {
|
|
23
24
|
constructor(config) {
|
|
24
25
|
this.config = config;
|
|
@@ -27,10 +28,12 @@ let GrafanaLokiDataSourceProvider = exports.GrafanaLokiDataSourceProvider = Graf
|
|
|
27
28
|
return new integration_engine_1.DataSource(GrafanaLokiDataSourceProvider_1.DATASOURCE_NAME, this.getProtocolStrategy(params), new integration_engine_1.JSONDataTypeStrategy({ resultsPath: "data.result" }), new golemio_validator_1.JSONSchemaValidator(GrafanaLokiDataSourceProvider_1.DATASOURCE_NAME, datasources_1.grafanaLokiJsonSchema));
|
|
28
29
|
}
|
|
29
30
|
getProtocolStrategy(params) {
|
|
31
|
+
var _a;
|
|
30
32
|
const url = new URL("/loki/api/v1/query_range", this.config.datasources.GrafanaLokiApiUrl);
|
|
31
33
|
url.searchParams.set("start", params.start.toString());
|
|
32
34
|
url.searchParams.set("end", params.end.toString());
|
|
33
35
|
url.searchParams.set("query", params.query);
|
|
36
|
+
url.searchParams.set("limit", (_a = this.config.datasources.GrafanaLokiApiLimit) !== null && _a !== void 0 ? _a : DEFAULT_API_LIMIT);
|
|
34
37
|
return new integration_engine_1.HTTPProtocolStrategy({
|
|
35
38
|
method: "GET",
|
|
36
39
|
url: url.toString(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GrafanaLokiDataSourceProvider.js","sourceRoot":"","sources":["../../../../../../../src/integration-engine/ropid-gtfs/workers/presets/datasources/grafana-loki/GrafanaLokiDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AACA,+GAAsF;AAEtF,8EAA4H;AAE5H,6FAA0F;AAC1F,mFAAkF;AAClF,iEAAwE;
|
|
1
|
+
{"version":3,"file":"GrafanaLokiDataSourceProvider.js","sourceRoot":"","sources":["../../../../../../../src/integration-engine/ropid-gtfs/workers/presets/datasources/grafana-loki/GrafanaLokiDataSourceProvider.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AACA,+GAAsF;AAEtF,8EAA4H;AAE5H,6FAA0F;AAC1F,mFAAkF;AAClF,iEAAwE;AAQxE,MAAM,iBAAiB,GAAG,IAAI,CAAC;AAGxB,IAAM,6BAA6B,6EAAnC,MAAM,6BAA6B;IAGtC,YAAmD,MAAsB;QAAtB,WAAM,GAAN,MAAM,CAAgB;IAAG,CAAC;IAEtE,aAAa,CAAC,MAAoB;QACrC,OAAO,IAAI,+BAAU,CACjB,+BAA6B,CAAC,eAAe,EAC7C,IAAI,CAAC,mBAAmB,CAAC,MAAM,CAAC,EAChC,IAAI,yCAAoB,CAAC,EAAE,WAAW,EAAE,aAAa,EAAE,CAAC,EACxD,IAAI,uCAAmB,CAAC,+BAA6B,CAAC,eAAe,EAAE,mCAAqB,CAAC,CAChG,CAAC;IACN,CAAC;IAEO,mBAAmB,CAAC,MAAoB;;QAC5C,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,0BAA0B,EAAE,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,iBAAiB,CAAC,CAAC;QAC3F,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,OAAO,EAAE,MAAM,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC,CAAC;QACvD,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,KAAK,EAAE,MAAM,CAAC,GAAG,CAAC,QAAQ,EAAE,CAAC,CAAC;QACnD,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,OAAO,EAAE,MAAM,CAAC,KAAK,CAAC,CAAC;QAC5C,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,OAAO,EAAE,MAAA,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,mBAAmB,mCAAI,iBAAiB,CAAC,CAAC;QAEhG,OAAO,IAAI,yCAAoB,CAAC;YAC5B,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,GAAG,CAAC,QAAQ,EAAE;YACnB,OAAO,EAAE,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,qBAAqB;YACtD,OAAO,EAAE,KAAK,EAAE,aAAa;SAChC,CAAC,CAAC;IACP,CAAC;;AA1Bc,6CAAe,GAAG,uBAAuB,AAA1B,CAA2B;wCADhD,6BAA6B;IADzC,IAAA,qBAAU,GAAE;IAII,WAAA,IAAA,iBAAM,EAAC,+BAAc,CAAC,MAAM,CAAC,CAAA;;GAHjC,6BAA6B,CA4BzC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@golemio/pid",
|
|
3
|
-
"version": "2.7.10-
|
|
3
|
+
"version": "2.7.10-rc.926084951",
|
|
4
4
|
"description": "Golemio PID Module",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@apideck/portman": "^1.16.1",
|
|
39
39
|
"@commitlint/cli": "^11.0.0",
|
|
40
40
|
"@commitlint/config-conventional": "^11.0.0",
|
|
41
|
-
"@golemio/cli": "1.4.
|
|
41
|
+
"@golemio/cli": "1.4.4",
|
|
42
42
|
"@golemio/core": "1.8.2",
|
|
43
43
|
"@golemio/db-common": "1.1.1",
|
|
44
44
|
"@golemio/eslint-config": "1.1.1",
|