@speedkit/cli 4.36.1 → 4.36.2
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/CHANGELOG.md +7 -0
- package/dist/base/sk-command.d.ts +41 -0
- package/dist/base/sk-command.js +56 -0
- package/dist/commands/auto-prewarm.d.ts +6 -4
- package/dist/commands/auto-prewarm.js +13 -66
- package/dist/commands/autocomplete/fish.d.ts +2 -2
- package/dist/commands/autocomplete/fish.js +3 -2
- package/dist/commands/browser/clean.d.ts +2 -2
- package/dist/commands/browser/clean.js +6 -6
- package/dist/commands/browser/list.d.ts +2 -2
- package/dist/commands/browser/list.js +6 -7
- package/dist/commands/browser/update.d.ts +2 -2
- package/dist/commands/browser/update.js +9 -11
- package/dist/commands/bulk-deploy.d.ts +4 -2
- package/dist/commands/bulk-deploy.js +7 -37
- package/dist/commands/config/edit.d.ts +2 -2
- package/dist/commands/config/edit.js +2 -2
- package/dist/commands/config/setup.d.ts +5 -2
- package/dist/commands/config/setup.js +9 -19
- package/dist/commands/deploy.d.ts +12 -3
- package/dist/commands/deploy.js +14 -20
- package/dist/commands/diff-url-parameters.d.ts +3 -2
- package/dist/commands/diff-url-parameters.js +19 -16
- package/dist/commands/extension/add.d.ts +2 -2
- package/dist/commands/extension/add.js +6 -6
- package/dist/commands/extension/devtools.d.ts +2 -2
- package/dist/commands/extension/devtools.js +6 -7
- package/dist/commands/extension/list.d.ts +2 -2
- package/dist/commands/extension/list.js +5 -6
- package/dist/commands/extension/remove.d.ts +2 -2
- package/dist/commands/extension/remove.js +6 -6
- package/dist/commands/extension/update.d.ts +2 -2
- package/dist/commands/extension/update.js +5 -6
- package/dist/commands/find-pops.d.ts +2 -2
- package/dist/commands/find-pops.js +10 -11
- package/dist/commands/generate-customer-config.d.ts +5 -2
- package/dist/commands/generate-customer-config.js +9 -27
- package/dist/commands/generate-pop-config.d.ts +2 -2
- package/dist/commands/generate-pop-config.js +19 -15
- package/dist/commands/login.d.ts +2 -2
- package/dist/commands/login.js +6 -9
- package/dist/commands/onboarding.d.ts +18 -3
- package/dist/commands/onboarding.js +13 -11
- package/dist/commands/origin-request.d.ts +4 -2
- package/dist/commands/origin-request.js +10 -42
- package/dist/commands/prewarm.d.ts +4 -2
- package/dist/commands/prewarm.js +12 -56
- package/dist/commands/pull.d.ts +4 -2
- package/dist/commands/pull.js +9 -14
- package/dist/commands/query/parameter.d.ts +4 -2
- package/dist/commands/query/parameter.js +12 -19
- package/dist/commands/query/prewarm.d.ts +4 -2
- package/dist/commands/query/prewarm.js +16 -23
- package/dist/commands/revalidate.d.ts +4 -2
- package/dist/commands/revalidate.js +13 -56
- package/dist/commands/wpt-launcher.d.ts +2 -2
- package/dist/commands/wpt-launcher.js +16 -17
- package/dist/hooks/init/first-run.js +9 -10
- package/dist/models/context.d.ts +24 -0
- package/dist/models/context.js +31 -0
- package/dist/services/athena/athena-flags.d.ts +18 -0
- package/dist/services/athena/athena-flags.js +29 -0
- package/dist/services/athena/athena-service-build-context.d.ts +25 -0
- package/dist/services/athena/athena-service-build-context.js +4 -0
- package/dist/services/athena/athena-service-factory.d.ts +3 -16
- package/dist/services/athena/athena-service-factory.js +11 -27
- package/dist/services/athena/baqend-athena-service.d.ts +3 -14
- package/dist/services/athena/baqend-athena-service.js +8 -16
- package/dist/services/athena/index.d.ts +1 -0
- package/dist/services/athena/index.js +1 -0
- package/dist/services/athena/spec/baqend-athena-service.spec.js +2 -2
- package/dist/services/browser-fetch/browser-origin-fetch.d.ts +2 -2
- package/dist/services/browser-fetch/browser-origin-fetch.js +1 -1
- package/dist/services/browser-fetch/browser-origin-fetcher.d.ts +3 -3
- package/dist/services/browser-fetch/browser-origin-fetcher.js +5 -5
- package/dist/services/browser-fetch/spec/browser-origin-fetch.spec.js +10 -10
- package/dist/services/cli/cli-environment-factory.d.ts +25 -0
- package/dist/services/cli/cli-environment-factory.js +30 -0
- package/dist/services/cli/cli-environment.d.ts +73 -0
- package/dist/services/cli/cli-environment.js +216 -0
- package/dist/services/cli/cli-service-build-context.d.ts +10 -0
- package/dist/services/cli/cli-service-build-context.js +4 -0
- package/dist/services/cli/cli-service-factory.d.ts +7 -7
- package/dist/services/cli/cli-service-factory.js +7 -7
- package/dist/services/cli/cli-service-model.d.ts +0 -4
- package/dist/services/cli/cli-service-model.js +0 -6
- package/dist/services/cli/cli-service.d.ts +16 -2
- package/dist/services/cli/cli-service.js +17 -18
- package/dist/services/cli/cli-settings.d.ts +37 -0
- package/dist/services/cli/cli-settings.js +23 -0
- package/dist/services/cli/command-build-context.d.ts +23 -0
- package/dist/services/cli/index.d.ts +5 -1
- package/dist/services/cli/index.js +5 -1
- package/dist/services/cli/spec/cli-environment-detection.spec.js +52 -0
- package/dist/services/cli/spec/cli-environment.spec.js +125 -0
- package/dist/services/cli/spec/cli-service.spec.js +9 -19
- package/dist/services/config-api/client.d.ts +3 -3
- package/dist/services/config-api/client.js +4 -4
- package/dist/services/config-api/config-api-factory.js +3 -3
- package/dist/services/config-api/entity-manager-provider.d.ts +11 -0
- package/dist/services/config-api/{entity-manager-factory.js → entity-manager-provider.js} +7 -1
- package/dist/services/customer-config/customer-config-service-build-context.d.ts +33 -0
- package/dist/services/customer-config/customer-config-service-build-context.js +36 -0
- package/dist/services/customer-config/customer-config-service-factory.d.ts +3 -4
- package/dist/services/customer-config/customer-config-service-factory.js +5 -8
- package/dist/services/customer-config/customer-config-service.d.ts +2 -2
- package/dist/services/customer-config/index.d.ts +1 -1
- package/dist/services/customer-config/index.js +1 -1
- package/dist/services/customer-config/site-analyzer/index.d.ts +1 -0
- package/dist/services/customer-config/site-analyzer/index.js +1 -0
- package/dist/services/customer-config/site-analyzer/site-analyzer-service-build-context.d.ts +6 -0
- package/dist/services/customer-config/site-analyzer/site-analyzer-service-build-context.js +4 -0
- package/dist/services/customer-config/site-analyzer/site-analyzer-service-factory.d.ts +3 -3
- package/dist/services/customer-config/site-analyzer/site-analyzer-service-factory.js +4 -5
- package/dist/services/deploy/bulk/bulk-deploy-model.d.ts +0 -25
- package/dist/services/deploy/bulk/bulk-deploy-model.js +1 -27
- package/dist/services/deploy/bulk/bulk-deploy-service-build-context.d.ts +51 -0
- package/dist/services/deploy/bulk/bulk-deploy-service-build-context.js +50 -0
- package/dist/services/deploy/bulk/bulk-deploy-service-factory.d.ts +2 -4
- package/dist/services/deploy/bulk/bulk-deploy-service-factory.js +2 -5
- package/dist/services/deploy/bulk/bulk-deploy-service.d.ts +3 -2
- package/dist/services/deploy/bulk/config-deploy-factory.d.ts +3 -3
- package/dist/services/deploy/bulk/config-deploy-factory.js +16 -8
- package/dist/services/deploy/bulk/index.d.ts +1 -0
- package/dist/services/deploy/bulk/index.js +1 -0
- package/dist/services/deploy/checks/activation/customer-approval-check.d.ts +3 -1
- package/dist/services/deploy/checks/activation/customer-approval-check.js +4 -2
- package/dist/services/deploy/checks/pre-deploy/device-detection-changed-check.d.ts +3 -1
- package/dist/services/deploy/checks/pre-deploy/device-detection-changed-check.js +4 -2
- package/dist/services/deploy/checks/pre-deploy/split-change-check.d.ts +3 -1
- package/dist/services/deploy/checks/pre-deploy/split-change-check.js +4 -2
- package/dist/services/deploy/deploy-service-build-context.d.ts +63 -0
- package/dist/services/deploy/deploy-service-build-context.js +64 -0
- package/dist/services/deploy/deploy-service-factory.d.ts +5 -8
- package/dist/services/deploy/deploy-service-factory.js +28 -19
- package/dist/services/deploy/mr/base-config-reader.d.ts +6 -4
- package/dist/services/deploy/mr/base-config-reader.js +6 -8
- package/dist/services/deploy/mr/index.d.ts +1 -0
- package/dist/services/deploy/mr/index.js +1 -0
- package/dist/services/deploy/mr/merge-request-deploy-model.d.ts +0 -35
- package/dist/services/deploy/mr/merge-request-deploy-model.js +0 -34
- package/dist/services/deploy/mr/merge-request-deploy-service-build-context.d.ts +32 -0
- package/dist/services/deploy/mr/merge-request-deploy-service-build-context.js +20 -0
- package/dist/services/deploy/mr/merge-request-deploy-service-factory.d.ts +2 -4
- package/dist/services/deploy/mr/merge-request-deploy-service-factory.js +31 -10
- package/dist/services/deploy/mr/merge-request-deploy-service.d.ts +3 -2
- package/dist/services/deploy/spec/bulk/bulk-deploy-service.spec.js +14 -3
- package/dist/services/deploy/spec/checks/activation/customer-approval-check.spec.js +7 -5
- package/dist/services/deploy/spec/checks/pre-deploy/split-change-check.spec.js +2 -1
- package/dist/services/diff/diff-service-build-context.d.ts +14 -0
- package/dist/services/diff/diff-service-build-context.js +4 -0
- package/dist/services/diff/diff-service-factory.d.ts +4 -5
- package/dist/services/diff/diff-service-factory.js +4 -7
- package/dist/services/diff/index.d.ts +1 -1
- package/dist/services/diff/index.js +1 -1
- package/dist/services/document-handler-runtime/{context/document-handler-runtime-context.d.ts → document-handler-runtime-model.d.ts} +0 -5
- package/dist/services/document-handler-runtime/document-handler-runtime-service-build-context.d.ts +11 -0
- package/dist/services/document-handler-runtime/document-handler-runtime-service-build-context.js +4 -0
- package/dist/services/document-handler-runtime/document-handler-server.js +2 -2
- package/dist/services/document-handler-runtime/factory/document-handler-runtime-service-factory.d.ts +3 -6
- package/dist/services/document-handler-runtime/factory/document-handler-runtime-service-factory.js +14 -14
- package/dist/services/document-handler-runtime/server/request.js +1 -1
- package/dist/services/document-handler-runtime/templates/database-mock.d.ts +1 -1
- package/dist/services/document-handler-runtime/templates/database-mock.js +1 -1
- package/dist/services/integration-api/customer-config-flags.d.ts +16 -0
- package/dist/services/integration-api/customer-config-flags.js +30 -0
- package/dist/services/integration-api/handler/install-resource-handler.d.ts +8 -0
- package/dist/services/integration-api/handler/install-resource-handler.js +10 -1
- package/dist/services/integration-api/index.d.ts +1 -0
- package/dist/services/integration-api/index.js +1 -0
- package/dist/services/integration-api/integration-api-factory.d.ts +4 -6
- package/dist/services/integration-api/integration-api-factory.js +11 -11
- package/dist/services/integration-api/integration-api-model.d.ts +0 -9
- package/dist/services/integration-api/integration-api-model.js +0 -16
- package/dist/services/integration-api/integration-api-service-build-context.d.ts +19 -0
- package/dist/services/integration-api/integration-api-service-build-context.js +4 -0
- package/dist/services/integration-api/spec/config-plugin.spec.js +1 -1
- package/dist/services/integration-api/spec/integration-api-service.spec.js +7 -3
- package/dist/services/integration-api/spec/speed-kit-config-file.spec.js +9 -2
- package/dist/services/integration-api/struct/config-plugin.d.ts +1 -1
- package/dist/services/integration-api/struct/config-plugin.js +12 -7
- package/dist/services/integration-api/struct/speed-kit-config-file.d.ts +18 -2
- package/dist/services/integration-api/struct/speed-kit-config-file.js +22 -12
- package/dist/services/integration-api/struct/speed-kit-config.d.ts +1 -1
- package/dist/services/onboarding/browser/config/browser-config.d.ts +3 -3
- package/dist/services/onboarding/browser/config/browser-config.js +5 -5
- package/dist/services/onboarding/browser/executable/executable-validator.d.ts +3 -3
- package/dist/services/onboarding/browser/executable/executable-validator.js +17 -15
- package/dist/services/onboarding/browser/extension/extension-downloader.d.ts +3 -3
- package/dist/services/onboarding/browser/extension/extension-downloader.js +6 -6
- package/dist/services/onboarding/browser/extension/extension-validator.d.ts +3 -3
- package/dist/services/onboarding/browser/extension/extension-validator.js +4 -4
- package/dist/services/onboarding/file-events/file-watcher.js +1 -0
- package/dist/services/onboarding/index.d.ts +1 -1
- package/dist/services/onboarding/index.js +1 -1
- package/dist/services/onboarding/onboarding-model.d.ts +8 -24
- package/dist/services/onboarding/onboarding-model.js +19 -87
- package/dist/services/onboarding/onboarding-service-build-context.d.ts +57 -0
- package/dist/services/onboarding/onboarding-service-build-context.js +67 -0
- package/dist/services/onboarding/onboarding-service-factory.d.ts +2 -5
- package/dist/services/onboarding/onboarding-service-factory.js +47 -34
- package/dist/services/onboarding/spec/onboarding-model.spec.js +11 -6
- package/dist/services/origin-request/index.d.ts +1 -1
- package/dist/services/origin-request/index.js +1 -1
- package/dist/services/origin-request/origin-request-service-build-context.d.ts +52 -0
- package/dist/services/origin-request/origin-request-service-build-context.js +54 -0
- package/dist/services/origin-request/origin-request-service-factory.d.ts +2 -5
- package/dist/services/origin-request/origin-request-service-factory.js +12 -12
- package/dist/services/origin-request/origin-request-service.d.ts +2 -2
- package/dist/services/pop-config/index.d.ts +1 -0
- package/dist/services/pop-config/index.js +1 -0
- package/dist/services/pop-config/pop-config-factory.d.ts +4 -1
- package/dist/services/pop-config/pop-config-factory.js +10 -3
- package/dist/services/pop-config/pop-config-service-build-context.d.ts +10 -0
- package/dist/services/pop-config/pop-config-service-build-context.js +4 -0
- package/dist/services/prewarm/auto-pre-warm-factory.d.ts +3 -31
- package/dist/services/prewarm/auto-pre-warm-factory.js +6 -11
- package/dist/services/prewarm/auto-pre-warm-service-build-context.d.ts +84 -0
- package/dist/services/prewarm/auto-pre-warm-service-build-context.js +68 -0
- package/dist/services/prewarm/index.d.ts +2 -0
- package/dist/services/prewarm/index.js +2 -0
- package/dist/services/prewarm/pre-warm-factory.d.ts +4 -5
- package/dist/services/prewarm/pre-warm-factory.js +6 -8
- package/dist/services/prewarm/pre-warm-model.d.ts +0 -10
- package/dist/services/prewarm/pre-warm-model.js +0 -18
- package/dist/services/prewarm/pre-warm-service-build-context.d.ts +47 -0
- package/dist/services/prewarm/pre-warm-service-build-context.js +64 -0
- package/dist/services/pull/index.d.ts +1 -0
- package/dist/services/pull/index.js +1 -0
- package/dist/services/pull/pull-service-build-context.d.ts +28 -0
- package/dist/services/pull/pull-service-build-context.js +17 -0
- package/dist/services/pull/pull-service-factory.d.ts +3 -5
- package/dist/services/pull/pull-service-factory.js +13 -14
- package/dist/services/pull/pull-service-model.d.ts +0 -5
- package/dist/services/pull/pull-service-model.js +0 -9
- package/dist/services/query-builder/query-builder-factory.d.ts +9 -7
- package/dist/services/query-builder/query-builder-factory.js +26 -15
- package/dist/{models/cli-parameters.d.ts → services/query-builder/query-builder-flags.d.ts} +1 -120
- package/dist/services/query-builder/query-builder-flags.js +150 -0
- package/dist/services/query-builder/query-builder-model.d.ts +1 -14
- package/dist/services/query-builder/query-builder-service-build-context.d.ts +113 -0
- package/dist/services/query-builder/query-builder-service-build-context.js +68 -0
- package/dist/services/query-builder/query-builder-service.d.ts +3 -3
- package/dist/services/query-builder/spec/query-builder-flags.spec.d.ts +1 -0
- package/dist/{models/spec/cli-parameters.spec.js → services/query-builder/spec/query-builder-flags.spec.js} +1 -1
- package/dist/services/revalidate/index.d.ts +1 -0
- package/dist/services/revalidate/index.js +1 -0
- package/dist/services/revalidate/revalidate-factory.d.ts +3 -5
- package/dist/services/revalidate/revalidate-factory.js +2 -6
- package/dist/services/revalidate/revalidate-model.d.ts +0 -9
- package/dist/services/revalidate/revalidate-model.js +0 -8
- package/dist/services/revalidate/revalidate-service-build-context.d.ts +38 -0
- package/dist/services/revalidate/revalidate-service-build-context.js +59 -0
- package/dist/services/setup/browser/browser-setup-service.d.ts +3 -4
- package/dist/services/setup/browser/browser-setup-service.js +16 -18
- package/dist/services/setup/difftool/difftool-setup-service.d.ts +3 -4
- package/dist/services/setup/difftool/difftool-setup-service.js +5 -7
- package/dist/services/setup/extension/extension-setup-service.d.ts +3 -4
- package/dist/services/setup/extension/extension-setup-service.js +8 -10
- package/dist/services/setup/index.d.ts +1 -1
- package/dist/services/setup/index.js +1 -1
- package/dist/services/setup/setup-service-build-context.d.ts +27 -0
- package/dist/services/setup/setup-service-build-context.js +26 -0
- package/dist/services/setup/setup-service-factory.d.ts +2 -6
- package/dist/services/setup/setup-service-factory.js +10 -18
- package/dist/services/setup/setup-service.d.ts +4 -5
- package/dist/services/setup/setup-service.js +6 -7
- package/oclif.manifest.json +1 -1
- package/package.json +4 -2
- package/dist/models/cli-parameters.js +0 -297
- package/dist/services/cli/cli-config.d.ts +0 -59
- package/dist/services/cli/cli-config.js +0 -180
- package/dist/services/cli/environment.d.ts +0 -15
- package/dist/services/cli/environment.js +0 -40
- package/dist/services/cli/spec/cli-config.spec.js +0 -117
- package/dist/services/cli/spec/environment.spec.js +0 -28
- package/dist/services/config-api/entity-manager-factory.d.ts +0 -5
- package/dist/services/customer-config/customer-config-service-context.d.ts +0 -13
- package/dist/services/customer-config/customer-config-service-context.js +0 -21
- package/dist/services/deploy/context/deploy-context.d.ts +0 -32
- package/dist/services/deploy/context/deploy-context.js +0 -72
- package/dist/services/diff/diff-model.d.ts +0 -9
- package/dist/services/diff/diff-model.js +0 -12
- package/dist/services/origin-request/origin-request-context.d.ts +0 -13
- package/dist/services/origin-request/origin-request-context.js +0 -23
- package/dist/services/query-builder/query-command.d.ts +0 -28
- package/dist/services/query-builder/query-command.js +0 -37
- package/dist/services/setup/setup-context.d.ts +0 -14
- package/dist/services/setup/setup-context.js +0 -15
- /package/dist/{models/spec/cli-parameters.spec.d.ts → services/cli/command-build-context.js} +0 -0
- /package/dist/services/cli/spec/{cli-config.spec.d.ts → cli-environment-detection.spec.d.ts} +0 -0
- /package/dist/services/cli/spec/{environment.spec.d.ts → cli-environment.spec.d.ts} +0 -0
- /package/dist/services/document-handler-runtime/{context/document-handler-runtime-context.js → document-handler-runtime-model.js} +0 -0
|
@@ -1,32 +1,15 @@
|
|
|
1
1
|
import { AthenaClient } from "@aws-sdk/client-athena";
|
|
2
2
|
import { safe } from "../../helpers/safe.js";
|
|
3
|
-
import { CliServiceFactory } from "../cli/index.js";
|
|
4
3
|
import { ATHENA_CONFIG } from "./athena-service-model.js";
|
|
5
4
|
import { FetchCredentialsError } from "./error/fetch-credentials-error.js";
|
|
6
5
|
import { AwsAthenaService } from "./athena-service.js";
|
|
7
6
|
import { BaqendAthenaService } from "./baqend-athena-service.js";
|
|
8
|
-
import {
|
|
7
|
+
import { EntityManagerProvider } from "../config-api/entity-manager-provider.js";
|
|
9
8
|
export class AthenaServiceFactory {
|
|
10
|
-
|
|
11
|
-
workgroup;
|
|
12
|
-
catalog;
|
|
13
|
-
cli;
|
|
9
|
+
context;
|
|
14
10
|
service;
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
* token only) as a fallback when no AWS login is present. Without it, only
|
|
18
|
-
* the AWS path is available.
|
|
19
|
-
* @param workgroup - Athena workgroup for the AWS path. The Baqend path has
|
|
20
|
-
* no such notion, so it is ignored there.
|
|
21
|
-
* @param catalog - the data catalog the tables live in. The Baqend path is
|
|
22
|
-
* told so it can recognise the prefix, not so it can use it: the server
|
|
23
|
-
* resolves the catalog itself.
|
|
24
|
-
*/
|
|
25
|
-
constructor(app, workgroup, catalog, cli) {
|
|
26
|
-
this.app = app;
|
|
27
|
-
this.workgroup = workgroup;
|
|
28
|
-
this.catalog = catalog;
|
|
29
|
-
this.cli = cli;
|
|
11
|
+
constructor(context) {
|
|
12
|
+
this.context = context;
|
|
30
13
|
}
|
|
31
14
|
async getService() {
|
|
32
15
|
if (!this.service) {
|
|
@@ -41,16 +24,17 @@ export class AthenaServiceFactory {
|
|
|
41
24
|
* path (which needs an `app`).
|
|
42
25
|
*/
|
|
43
26
|
async createService() {
|
|
44
|
-
const cli = this.cli
|
|
27
|
+
const cli = this.context.environment.cli;
|
|
28
|
+
const { app, workgroup, catalog } = this.context;
|
|
45
29
|
const client = await this.tryGetAthenaClient();
|
|
46
30
|
if (client) {
|
|
47
|
-
cli.comment(
|
|
48
|
-
? `Using AWS credentials for Athena queries, workgroup ${
|
|
31
|
+
cli.comment(workgroup
|
|
32
|
+
? `Using AWS credentials for Athena queries, workgroup ${workgroup}.`
|
|
49
33
|
: "Using AWS credentials for Athena queries.");
|
|
50
|
-
return new AwsAthenaService(client, cli,
|
|
34
|
+
return new AwsAthenaService(client, cli, workgroup, catalog);
|
|
51
35
|
}
|
|
52
|
-
if (
|
|
53
|
-
return new BaqendAthenaService(
|
|
36
|
+
if (app) {
|
|
37
|
+
return new BaqendAthenaService(app, new EntityManagerProvider(), cli, catalog);
|
|
54
38
|
}
|
|
55
39
|
throw new FetchCredentialsError("Cannot send Athena queries: no AWS credentials found and no app given for the Baqend API.");
|
|
56
40
|
}
|
|
@@ -1,27 +1,16 @@
|
|
|
1
1
|
import { AthenaBucket, AthenaParameter, AthenaService } from "./athena-query-service.js";
|
|
2
|
-
import {
|
|
2
|
+
import { EntityManagerProvider } from "../config-api/entity-manager-provider.js";
|
|
3
3
|
import { CliServiceInterface } from "../cli/index.js";
|
|
4
|
-
/**
|
|
5
|
-
* Runs Athena SQL through the Baqend API, authenticated by the app token only
|
|
6
|
-
* (no AWS login). Hits the native query path via
|
|
7
|
-
* `db["<bucket>"].executeQuery(sql, triggeredBy, ttl)`.
|
|
8
|
-
*
|
|
9
|
-
* Two normalizations vs the AWS path:
|
|
10
|
-
* - `?` placeholders are inlined (the native path has no parameter binding).
|
|
11
|
-
* - the catalog prefix is stripped — the server derives catalog and database
|
|
12
|
-
* itself, and a 3-part `<catalog>.<db>.<table>` reference fails there
|
|
13
|
-
* (verified against a live app), whereas 2-part `<db>.<table>` works.
|
|
14
|
-
*/
|
|
15
4
|
export declare class BaqendAthenaService implements AthenaService {
|
|
16
5
|
private app;
|
|
17
|
-
private
|
|
6
|
+
private entityManagerProvider;
|
|
18
7
|
private cli;
|
|
19
8
|
private static readonly TRIGGERED_BY;
|
|
20
9
|
/** A catalog qualifier in front of a `<db>.<table>` reference. */
|
|
21
10
|
private readonly catalogPrefix;
|
|
22
11
|
/** The catalog whose qualifier has to come back out of the query. */
|
|
23
12
|
private readonly catalog;
|
|
24
|
-
constructor(app: string,
|
|
13
|
+
constructor(app: string, entityManagerProvider: EntityManagerProvider, cli: CliServiceInterface,
|
|
25
14
|
/**
|
|
26
15
|
* The catalog the queries name. Whichever one the caller runs under, the
|
|
27
16
|
* prefix has to come back out here — so the name is read rather than
|
|
@@ -4,27 +4,16 @@ import { safe } from "../../helpers/safe.js";
|
|
|
4
4
|
function escapeRegExp(value) {
|
|
5
5
|
return value.replaceAll(/[.*+?^${}()|[\]\\]/g, String.raw `\$&`);
|
|
6
6
|
}
|
|
7
|
-
/**
|
|
8
|
-
* Runs Athena SQL through the Baqend API, authenticated by the app token only
|
|
9
|
-
* (no AWS login). Hits the native query path via
|
|
10
|
-
* `db["<bucket>"].executeQuery(sql, triggeredBy, ttl)`.
|
|
11
|
-
*
|
|
12
|
-
* Two normalizations vs the AWS path:
|
|
13
|
-
* - `?` placeholders are inlined (the native path has no parameter binding).
|
|
14
|
-
* - the catalog prefix is stripped — the server derives catalog and database
|
|
15
|
-
* itself, and a 3-part `<catalog>.<db>.<table>` reference fails there
|
|
16
|
-
* (verified against a live app), whereas 2-part `<db>.<table>` works.
|
|
17
|
-
*/
|
|
18
7
|
export class BaqendAthenaService {
|
|
19
8
|
app;
|
|
20
|
-
|
|
9
|
+
entityManagerProvider;
|
|
21
10
|
cli;
|
|
22
11
|
static TRIGGERED_BY = "speed-kit-cli";
|
|
23
12
|
/** A catalog qualifier in front of a `<db>.<table>` reference. */
|
|
24
13
|
catalogPrefix;
|
|
25
14
|
/** The catalog whose qualifier has to come back out of the query. */
|
|
26
15
|
catalog;
|
|
27
|
-
constructor(app,
|
|
16
|
+
constructor(app, entityManagerProvider, cli,
|
|
28
17
|
/**
|
|
29
18
|
* The catalog the queries name. Whichever one the caller runs under, the
|
|
30
19
|
* prefix has to come back out here — so the name is read rather than
|
|
@@ -32,7 +21,7 @@ export class BaqendAthenaService {
|
|
|
32
21
|
*/
|
|
33
22
|
catalog) {
|
|
34
23
|
this.app = app;
|
|
35
|
-
this.
|
|
24
|
+
this.entityManagerProvider = entityManagerProvider;
|
|
36
25
|
this.cli = cli;
|
|
37
26
|
this.catalog = athenaCatalog(catalog);
|
|
38
27
|
this.catalogPrefix = new RegExp(`^${escapeRegExp(this.catalog)}\\.[a-z_]\\w*\\.[a-z_]`, "i");
|
|
@@ -42,10 +31,13 @@ export class BaqendAthenaService {
|
|
|
42
31
|
throw new Error("BaqendAthenaService.getResult requires a bucket to target");
|
|
43
32
|
}
|
|
44
33
|
this.cli.startAction("ATHENA:QUERY", "execute athena query via baqend");
|
|
45
|
-
const db = await this.
|
|
34
|
+
const db = await this.entityManagerProvider.getEntityManager(this.app);
|
|
46
35
|
const sql = this.prepareQuery(query, parameters);
|
|
47
36
|
const ttl = `${maxAgeInMinutes}m`;
|
|
48
|
-
|
|
37
|
+
// The bucket entities are not in the SDK's types: an app has the ones its
|
|
38
|
+
// schema declares.
|
|
39
|
+
const entity = db[bucket];
|
|
40
|
+
const result = await safe(entity.executeQuery(sql, BaqendAthenaService.TRIGGERED_BY, ttl));
|
|
49
41
|
if (result.success === true) {
|
|
50
42
|
this.cli.successAction("ATHENA:QUERY");
|
|
51
43
|
return result.data;
|
|
@@ -2,5 +2,6 @@ export * from "./athena-query-service.js";
|
|
|
2
2
|
export * from "./athena-service.js";
|
|
3
3
|
export * from "./baqend-athena-service.js";
|
|
4
4
|
export * from "./athena-service-factory.js";
|
|
5
|
+
export * from "./athena-service-build-context.js";
|
|
5
6
|
export * from "./athena-service-model.js";
|
|
6
7
|
export * from "./error/fetch-credentials-error.js";
|
|
@@ -2,5 +2,6 @@ export * from "./athena-query-service.js";
|
|
|
2
2
|
export * from "./athena-service.js";
|
|
3
3
|
export * from "./baqend-athena-service.js";
|
|
4
4
|
export * from "./athena-service-factory.js";
|
|
5
|
+
export * from "./athena-service-build-context.js";
|
|
5
6
|
export * from "./athena-service-model.js";
|
|
6
7
|
export * from "./error/fetch-credentials-error.js";
|
|
@@ -9,7 +9,7 @@ const cli = {
|
|
|
9
9
|
writeError: () => undefined,
|
|
10
10
|
};
|
|
11
11
|
/** An entity manager that records the sql it was asked to run. */
|
|
12
|
-
function
|
|
12
|
+
function providerCapturing(sent) {
|
|
13
13
|
return {
|
|
14
14
|
getEntityManager: async () => ({
|
|
15
15
|
[AthenaBucket.RumPi]: {
|
|
@@ -24,7 +24,7 @@ function factoryCapturing(sent) {
|
|
|
24
24
|
/** The sql that reached the Baqend API for a query run under `catalog`. */
|
|
25
25
|
async function sentFor(query, catalog) {
|
|
26
26
|
const sent = [];
|
|
27
|
-
const service = new BaqendAthenaService("shop-de",
|
|
27
|
+
const service = new BaqendAthenaService("shop-de", providerCapturing(sent), cli, catalog);
|
|
28
28
|
await service.getResult(query, [], 60, AthenaBucket.RumPi);
|
|
29
29
|
return sent[0];
|
|
30
30
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CliEnvironment } from "../cli/index.js";
|
|
2
2
|
import { directOriginFetch } from "../../helpers/origin-proxy.js";
|
|
3
3
|
import { BrowserFetchLogger, BrowserOriginFetcher } from "./browser-origin-fetcher.js";
|
|
4
4
|
/**
|
|
@@ -17,7 +17,7 @@ export interface BrowserOriginFetchHandle {
|
|
|
17
17
|
close(): Promise<void>;
|
|
18
18
|
}
|
|
19
19
|
export interface BrowserOriginFetchOptions {
|
|
20
|
-
|
|
20
|
+
environment: CliEnvironment;
|
|
21
21
|
logger?: BrowserFetchLogger;
|
|
22
22
|
mode?: BrowserFetchMode;
|
|
23
23
|
/**
|
|
@@ -18,7 +18,7 @@ export function installBrowserOriginFetch(options) {
|
|
|
18
18
|
const mode = options.mode ?? "auto";
|
|
19
19
|
const direct = options.direct ?? directOriginFetch;
|
|
20
20
|
const fetcher = options.fetcher ??
|
|
21
|
-
new BrowserOriginFetcher(options.
|
|
21
|
+
new BrowserOriginFetcher(options.environment, options.logger);
|
|
22
22
|
/** Hosts a network fetch was refused by, which the browser serves from then on. */
|
|
23
23
|
const browserHosts = new Set();
|
|
24
24
|
const transport = async (url, init, fetchOptions) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Frame, HTTPRequest } from "puppeteer";
|
|
2
|
-
import {
|
|
2
|
+
import { CliEnvironment } from "../cli/index.js";
|
|
3
3
|
import { OriginFetchOptions } from "../../helpers/origin-proxy.js";
|
|
4
4
|
/** Only the writers this fetcher uses, so it does not depend on the whole CLI service. */
|
|
5
5
|
export interface BrowserFetchLogger {
|
|
@@ -45,7 +45,7 @@ export declare function isDocumentRequest(request: Pick<HTTPRequest, "isNavigati
|
|
|
45
45
|
* the access this fetcher exists to get. See `device-emulation.ts`.
|
|
46
46
|
*/
|
|
47
47
|
export declare class BrowserOriginFetcher {
|
|
48
|
-
private readonly
|
|
48
|
+
private readonly environment;
|
|
49
49
|
private readonly logger?;
|
|
50
50
|
private readonly navigationTimeout;
|
|
51
51
|
private browser?;
|
|
@@ -69,7 +69,7 @@ export declare class BrowserOriginFetcher {
|
|
|
69
69
|
private profile?;
|
|
70
70
|
/** When the session was last thrown away, so recovery cannot run per request. */
|
|
71
71
|
private lastRecycle;
|
|
72
|
-
constructor(
|
|
72
|
+
constructor(environment: CliEnvironment, logger?: BrowserFetchLogger, navigationTimeout?: number);
|
|
73
73
|
/**
|
|
74
74
|
* Fetches one origin URL through the browser.
|
|
75
75
|
*
|
|
@@ -105,7 +105,7 @@ export function isDocumentRequest(request, mainFrame) {
|
|
|
105
105
|
* the access this fetcher exists to get. See `device-emulation.ts`.
|
|
106
106
|
*/
|
|
107
107
|
export class BrowserOriginFetcher {
|
|
108
|
-
|
|
108
|
+
environment;
|
|
109
109
|
logger;
|
|
110
110
|
navigationTimeout;
|
|
111
111
|
browser;
|
|
@@ -129,8 +129,8 @@ export class BrowserOriginFetcher {
|
|
|
129
129
|
profile;
|
|
130
130
|
/** When the session was last thrown away, so recovery cannot run per request. */
|
|
131
131
|
lastRecycle = 0;
|
|
132
|
-
constructor(
|
|
133
|
-
this.
|
|
132
|
+
constructor(environment, logger, navigationTimeout = DEFAULT_NAVIGATION_TIMEOUT) {
|
|
133
|
+
this.environment = environment;
|
|
134
134
|
this.logger = logger;
|
|
135
135
|
this.navigationTimeout = navigationTimeout;
|
|
136
136
|
}
|
|
@@ -472,7 +472,7 @@ export class BrowserOriginFetcher {
|
|
|
472
472
|
const proxy = currentOriginProxy();
|
|
473
473
|
const browser = await puppeteer.launch({
|
|
474
474
|
headless: true,
|
|
475
|
-
executablePath: path.resolve(this.
|
|
475
|
+
executablePath: path.resolve(this.environment.settings.chromePath),
|
|
476
476
|
defaultViewport: null,
|
|
477
477
|
acceptInsecureCerts: true,
|
|
478
478
|
timeout: this.navigationTimeout,
|
|
@@ -500,7 +500,7 @@ export class BrowserOriginFetcher {
|
|
|
500
500
|
* once, and one must not delete the profile the other is holding open.
|
|
501
501
|
*/
|
|
502
502
|
async createProfile() {
|
|
503
|
-
const parent = path.resolve(this.
|
|
503
|
+
const parent = path.resolve(this.environment.cacheDir, PROFILE_FOLDER);
|
|
504
504
|
mkdirSync(parent, { recursive: true });
|
|
505
505
|
this.pruneProfiles(parent);
|
|
506
506
|
return mkdtemp(path.join(parent, "profile-"));
|
|
@@ -22,7 +22,7 @@ const logger = {
|
|
|
22
22
|
comment: () => undefined,
|
|
23
23
|
};
|
|
24
24
|
/** The fetcher is always stubbed in these specs, so no Chrome is ever launched from them. */
|
|
25
|
-
const
|
|
25
|
+
const environment = {};
|
|
26
26
|
describe("installBrowserOriginFetch", () => {
|
|
27
27
|
let handle;
|
|
28
28
|
let log;
|
|
@@ -39,7 +39,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
39
39
|
describe("auto mode", () => {
|
|
40
40
|
it("leaves an origin that answers on the network alone", async () => {
|
|
41
41
|
handle = installBrowserOriginFetch({
|
|
42
|
-
|
|
42
|
+
environment,
|
|
43
43
|
logger,
|
|
44
44
|
fetcher: stubFetcher(log, () => Promise.resolve(new Response("browser"))),
|
|
45
45
|
direct: (url) => {
|
|
@@ -53,7 +53,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
53
53
|
});
|
|
54
54
|
it("retries through the browser once the origin refuses the request", async () => {
|
|
55
55
|
handle = installBrowserOriginFetch({
|
|
56
|
-
|
|
56
|
+
environment,
|
|
57
57
|
logger,
|
|
58
58
|
fetcher: stubFetcher(log, () => Promise.resolve(new Response("browser"))),
|
|
59
59
|
direct: (url) => {
|
|
@@ -67,7 +67,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
67
67
|
});
|
|
68
68
|
it("keeps a refused host on the browser, instead of paying for the network leg again", async () => {
|
|
69
69
|
handle = installBrowserOriginFetch({
|
|
70
|
-
|
|
70
|
+
environment,
|
|
71
71
|
logger,
|
|
72
72
|
fetcher: stubFetcher(log, () => Promise.resolve(new Response("browser"))),
|
|
73
73
|
direct: (url) => {
|
|
@@ -85,7 +85,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
85
85
|
});
|
|
86
86
|
it("leaves another host on the network, because only the refused one is rerouted", async () => {
|
|
87
87
|
handle = installBrowserOriginFetch({
|
|
88
|
-
|
|
88
|
+
environment,
|
|
89
89
|
logger,
|
|
90
90
|
fetcher: stubFetcher(log, () => Promise.resolve(new Response("browser"))),
|
|
91
91
|
direct: (url) => {
|
|
@@ -101,7 +101,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
101
101
|
});
|
|
102
102
|
it("does not reroute an ordinary origin error", async () => {
|
|
103
103
|
handle = installBrowserOriginFetch({
|
|
104
|
-
|
|
104
|
+
environment,
|
|
105
105
|
logger,
|
|
106
106
|
fetcher: stubFetcher(log, () => Promise.resolve(new Response("browser"))),
|
|
107
107
|
direct: () => Promise.resolve(new Response("gone", { status: 404 })),
|
|
@@ -112,7 +112,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
112
112
|
});
|
|
113
113
|
it("answers the refusal when the browser cannot reach the origin either", async () => {
|
|
114
114
|
handle = installBrowserOriginFetch({
|
|
115
|
-
|
|
115
|
+
environment,
|
|
116
116
|
logger,
|
|
117
117
|
fetcher: stubFetcher(log, () => Promise.reject(new Error("navigation timeout"))),
|
|
118
118
|
direct: () => Promise.resolve(new Response("blocked", { status: 403 })),
|
|
@@ -126,7 +126,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
126
126
|
describe("always mode", () => {
|
|
127
127
|
it("sends the first request through the browser", async () => {
|
|
128
128
|
handle = installBrowserOriginFetch({
|
|
129
|
-
|
|
129
|
+
environment,
|
|
130
130
|
logger,
|
|
131
131
|
mode: "always",
|
|
132
132
|
fetcher: stubFetcher(log, () => Promise.resolve(new Response("browser"))),
|
|
@@ -141,7 +141,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
141
141
|
});
|
|
142
142
|
it("falls back to the network when the browser fails", async () => {
|
|
143
143
|
handle = installBrowserOriginFetch({
|
|
144
|
-
|
|
144
|
+
environment,
|
|
145
145
|
logger,
|
|
146
146
|
mode: "always",
|
|
147
147
|
fetcher: stubFetcher(log, () => Promise.reject(new Error("no chrome"))),
|
|
@@ -157,7 +157,7 @@ describe("installBrowserOriginFetch", () => {
|
|
|
157
157
|
});
|
|
158
158
|
it("restores the direct transport when the handle is closed", async () => {
|
|
159
159
|
const installed = installBrowserOriginFetch({
|
|
160
|
-
|
|
160
|
+
environment,
|
|
161
161
|
logger,
|
|
162
162
|
mode: "always",
|
|
163
163
|
fetcher: stubFetcher(log, () => Promise.resolve(new Response("browser"))),
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Config } from "@oclif/core";
|
|
2
|
+
import { CliEnvironment } from "./cli-environment.js";
|
|
3
|
+
export interface CliEnvironmentOptions {
|
|
4
|
+
/** The customer the command works on, for its documentHandler's node modules. */
|
|
5
|
+
readonly customerPath?: string;
|
|
6
|
+
/** Keep the CLI to what `--quiet` allows: no spinners, default answers. */
|
|
7
|
+
readonly quiet?: boolean;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Builds the environment of one invocation, with its one CLI.
|
|
11
|
+
*
|
|
12
|
+
* The CLI asks the environment whether it runs in CI and whether it may prompt,
|
|
13
|
+
* and the environment hands the CLI out, so the settings are loaded first, the
|
|
14
|
+
* CLI is built against them, and only then is the environment complete.
|
|
15
|
+
*/
|
|
16
|
+
export declare class CliEnvironmentFactory {
|
|
17
|
+
private readonly oclif;
|
|
18
|
+
private readonly options;
|
|
19
|
+
/**
|
|
20
|
+
* @param oclif the oclif config of the running command
|
|
21
|
+
* @param options what the command knows about its invocation
|
|
22
|
+
*/
|
|
23
|
+
constructor(oclif: Config, options?: CliEnvironmentOptions);
|
|
24
|
+
buildEnvironment(): CliEnvironment;
|
|
25
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { CliEnvironment } from "./cli-environment.js";
|
|
2
|
+
import { CliServiceFactory } from "./cli-service-factory.js";
|
|
3
|
+
import { CliServiceBuildContext } from "./cli-service-build-context.js";
|
|
4
|
+
/**
|
|
5
|
+
* Builds the environment of one invocation, with its one CLI.
|
|
6
|
+
*
|
|
7
|
+
* The CLI asks the environment whether it runs in CI and whether it may prompt,
|
|
8
|
+
* and the environment hands the CLI out, so the settings are loaded first, the
|
|
9
|
+
* CLI is built against them, and only then is the environment complete.
|
|
10
|
+
*/
|
|
11
|
+
export class CliEnvironmentFactory {
|
|
12
|
+
oclif;
|
|
13
|
+
options;
|
|
14
|
+
/**
|
|
15
|
+
* @param oclif the oclif config of the running command
|
|
16
|
+
* @param options what the command knows about its invocation
|
|
17
|
+
*/
|
|
18
|
+
constructor(oclif, options = {}) {
|
|
19
|
+
this.oclif = oclif;
|
|
20
|
+
this.options = options;
|
|
21
|
+
}
|
|
22
|
+
buildEnvironment() {
|
|
23
|
+
const environment = CliEnvironment.load(this.oclif, this.options.customerPath);
|
|
24
|
+
const cli = new CliServiceFactory(new CliServiceBuildContext({
|
|
25
|
+
environment,
|
|
26
|
+
quiet: this.options.quiet ?? false,
|
|
27
|
+
})).getService();
|
|
28
|
+
return environment.attachCli(cli);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { Config } from "@oclif/core";
|
|
2
|
+
import { CliSettings } from "./cli-settings.js";
|
|
3
|
+
import type { CliServiceInterface } from "./cli-service-model.js";
|
|
4
|
+
/**
|
|
5
|
+
* Where a command runs: the user's settings, oclif's config and the
|
|
6
|
+
* directories the CLI owns.
|
|
7
|
+
*
|
|
8
|
+
* One per invocation, built by {@link CliEnvironmentFactory} together with the
|
|
9
|
+
* invocation's one CLI ({@link cli}) and handed to every factory in its
|
|
10
|
+
* context. The settings merge three sources, later winning over earlier:
|
|
11
|
+
*
|
|
12
|
+
* ```
|
|
13
|
+
* ~/.config/speed-kit-cli/config.json < .env < process.env
|
|
14
|
+
* ```
|
|
15
|
+
*/
|
|
16
|
+
export declare class CliEnvironment {
|
|
17
|
+
readonly oclif: Config;
|
|
18
|
+
private readonly env;
|
|
19
|
+
/** The user's settings; {@link save} writes changes back. */
|
|
20
|
+
readonly settings: CliSettings;
|
|
21
|
+
/** Where the extra node modules of a customer's documentHandler live. */
|
|
22
|
+
readonly nodeModulesPath: string;
|
|
23
|
+
private attachedCli?;
|
|
24
|
+
/**
|
|
25
|
+
* Loads the settings for one invocation.
|
|
26
|
+
*
|
|
27
|
+
* @param oclif the oclif config of the running command
|
|
28
|
+
* @param customerPath the customer the command works on, if any, for its
|
|
29
|
+
* node modules
|
|
30
|
+
* @param env the process environment; a test passes its own
|
|
31
|
+
*/
|
|
32
|
+
static load(oclif: Config, customerPath?: string, env?: NodeJS.ProcessEnv): CliEnvironment;
|
|
33
|
+
private constructor();
|
|
34
|
+
/** The one CLI of this invocation: every output and every prompt. */
|
|
35
|
+
get cli(): CliServiceInterface;
|
|
36
|
+
/**
|
|
37
|
+
* Completes the environment with its CLI. Only {@link CliEnvironmentFactory}
|
|
38
|
+
* calls this, once: the CLI is built against the environment, so the two
|
|
39
|
+
* cannot be created in one step.
|
|
40
|
+
*/
|
|
41
|
+
attachCli(cli: CliServiceInterface): this;
|
|
42
|
+
/** The directory the CLI keeps its caches and scratch files in. */
|
|
43
|
+
get cacheDir(): string;
|
|
44
|
+
/**
|
|
45
|
+
* Whether this runs in CI. Most CI providers set `CI=true`, and several set
|
|
46
|
+
* their own dedicated variable, so both are checked.
|
|
47
|
+
*/
|
|
48
|
+
get isCI(): boolean;
|
|
49
|
+
/**
|
|
50
|
+
* True when the user cannot safely be prompted: in CI, without an attached
|
|
51
|
+
* TTY (piped output, an npm background install), or when they opted out
|
|
52
|
+
* with SK_NON_INTERACTIVE.
|
|
53
|
+
*/
|
|
54
|
+
get nonInteractive(): boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Persists the given settings into the user config.json, merging with what
|
|
57
|
+
* is already there. Also reflects the change in {@link settings} so the
|
|
58
|
+
* running command sees it immediately.
|
|
59
|
+
*/
|
|
60
|
+
save(partial: Partial<CliSettings>): void;
|
|
61
|
+
private loadSettings;
|
|
62
|
+
private createEmptyConfigFile;
|
|
63
|
+
private getConfigFilePath;
|
|
64
|
+
private loadConfigFromConfigFile;
|
|
65
|
+
private loadConfigFromEnvironment;
|
|
66
|
+
private resolveExtensionConfigPaths;
|
|
67
|
+
private readCliConfigFromFile;
|
|
68
|
+
/**
|
|
69
|
+
* Reads and parses config.json without any side effects. Returns null when
|
|
70
|
+
* the file is missing or cannot be parsed.
|
|
71
|
+
*/
|
|
72
|
+
private readRawConfigFile;
|
|
73
|
+
}
|