@salesforce/plugin-devops-center 1.2.27 → 1.3.0
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/LICENSE.txt +200 -6
- package/README.md +515 -19
- package/bin/dev.js +15 -0
- package/bin/run.js +5 -0
- package/lib/commands/devops/pipeline/activate.d.ts +14 -0
- package/lib/commands/devops/pipeline/activate.js +82 -0
- package/lib/commands/devops/pipeline/activate.js.map +1 -0
- package/lib/commands/devops/pipeline/attach-project.d.ts +15 -0
- package/lib/commands/devops/pipeline/attach-project.js +82 -0
- package/lib/commands/devops/pipeline/attach-project.js.map +1 -0
- package/lib/commands/devops/pipeline/create.d.ts +23 -0
- package/lib/commands/devops/pipeline/create.js +136 -0
- package/lib/commands/devops/pipeline/create.js.map +1 -0
- package/lib/commands/devops/pipeline/stage/add.d.ts +16 -0
- package/lib/commands/devops/pipeline/stage/add.js +94 -0
- package/lib/commands/devops/pipeline/stage/add.js.map +1 -0
- package/lib/commands/devops/project/create.d.ts +15 -0
- package/lib/commands/devops/project/create.js +72 -0
- package/lib/commands/devops/project/create.js.map +1 -0
- package/lib/commands/devops/project/list.d.ts +20 -0
- package/lib/commands/devops/project/list.js +59 -0
- package/lib/commands/devops/project/list.js.map +1 -0
- package/lib/commands/devops/pull-request/create.d.ts +17 -0
- package/lib/commands/devops/pull-request/create.js +104 -0
- package/lib/commands/devops/pull-request/create.js.map +1 -0
- package/lib/commands/devops/stage/add-branch.d.ts +17 -0
- package/lib/commands/devops/stage/add-branch.js +110 -0
- package/lib/commands/devops/stage/add-branch.js.map +1 -0
- package/lib/commands/devops/stage/add-environment.d.ts +18 -0
- package/lib/commands/devops/stage/add-environment.js +136 -0
- package/lib/commands/devops/stage/add-environment.js.map +1 -0
- package/lib/commands/devops/work-item/create.d.ts +16 -0
- package/lib/commands/devops/work-item/create.js +76 -0
- package/lib/commands/devops/work-item/create.js.map +1 -0
- package/lib/commands/devops/work-item/list.d.ts +17 -0
- package/lib/commands/devops/work-item/list.js +72 -0
- package/lib/commands/devops/work-item/list.js.map +1 -0
- package/lib/commands/devops/work-item/status/update.d.ts +16 -0
- package/lib/commands/devops/work-item/status/update.js +90 -0
- package/lib/commands/devops/work-item/status/update.js.map +1 -0
- package/lib/commands/project/deploy/pipeline/quick.d.ts +2 -2
- package/lib/commands/project/deploy/pipeline/quick.js +24 -21
- package/lib/commands/project/deploy/pipeline/quick.js.map +1 -1
- package/lib/commands/project/deploy/pipeline/report.d.ts +4 -4
- package/lib/commands/project/deploy/pipeline/report.js +38 -35
- package/lib/commands/project/deploy/pipeline/report.js.map +1 -1
- package/lib/commands/project/deploy/pipeline/resume.d.ts +2 -2
- package/lib/commands/project/deploy/pipeline/resume.js +24 -21
- package/lib/commands/project/deploy/pipeline/resume.js.map +1 -1
- package/lib/commands/project/deploy/pipeline/start.d.ts +3 -3
- package/lib/commands/project/deploy/pipeline/start.js +26 -23
- package/lib/commands/project/deploy/pipeline/start.js.map +1 -1
- package/lib/commands/project/deploy/pipeline/validate.d.ts +3 -3
- package/lib/commands/project/deploy/pipeline/validate.js +24 -21
- package/lib/commands/project/deploy/pipeline/validate.js.map +1 -1
- package/lib/common/base/abstractAsyncOperation.d.ts +3 -3
- package/lib/common/base/abstractAsyncOperation.js +31 -23
- package/lib/common/base/abstractAsyncOperation.js.map +1 -1
- package/lib/common/base/abstractPromote.d.ts +5 -4
- package/lib/common/base/abstractPromote.js +52 -38
- package/lib/common/base/abstractPromote.js.map +1 -1
- package/lib/common/base/abstractQuick.d.ts +4 -3
- package/lib/common/base/abstractQuick.js +44 -43
- package/lib/common/base/abstractQuick.js.map +1 -1
- package/lib/common/base/abstractReportOnPromote.d.ts +2 -1
- package/lib/common/base/abstractReportOnPromote.js +31 -24
- package/lib/common/base/abstractReportOnPromote.js.map +1 -1
- package/lib/common/base/abstractResume.d.ts +3 -2
- package/lib/common/base/abstractResume.js +40 -33
- package/lib/common/base/abstractResume.js.map +1 -1
- package/lib/common/constants.js +19 -13
- package/lib/common/constants.js.map +1 -1
- package/lib/common/deployPipelineCache.js +20 -15
- package/lib/common/deployPipelineCache.js.map +1 -1
- package/lib/common/flags/flags.d.ts +2 -2
- package/lib/common/flags/flags.js +34 -29
- package/lib/common/flags/flags.js.map +1 -1
- package/lib/common/flags/promote/promoteFlags.d.ts +3 -3
- package/lib/common/flags/promote/promoteFlags.js +26 -20
- package/lib/common/flags/promote/promoteFlags.js.map +1 -1
- package/lib/common/index.d.ts +3 -2
- package/lib/common/index.js +2 -17
- package/lib/common/index.js.map +1 -1
- package/lib/common/outputColumns.d.ts +3 -13
- package/lib/common/outputColumns.js +23 -19
- package/lib/common/outputColumns.js.map +1 -1
- package/lib/common/outputService/aorOutputService.d.ts +4 -4
- package/lib/common/outputService/aorOutputService.js +27 -20
- package/lib/common/outputService/aorOutputService.js.map +1 -1
- package/lib/common/outputService/deployCommandOutputService.d.ts +2 -2
- package/lib/common/outputService/deployCommandOutputService.js +17 -12
- package/lib/common/outputService/deployCommandOutputService.js.map +1 -1
- package/lib/common/outputService/deploySummaryBuilder.d.ts +1 -1
- package/lib/common/outputService/deploySummaryBuilder.js +45 -31
- package/lib/common/outputService/deploySummaryBuilder.js.map +1 -1
- package/lib/common/outputService/deploymentResultOutputService.d.ts +4 -4
- package/lib/common/outputService/deploymentResultOutputService.js +16 -10
- package/lib/common/outputService/deploymentResultOutputService.js.map +1 -1
- package/lib/common/outputService/index.d.ts +8 -6
- package/lib/common/outputService/index.js +5 -19
- package/lib/common/outputService/index.js.map +1 -1
- package/lib/common/outputService/outputService.d.ts +6 -4
- package/lib/common/outputService/outputService.js +20 -14
- package/lib/common/outputService/outputService.js.map +1 -1
- package/lib/common/outputService/outputServiceFactory.d.ts +8 -8
- package/lib/common/outputService/outputServiceFactory.js +21 -16
- package/lib/common/outputService/outputServiceFactory.js.map +1 -1
- package/lib/common/outputService/outputUtils.d.ts +1 -1
- package/lib/common/outputService/outputUtils.js +24 -19
- package/lib/common/outputService/outputUtils.js.map +1 -1
- package/lib/common/outputService/promoteOutputService.d.ts +4 -5
- package/lib/common/outputService/promoteOutputService.js +19 -13
- package/lib/common/outputService/promoteOutputService.js.map +1 -1
- package/lib/common/outputService/reportOutputService.d.ts +5 -6
- package/lib/common/outputService/reportOutputService.js +32 -27
- package/lib/common/outputService/reportOutputService.js.map +1 -1
- package/lib/common/outputService/resumeCommandOutputService.d.ts +3 -3
- package/lib/common/outputService/resumeCommandOutputService.js +19 -13
- package/lib/common/outputService/resumeCommandOutputService.js.map +1 -1
- package/lib/common/outputService/resumeOutputService.d.ts +3 -3
- package/lib/common/outputService/resumeOutputService.js +23 -17
- package/lib/common/outputService/resumeOutputService.js.map +1 -1
- package/lib/common/selectors/asyncOperationResultsSelector.d.ts +1 -1
- package/lib/common/selectors/asyncOperationResultsSelector.js +16 -10
- package/lib/common/selectors/asyncOperationResultsSelector.js.map +1 -1
- package/lib/common/selectors/deployComponentsSelector.d.ts +1 -1
- package/lib/common/selectors/deployComponentsSelector.js +18 -13
- package/lib/common/selectors/deployComponentsSelector.js.map +1 -1
- package/lib/common/selectors/deployProgressSummarySelector.d.ts +2 -2
- package/lib/common/selectors/deployProgressSummarySelector.js +16 -10
- package/lib/common/selectors/deployProgressSummarySelector.js.map +1 -1
- package/lib/common/selectors/deploymentResultsSelector.d.ts +2 -2
- package/lib/common/selectors/deploymentResultsSelector.js +20 -16
- package/lib/common/selectors/deploymentResultsSelector.js.map +1 -1
- package/lib/common/selectors/environmentSelector.d.ts +2 -2
- package/lib/common/selectors/environmentSelector.js +16 -10
- package/lib/common/selectors/environmentSelector.js.map +1 -1
- package/lib/common/selectors/namedCredentialSelector.d.ts +1 -1
- package/lib/common/selectors/namedCredentialSelector.js +16 -10
- package/lib/common/selectors/namedCredentialSelector.js.map +1 -1
- package/lib/common/selectors/pipelineStageSelector.d.ts +1 -1
- package/lib/common/selectors/pipelineStageSelector.js +18 -13
- package/lib/common/selectors/pipelineStageSelector.js.map +1 -1
- package/lib/common/selectors/selectorUtils.d.ts +1 -1
- package/lib/common/selectors/selectorUtils.js +17 -11
- package/lib/common/selectors/selectorUtils.js.map +1 -1
- package/lib/common/selectors/validateDeploySelector.d.ts +1 -1
- package/lib/common/selectors/validateDeploySelector.js +16 -10
- package/lib/common/selectors/validateDeploySelector.js.map +1 -1
- package/lib/common/selectors/workItemSelector.d.ts +2 -2
- package/lib/common/selectors/workItemSelector.js +16 -10
- package/lib/common/selectors/workItemSelector.js.map +1 -1
- package/lib/common/types.d.ts +4 -4
- package/lib/common/types.js +4 -7
- package/lib/common/types.js.map +1 -1
- package/lib/common/utils.d.ts +4 -4
- package/lib/common/utils.js +42 -43
- package/lib/common/utils.js.map +1 -1
- package/lib/configMeta.js +21 -15
- package/lib/configMeta.js.map +1 -1
- package/lib/streamer/doceMonitor.d.ts +3 -2
- package/lib/streamer/doceMonitor.js +14 -6
- package/lib/streamer/doceMonitor.js.map +1 -1
- package/lib/streamer/doceStream.d.ts +1 -1
- package/lib/streamer/doceStream.js +19 -11
- package/lib/streamer/doceStream.js.map +1 -1
- package/lib/streamer/processors/asyncOpStream.d.ts +2 -2
- package/lib/streamer/processors/asyncOpStream.js +22 -15
- package/lib/streamer/processors/asyncOpStream.js.map +1 -1
- package/lib/streamer/sObjectStream.d.ts +1 -1
- package/lib/streamer/sObjectStream.js +9 -10
- package/lib/streamer/sObjectStream.js.map +1 -1
- package/lib/utils/activatePipeline.d.ts +17 -0
- package/lib/utils/activatePipeline.js +35 -0
- package/lib/utils/activatePipeline.js.map +1 -0
- package/lib/utils/addPipelineStage.d.ts +20 -0
- package/lib/utils/addPipelineStage.js +43 -0
- package/lib/utils/addPipelineStage.js.map +1 -0
- package/lib/utils/addStageBranch.d.ts +22 -0
- package/lib/utils/addStageBranch.js +48 -0
- package/lib/utils/addStageBranch.js.map +1 -0
- package/lib/utils/addStageEnvironment.d.ts +92 -0
- package/lib/utils/addStageEnvironment.js +120 -0
- package/lib/utils/addStageEnvironment.js.map +1 -0
- package/lib/utils/attachProject.d.ts +21 -0
- package/lib/utils/attachProject.js +44 -0
- package/lib/utils/attachProject.js.map +1 -0
- package/lib/utils/createPipeline.d.ts +34 -0
- package/lib/utils/createPipeline.js +77 -0
- package/lib/utils/createPipeline.js.map +1 -0
- package/lib/utils/createProject.d.ts +17 -0
- package/lib/utils/createProject.js +39 -0
- package/lib/utils/createProject.js.map +1 -0
- package/lib/utils/createPullRequest.d.ts +49 -0
- package/lib/utils/createPullRequest.js +204 -0
- package/lib/utils/createPullRequest.js.map +1 -0
- package/lib/utils/createWorkItem.d.ts +19 -0
- package/lib/utils/createWorkItem.js +58 -0
- package/lib/utils/createWorkItem.js.map +1 -0
- package/lib/utils/pipelineUtils.d.ts +8 -0
- package/lib/utils/pipelineUtils.js +51 -0
- package/lib/utils/pipelineUtils.js.map +1 -0
- package/lib/utils/types.d.ts +57 -0
- package/lib/utils/types.js +17 -0
- package/lib/utils/types.js.map +1 -0
- package/lib/utils/updateWorkItemStatus.d.ts +34 -0
- package/lib/utils/updateWorkItemStatus.js +71 -0
- package/lib/utils/updateWorkItemStatus.js.map +1 -0
- package/lib/utils/workItems.d.ts +3 -0
- package/lib/utils/workItems.js +181 -0
- package/lib/utils/workItems.js.map +1 -0
- package/messages/commonErrors.md +5 -1
- package/messages/devops.pipeline.activate.md +29 -0
- package/messages/devops.pipeline.attach-project.md +29 -0
- package/messages/devops.pipeline.create.md +81 -0
- package/messages/devops.pipeline.stage.add.md +37 -0
- package/messages/devops.project.create.md +29 -0
- package/messages/devops.project.list.md +17 -0
- package/messages/devops.pull-request.create.md +57 -0
- package/messages/devops.stage.add-branch.md +46 -0
- package/messages/devops.stage.add-environment.md +61 -0
- package/messages/devops.work-item.create.md +29 -0
- package/messages/devops.work-item.list.md +21 -0
- package/messages/devops.work-item.status.update.md +29 -0
- package/npm-shrinkwrap.json +4197 -4471
- package/oclif.lock +3380 -3272
- package/oclif.manifest.json +1056 -11
- package/package.json +53 -23
- package/schemas/devops-pipeline-activate.json +28 -0
- package/schemas/devops-pipeline-attach__project.json +25 -0
- package/schemas/devops-pipeline-create.json +50 -0
- package/schemas/devops-pipeline-stage-add.json +31 -0
- package/schemas/devops-project-create.json +28 -0
- package/schemas/devops-project-list.json +35 -0
- package/schemas/devops-pull__request-create.json +34 -0
- package/schemas/devops-stage-add__branch.json +34 -0
- package/schemas/devops-stage-add__environment.json +47 -0
- package/schemas/devops-work__item-create.json +28 -0
- package/schemas/devops-work__item-list.json +75 -0
- package/schemas/devops-work__item-status-update.json +28 -0
- package/schemas/project-deploy-pipeline-report.json +2 -2
|
@@ -1,24 +1,30 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
exports.selectDeployAORSummaryDataById = selectDeployAORSummaryDataById;
|
|
10
|
-
const selectorUtils_1 = require("./selectorUtils");
|
|
16
|
+
import { runSafeQuery } from './selectorUtils.js';
|
|
11
17
|
/**
|
|
12
18
|
* Returns the data necessary to create the deploy summary (or part of it).
|
|
13
19
|
*/
|
|
14
|
-
async function selectDeployAORSummaryDataById(con, aorId) {
|
|
20
|
+
export async function selectDeployAORSummaryDataById(con, aorId) {
|
|
15
21
|
const queryStr = `SELECT Id, sf_devops__Operation__c,
|
|
16
22
|
(SELECT sf_devops__Pipeline_Stage__r.Name, sf_devops__Pipeline_Stage__r.sf_devops__Environment__r.sf_devops__Named_Credential__c, sf_devops__Pipeline_Stage__r.sf_devops__Environment__r.Name, sf_devops__Work_Item__r.Name FROM sf_devops__Work_Item_Promotes__r),
|
|
17
23
|
(SELECT sf_devops__Change_Bundle__r.Id, sf_devops__Change_Bundle__r.sf_devops__Version_Name__c, sf_devops__Environment__r.Id FROM sf_devops__Change_Bundle_Installs__r),
|
|
18
24
|
(SELECT Name FROM sf_devops__Work_Items__r)
|
|
19
25
|
FROM sf_devops__Async_Operation_Result__c
|
|
20
26
|
WHERE Id = '${aorId}'`;
|
|
21
|
-
const resp = await
|
|
27
|
+
const resp = await runSafeQuery(con, queryStr);
|
|
22
28
|
return resp.records[0];
|
|
23
29
|
}
|
|
24
30
|
//# sourceMappingURL=deployProgressSummarySelector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deployProgressSummarySelector.js","sourceRoot":"","sources":["../../../src/common/selectors/deployProgressSummarySelector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"deployProgressSummarySelector.js","sourceRoot":"","sources":["../../../src/common/selectors/deployProgressSummarySelector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAUlD;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,8BAA8B,CAClD,GAAe,EACf,KAAa;IAEb,MAAM,QAAQ,GAAG;;;;;kCAKe,KAAK,GAAG,CAAC;IAEzC,MAAM,IAAI,GAA0C,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;IACtF,OAAO,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AACzB,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Connection } from '@salesforce/core';
|
|
2
|
-
import { QueryResult } from 'jsforce';
|
|
3
|
-
import { AsyncOperationResult, ChangeBundleInstall, DeploymentResult } from '../types';
|
|
2
|
+
import { QueryResult } from '@jsforce/jsforce-node';
|
|
3
|
+
import { AsyncOperationResult, ChangeBundleInstall, DeploymentResult } from '../types.js';
|
|
4
4
|
export type DeploymentResultCheckDeploy = {
|
|
5
5
|
sf_devops__Check_Deploy__c: boolean | null;
|
|
6
6
|
};
|
|
@@ -1,40 +1,44 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
exports.selectOneDeploymentResultByAsyncJobId = selectOneDeploymentResultByAsyncJobId;
|
|
10
|
-
exports.isCheckDeploy = isCheckDeploy;
|
|
11
|
-
exports.selectOneDeploymentResultWithChangeBundleInstallsByAsyncJobId = selectOneDeploymentResultWithChangeBundleInstallsByAsyncJobId;
|
|
12
|
-
const selectorUtils_1 = require("./selectorUtils");
|
|
16
|
+
import { runSafeQuery } from './selectorUtils.js';
|
|
13
17
|
/**
|
|
14
18
|
*
|
|
15
19
|
* Returns deployment result record filtering by async job id.
|
|
16
20
|
*/
|
|
17
|
-
async function selectOneDeploymentResultByAsyncJobId(con, asyncJobId) {
|
|
21
|
+
export async function selectOneDeploymentResultByAsyncJobId(con, asyncJobId) {
|
|
18
22
|
const queryStr = `SELECT sf_devops__Full_Deploy__c, sf_devops__Check_Deploy__c, sf_devops__Test_Level__c, sf_devops__Run_Tests__c, sf_devops__Completion_Date__c,
|
|
19
23
|
sf_devops__Status__r.Id, sf_devops__Status__r.CreatedDate, sf_devops__Status__r.CreatedById,
|
|
20
24
|
sf_devops__Status__r.CreatedBy.Name, sf_devops__Status__r.sf_devops__Message__c,
|
|
21
25
|
sf_devops__Status__r.sf_devops__Status__c, sf_devops__Status__r.sf_devops__Error_Details__c
|
|
22
26
|
FROM sf_devops__Deployment_Result__c
|
|
23
27
|
WHERE sf_devops__Status__r.Id = '${asyncJobId}'`;
|
|
24
|
-
const resp = await
|
|
28
|
+
const resp = await runSafeQuery(con, queryStr, true);
|
|
25
29
|
return resp.totalSize > 0 ? resp.records[0] : null;
|
|
26
30
|
}
|
|
27
31
|
/**
|
|
28
32
|
*
|
|
29
33
|
* Returns if a deployment result is from a Check-Deploy by async job id.
|
|
30
34
|
*/
|
|
31
|
-
async function isCheckDeploy(con, asyncJobId) {
|
|
35
|
+
export async function isCheckDeploy(con, asyncJobId) {
|
|
32
36
|
const queryStr = `SELECT sf_devops__Check_Deploy__c,
|
|
33
37
|
sf_devops__Status__r.Id, sf_devops__Check_Deploy_Status__r.Id
|
|
34
38
|
FROM sf_devops__Deployment_Result__c
|
|
35
39
|
WHERE sf_devops__Status__r.Id = '${asyncJobId}'
|
|
36
40
|
OR sf_devops__Check_Deploy_Status__r.Id = '${asyncJobId}'`;
|
|
37
|
-
const resp = await
|
|
41
|
+
const resp = await runSafeQuery(con, queryStr, true);
|
|
38
42
|
const result = resp.totalSize > 0 && !!resp.records[0].sf_devops__Check_Deploy__c;
|
|
39
43
|
return result;
|
|
40
44
|
}
|
|
@@ -42,14 +46,14 @@ async function isCheckDeploy(con, asyncJobId) {
|
|
|
42
46
|
*
|
|
43
47
|
* Returns deployment result record with Change Bundle Installs filtering by check deploy job id.
|
|
44
48
|
*/
|
|
45
|
-
async function selectOneDeploymentResultWithChangeBundleInstallsByAsyncJobId(con, asyncJobId) {
|
|
49
|
+
export async function selectOneDeploymentResultWithChangeBundleInstallsByAsyncJobId(con, asyncJobId) {
|
|
46
50
|
const queryStr = `SELECT sf_devops__Check_Deploy__c, sf_devops__Deployment_Id__c, sf_devops__Check_Deploy_Status__r.sf_devops__Status__c,
|
|
47
51
|
(SELECT sf_devops__Environment__c FROM sf_devops__Change_Bundle_Installs__r)
|
|
48
52
|
FROM sf_devops__Deployment_Result__c
|
|
49
53
|
WHERE sf_devops__Check_Deploy_Status__c = '${asyncJobId}'
|
|
50
54
|
AND sf_devops__Check_Deploy__c = TRUE
|
|
51
55
|
AND Id IN (SELECT sf_devops__Deployment_Result__c FROM sf_devops__Change_Bundle_Install__c)`;
|
|
52
|
-
const resp = await
|
|
56
|
+
const resp = await runSafeQuery(con, queryStr, true);
|
|
53
57
|
return resp.totalSize > 0 ? resp.records[0] : null;
|
|
54
58
|
}
|
|
55
59
|
//# sourceMappingURL=deploymentResultsSelector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deploymentResultsSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/deploymentResultsSelector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"deploymentResultsSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/deploymentResultsSelector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAWlD;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,qCAAqC,CACzD,GAAe,EACf,UAAkB;IAElB,MAAM,QAAQ,GAAG;;;;;uDAKoC,UAAU,GAAG,CAAC;IAEnE,MAAM,IAAI,GAAkC,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,EAAE,IAAI,CAAC,CAAC;IACpF,OAAO,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;AACrD,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,aAAa,CAAC,GAAe,EAAE,UAAkB;IACrE,MAAM,QAAQ,GAAG;;;uDAGoC,UAAU;iEACA,UAAU,GAAG,CAAC;IAE7E,MAAM,IAAI,GAA6C,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,EAAE,IAAI,CAAC,CAAC;IAC/F,MAAM,MAAM,GAAG,IAAI,CAAC,SAAS,GAAG,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,0BAA0B,CAAC;IAClF,OAAO,MAAM,CAAC;AAChB,CAAC;AACD;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,6DAA6D,CACjF,GAAe,EACf,UAAkB;IAElB,MAAM,QAAQ,GAAG;;;iEAG8C,UAAU;;kHAEuC,CAAC;IAEjH,MAAM,IAAI,GAA+D,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,EAAE,IAAI,CAAC,CAAC;IACjH,OAAO,IAAI,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;AACrD,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { QueryResult } from 'jsforce';
|
|
1
|
+
import { QueryResult } from '@jsforce/jsforce-node';
|
|
2
2
|
import { Connection } from '@salesforce/core';
|
|
3
|
-
import { PipelineStage } from '../types';
|
|
3
|
+
import { PipelineStage } from '../types.js';
|
|
4
4
|
export type EnvQueryResult = {
|
|
5
5
|
Name: string;
|
|
6
6
|
sf_devops__Pipeline_Stages__r: QueryResult<PipelineStage>;
|
|
@@ -1,22 +1,28 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
exports.selectPipelineStageByEnvironment = selectPipelineStageByEnvironment;
|
|
10
|
-
const selectorUtils_1 = require("./selectorUtils");
|
|
16
|
+
import { runSafeQuery } from './selectorUtils.js';
|
|
11
17
|
/**
|
|
12
18
|
* Returns the named credential and pipeline stage name associated with the envId sent
|
|
13
19
|
*/
|
|
14
|
-
async function selectPipelineStageByEnvironment(con, envId) {
|
|
20
|
+
export async function selectPipelineStageByEnvironment(con, envId) {
|
|
15
21
|
const queryStr = `SELECT Name,
|
|
16
22
|
(SELECT Name FROM sf_devops__Pipeline_Stages__r)
|
|
17
23
|
FROM sf_devops__Environment__c
|
|
18
24
|
WHERE Id = '${envId}'`;
|
|
19
|
-
const resp = await
|
|
25
|
+
const resp = await runSafeQuery(con, queryStr);
|
|
20
26
|
return resp.records[0];
|
|
21
27
|
}
|
|
22
28
|
//# sourceMappingURL=environmentSelector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"environmentSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/environmentSelector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"environmentSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/environmentSelector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAQlD;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,gCAAgC,CAAC,GAAe,EAAE,KAAa;IACnF,MAAM,QAAQ,GAAG;;;kCAGe,KAAK,GAAG,CAAC;IAEzC,MAAM,IAAI,GAAgC,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;IAC5E,OAAO,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AACzB,CAAC"}
|
|
@@ -1,24 +1,30 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
exports.selectNamedCredentialByName = selectNamedCredentialByName;
|
|
10
|
-
const selectorUtils_1 = require("./selectorUtils");
|
|
16
|
+
import { runSafeQuery } from './selectorUtils.js';
|
|
11
17
|
/**
|
|
12
18
|
* Given a named credential it returns the org url (endpoint) associated with it
|
|
13
19
|
*/
|
|
14
|
-
async function selectNamedCredentialByName(con, name) {
|
|
20
|
+
export async function selectNamedCredentialByName(con, name) {
|
|
15
21
|
const queryStr = `
|
|
16
22
|
SELECT Endpoint
|
|
17
23
|
FROM NamedCredential
|
|
18
24
|
WHERE DeveloperName = '${name}'
|
|
19
25
|
AND NamespacePrefix = 'sf_devops'
|
|
20
26
|
LIMIT 1`;
|
|
21
|
-
const resp = await
|
|
27
|
+
const resp = await runSafeQuery(con, queryStr);
|
|
22
28
|
return resp.records[0];
|
|
23
29
|
}
|
|
24
30
|
//# sourceMappingURL=namedCredentialSelector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"namedCredentialSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/namedCredentialSelector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"namedCredentialSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/namedCredentialSelector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,2BAA2B,CAAC,GAAe,EAAE,IAAY;IAC7E,MAAM,QAAQ,GAAG;;;6BAGU,IAAI;;YAErB,CAAC;IAEX,MAAM,IAAI,GAAiC,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;IAC7E,OAAO,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AACzB,CAAC"}
|
|
@@ -1,34 +1,39 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
exports.selectPipelineStagesByProject = selectPipelineStagesByProject;
|
|
10
|
-
exports.selectOnePipelineStageByEnvironmentId = selectOnePipelineStageByEnvironmentId;
|
|
11
|
-
const selectorUtils_1 = require("./selectorUtils");
|
|
16
|
+
import { runSafeQuery } from './selectorUtils.js';
|
|
12
17
|
/**
|
|
13
18
|
*
|
|
14
19
|
* Returns an array of a pipeline stages filtering by project name.
|
|
15
20
|
*/
|
|
16
|
-
async function selectPipelineStagesByProject(con, projectName) {
|
|
21
|
+
export async function selectPipelineStagesByProject(con, projectName) {
|
|
17
22
|
const queryStr = `SELECT Id, sf_devops__Pipeline__r.sf_devops__Project__c, sf_devops__Branch__r.sf_devops__Name__c, (SELECT Id FROM sf_devops__Pipeline_Stages__r)
|
|
18
23
|
FROM sf_devops__Pipeline_Stage__c
|
|
19
24
|
WHERE sf_devops__Pipeline__r.sf_devops__Project__r.Name = '${projectName}'`;
|
|
20
|
-
const resp = await
|
|
25
|
+
const resp = await runSafeQuery(con, queryStr);
|
|
21
26
|
return resp.records;
|
|
22
27
|
}
|
|
23
28
|
/**
|
|
24
29
|
*
|
|
25
30
|
* Returns an array of a pipeline stages filtering by environment Id.
|
|
26
31
|
*/
|
|
27
|
-
async function selectOnePipelineStageByEnvironmentId(con, envId) {
|
|
32
|
+
export async function selectOnePipelineStageByEnvironmentId(con, envId) {
|
|
28
33
|
const queryStr = `SELECT Id, sf_devops__Pipeline__r.sf_devops__Project__c, sf_devops__Branch__r.sf_devops__Name__c, (SELECT Id FROM sf_devops__Pipeline_Stages__r)
|
|
29
34
|
FROM sf_devops__Pipeline_Stage__c
|
|
30
35
|
WHERE sf_devops__Environment__c = '${envId}'`;
|
|
31
|
-
const resp = await
|
|
36
|
+
const resp = await runSafeQuery(con, queryStr);
|
|
32
37
|
return resp.records[0];
|
|
33
38
|
}
|
|
34
39
|
//# sourceMappingURL=pipelineStageSelector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pipelineStageSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/pipelineStageSelector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"pipelineStageSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/pipelineStageSelector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,6BAA6B,CAAC,GAAe,EAAE,WAAmB;IACtF,MAAM,QAAQ,GAAG;;iFAE8D,WAAW,GAAG,CAAC;IAE9F,MAAM,IAAI,GAA+B,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;IAC3E,OAAO,IAAI,CAAC,OAAO,CAAC;AACtB,CAAC;AAED;;;GAGG;AACH,MAAM,CAAC,KAAK,UAAU,qCAAqC,CACzD,GAAe,EACf,KAAa;IAEb,MAAM,QAAQ,GAAG;;yDAEsC,KAAK,GAAG,CAAC;IAEhE,MAAM,IAAI,GAA+B,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;IAC3E,OAAO,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;AACzB,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { Connection } from '@salesforce/core';
|
|
2
|
-
import { QueryResult, Record } from 'jsforce';
|
|
2
|
+
import { QueryResult, Record } from '@jsforce/jsforce-node';
|
|
3
3
|
export declare function runSafeQuery<T extends Record>(con: Connection, queryStr: string, allowNullResults?: boolean): Promise<QueryResult<T>>;
|
|
@@ -1,16 +1,22 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
const messages = core_1.Messages.loadMessages('@salesforce/plugin-devops-center', 'commonErrors');
|
|
13
|
-
async function runSafeQuery(con, queryStr, allowNullResults = false) {
|
|
16
|
+
import { Messages } from '@salesforce/core';
|
|
17
|
+
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
18
|
+
const messages = Messages.loadMessages('@salesforce/plugin-devops-center', 'commonErrors');
|
|
19
|
+
export async function runSafeQuery(con, queryStr, allowNullResults = false) {
|
|
14
20
|
// Parameters verification
|
|
15
21
|
if (!con) {
|
|
16
22
|
throw messages.createError('error.connection-required');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"selectorUtils.js","sourceRoot":"","sources":["../../../src/common/selectors/selectorUtils.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"selectorUtils.js","sourceRoot":"","sources":["../../../src/common/selectors/selectorUtils.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,EAAE,QAAQ,EAAc,MAAM,kBAAkB,CAAC;AAGxD,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,kCAAkC,EAAE,cAAc,CAAC,CAAC;AAE3F,MAAM,CAAC,KAAK,UAAU,YAAY,CAChC,GAAe,EACf,QAAgB,EAChB,gBAAgB,GAAG,KAAK;IAExB,0BAA0B;IAC1B,IAAI,CAAC,GAAG,EAAE,CAAC;QACT,MAAM,QAAQ,CAAC,WAAW,CAAC,2BAA2B,CAAC,CAAC;IAC1D,CAAC;IACD,IAAI,OAAO,QAAQ,KAAK,QAAQ,IAAI,QAAQ,CAAC,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACjE,MAAM,QAAQ,CAAC,WAAW,CAAC,6BAA6B,CAAC,CAAC;IAC5D,CAAC;IAED,uCAAuC;IACvC,IAAI,CAAC;QACH,8EAA8E;QAC9E,MAAM,MAAM,GAAmB,MAAM,GAAG,CAAC,KAAK,CAAC,QAAQ,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,EAAE,CAAC,CAAC;QAChG,IAAI,CAAC,MAAM,CAAC,SAAS,GAAG,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,MAAM,CAAC,SAAS,KAAK,CAAC,IAAI,gBAAgB,CAAC,EAAE,CAAC;YAC7F,OAAO,MAAM,CAAC;QAChB,CAAC;IACH,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,QAAQ,CAAC,WAAW,CAAC,oBAAoB,EAAE,CAAE,KAAe,CAAC,IAAI,CAAC,CAAC,CAAC;IAC5E,CAAC;IAED,wDAAwD;IACxD,MAAM,QAAQ,CAAC,WAAW,CAAC,wBAAwB,CAAC,CAAC;AACvD,CAAC"}
|
|
@@ -1,21 +1,27 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
exports.selectValidateDeployAORSummaryDataById = selectValidateDeployAORSummaryDataById;
|
|
10
|
-
const selectorUtils_1 = require("./selectorUtils");
|
|
16
|
+
import { runSafeQuery } from './selectorUtils.js';
|
|
11
17
|
/**
|
|
12
18
|
* Returns the data necessary to create the deploy summary (or part of it).
|
|
13
19
|
*/
|
|
14
|
-
async function selectValidateDeployAORSummaryDataById(con, aorId) {
|
|
20
|
+
export async function selectValidateDeployAORSummaryDataById(con, aorId) {
|
|
15
21
|
const queryStr = `SELECT sf_devops__Change_Bundle__r.Id, sf_devops__Change_Bundle__r.sf_devops__Version_Name__c, sf_devops__Environment__r.Id
|
|
16
22
|
FROM sf_devops__Change_Bundle_Install__c
|
|
17
23
|
WHERE sf_devops__Deployment_Result__r.sf_devops__Check_Deploy_Status__c = '${aorId}'`;
|
|
18
|
-
const resp = await
|
|
24
|
+
const resp = await runSafeQuery(con, queryStr);
|
|
19
25
|
return resp.records;
|
|
20
26
|
}
|
|
21
27
|
//# sourceMappingURL=validateDeploySelector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validateDeploySelector.js","sourceRoot":"","sources":["../../../src/common/selectors/validateDeploySelector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"validateDeploySelector.js","sourceRoot":"","sources":["../../../src/common/selectors/validateDeploySelector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAElD;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,sCAAsC,CAC1D,GAAe,EACf,KAAa;IAEb,MAAM,QAAQ,GAAG;;iGAE8E,KAAK,GAAG,CAAC;IAExG,MAAM,IAAI,GAAqC,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;IACjF,OAAO,IAAI,CAAC,OAAO,CAAC;AACtB,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { QueryResult } from 'jsforce';
|
|
1
|
+
import { QueryResult } from '@jsforce/jsforce-node';
|
|
2
2
|
import { Connection } from '@salesforce/core';
|
|
3
|
-
import { WorkItem } from '../types';
|
|
3
|
+
import { WorkItem } from '../types.js';
|
|
4
4
|
export type WorkItemsQueryResult = {
|
|
5
5
|
Id: string;
|
|
6
6
|
sf_devops__Work_Items__r: QueryResult<WorkItem>;
|
|
@@ -1,22 +1,28 @@
|
|
|
1
|
-
"use strict";
|
|
2
1
|
/*
|
|
3
|
-
* Copyright
|
|
4
|
-
*
|
|
5
|
-
* Licensed under the
|
|
6
|
-
*
|
|
2
|
+
* Copyright 2026, Salesforce, Inc.
|
|
3
|
+
*
|
|
4
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
+
* you may not use this file except in compliance with the License.
|
|
6
|
+
* You may obtain a copy of the License at
|
|
7
|
+
*
|
|
8
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
+
*
|
|
10
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
+
* See the License for the specific language governing permissions and
|
|
14
|
+
* limitations under the License.
|
|
7
15
|
*/
|
|
8
|
-
|
|
9
|
-
exports.selectWorkItemsByChangeBundles = selectWorkItemsByChangeBundles;
|
|
10
|
-
const selectorUtils_1 = require("./selectorUtils");
|
|
16
|
+
import { runSafeQuery } from './selectorUtils.js';
|
|
11
17
|
/**
|
|
12
18
|
* Returns the work items included in the change bundles sent
|
|
13
19
|
*/
|
|
14
|
-
async function selectWorkItemsByChangeBundles(con, changeBundles) {
|
|
20
|
+
export async function selectWorkItemsByChangeBundles(con, changeBundles) {
|
|
15
21
|
const queryStr = `SELECT Id,
|
|
16
22
|
(SELECT Name FROM sf_devops__Work_Items__r)
|
|
17
23
|
FROM sf_devops__Change_Bundle__c
|
|
18
24
|
WHERE Id IN (${changeBundles.map((id) => "'" + id + "'").join(', ')})`;
|
|
19
|
-
const resp = await
|
|
25
|
+
const resp = await runSafeQuery(con, queryStr);
|
|
20
26
|
return resp.records;
|
|
21
27
|
}
|
|
22
28
|
//# sourceMappingURL=workItemSelector.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"workItemSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/workItemSelector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"workItemSelector.js","sourceRoot":"","sources":["../../../src/common/selectors/workItemSelector.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAQlD;;GAEG;AACH,MAAM,CAAC,KAAK,UAAU,8BAA8B,CAClD,GAAe,EACf,aAAuB;IAEvB,MAAM,QAAQ,GAAG;;;mCAGgB,aAAa,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,GAAG,GAAG,EAAE,GAAG,GAAG,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC;IAEzF,MAAM,IAAI,GAAsC,MAAM,YAAY,CAAC,GAAG,EAAE,QAAQ,CAAC,CAAC;IAClF,OAAO,IAAI,CAAC,OAAO,CAAC;AACtB,CAAC"}
|
package/lib/common/types.d.ts
CHANGED
|
@@ -28,12 +28,12 @@ export declare enum TestLevel {
|
|
|
28
28
|
RunLocalTests = "RunLocalTests",
|
|
29
29
|
RunAllTestsInOrg = "RunAllTestsInOrg"
|
|
30
30
|
}
|
|
31
|
-
export
|
|
31
|
+
export type ApiError = Error & {
|
|
32
32
|
errorCode: string;
|
|
33
|
-
}
|
|
34
|
-
export
|
|
33
|
+
};
|
|
34
|
+
export type ApiPromoteResponse = {
|
|
35
35
|
jobId: string;
|
|
36
|
-
}
|
|
36
|
+
};
|
|
37
37
|
export type WorkItem = {
|
|
38
38
|
Name: string;
|
|
39
39
|
};
|
package/lib/common/types.js
CHANGED
|
@@ -1,18 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AsyncOperationStatus = exports.TestLevel = void 0;
|
|
4
|
-
var TestLevel;
|
|
1
|
+
export var TestLevel;
|
|
5
2
|
(function (TestLevel) {
|
|
6
3
|
TestLevel["NoTestRun"] = "NoTestRun";
|
|
7
4
|
TestLevel["RunSpecifiedTests"] = "RunSpecifiedTests";
|
|
8
5
|
TestLevel["RunLocalTests"] = "RunLocalTests";
|
|
9
6
|
TestLevel["RunAllTestsInOrg"] = "RunAllTestsInOrg";
|
|
10
|
-
})(TestLevel || (
|
|
11
|
-
var AsyncOperationStatus;
|
|
7
|
+
})(TestLevel || (TestLevel = {}));
|
|
8
|
+
export var AsyncOperationStatus;
|
|
12
9
|
(function (AsyncOperationStatus) {
|
|
13
10
|
AsyncOperationStatus["Error"] = "Error";
|
|
14
11
|
AsyncOperationStatus["Completed"] = "Completed";
|
|
15
12
|
AsyncOperationStatus["Ignored"] = "Ignored";
|
|
16
13
|
AsyncOperationStatus["InProgress"] = "In Progress";
|
|
17
|
-
})(AsyncOperationStatus || (
|
|
14
|
+
})(AsyncOperationStatus || (AsyncOperationStatus = {}));
|
|
18
15
|
//# sourceMappingURL=types.js.map
|
package/lib/common/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/common/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/common/types.ts"],"names":[],"mappings":"AA6CA,MAAM,CAAN,IAAY,SAKX;AALD,WAAY,SAAS;IACnB,oCAAuB,CAAA;IACvB,oDAAuC,CAAA;IACvC,4CAA+B,CAAA;IAC/B,kDAAqC,CAAA;AACvC,CAAC,EALW,SAAS,KAAT,SAAS,QAKpB;AAuED,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,uCAAe,CAAA;IACf,+CAAuB,CAAA;IACvB,2CAAmB,CAAA;IACnB,kDAA0B,CAAA;AAC5B,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B"}
|
package/lib/common/utils.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { Connection, Org } from '@salesforce/core';
|
|
2
2
|
import { Duration } from '@salesforce/kit';
|
|
3
3
|
import { Nullable } from '@salesforce/ts-types';
|
|
4
|
-
import { PipelineStage, TestLevel } from '../common';
|
|
5
|
-
import AsyncOpStreaming from '../streamer/processors/asyncOpStream';
|
|
6
|
-
import { AorOutputService } from './outputService/aorOutputService';
|
|
7
|
-
import { AsyncOperationResult, DeployComponent } from './types';
|
|
4
|
+
import { type PipelineStage, TestLevel } from '../common/index.js';
|
|
5
|
+
import AsyncOpStreaming from '../streamer/processors/asyncOpStream.js';
|
|
6
|
+
import { AorOutputService } from './outputService/aorOutputService.js';
|
|
7
|
+
import { AsyncOperationResult, DeployComponent } from './types.js';
|
|
8
8
|
/**
|
|
9
9
|
* @description validates the following:
|
|
10
10
|
* - if RunSpecifiedTests is specified, then it needs to indicate tests to run.
|