@spinnaker/core 2025.3.0 → 2025.4.0-rc1
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.js +337 -72061
- package/dist/index.js.map +1 -1
- package/dist/pipeline/config/services/PipelineConfigService.d.ts +1 -0
- package/package.json +6 -2
- package/src/pipeline/config/services/PipelineConfigService.spec.ts +18 -0
- package/src/pipeline/config/services/PipelineConfigService.ts +4 -0
- package/src/pipeline/executions/executionGroup/ExecutionGroup.tsx +4 -1
|
@@ -8,6 +8,7 @@ export declare class PipelineConfigService {
|
|
|
8
8
|
private static configViewStateCache;
|
|
9
9
|
private static buildViewStateCacheKey;
|
|
10
10
|
static getPipelinesForApplication(applicationName: string): PromiseLike<IPipeline[]>;
|
|
11
|
+
static getPipelineForApplication(applicationName: string, pipelineName: string): PromiseLike<IPipeline>;
|
|
11
12
|
static getStrategiesForApplication(applicationName: string): PromiseLike<IPipeline[]>;
|
|
12
13
|
static getHistory(id: string, isStrategy: boolean, count?: number): PromiseLike<IPipeline[]>;
|
|
13
14
|
static deletePipeline(applicationName: string, pipeline: IPipeline, pipelineName: string): PromiseLike<void>;
|
package/package.json
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spinnaker/core",
|
|
3
|
+
"repository": {
|
|
4
|
+
"type": "git",
|
|
5
|
+
"url": "https://github.com/spinnaker/spinnaker.git"
|
|
6
|
+
},
|
|
3
7
|
"license": "Apache-2.0",
|
|
4
|
-
"version": "2025.
|
|
8
|
+
"version": "2025.4.0-rc1",
|
|
5
9
|
"module": "dist/index.js",
|
|
6
10
|
"typings": "dist/index.d.ts",
|
|
7
11
|
"publishConfig": {
|
|
@@ -124,5 +128,5 @@
|
|
|
124
128
|
"shx": "0.3.3",
|
|
125
129
|
"typescript": "5.0.4"
|
|
126
130
|
},
|
|
127
|
-
"gitHead": "
|
|
131
|
+
"gitHead": "b8936c65d006d4a4aa89dfb35988af3c007b8637"
|
|
128
132
|
}
|
|
@@ -142,6 +142,24 @@ describe('PipelineConfigService', () => {
|
|
|
142
142
|
});
|
|
143
143
|
});
|
|
144
144
|
|
|
145
|
+
describe('getPipeline', () => {
|
|
146
|
+
it('makes correct get pipeline request', async () => {
|
|
147
|
+
const http = mockHttpClient();
|
|
148
|
+
const pipeline: IPipeline = buildPipeline({});
|
|
149
|
+
|
|
150
|
+
let result: IPipeline = null;
|
|
151
|
+
http.expectGET('/applications/foo/pipelineConfigs/bar%20name').respond(200, pipeline);
|
|
152
|
+
|
|
153
|
+
PipelineConfigService.getPipelineForApplication('foo', 'bar name').then((pipelines: IPipeline) => {
|
|
154
|
+
result = pipelines;
|
|
155
|
+
});
|
|
156
|
+
|
|
157
|
+
$scope.$digest();
|
|
158
|
+
await http.flush();
|
|
159
|
+
expect(result).toEqual(pipeline);
|
|
160
|
+
});
|
|
161
|
+
});
|
|
162
|
+
|
|
145
163
|
describe('stage dependencies', () => {
|
|
146
164
|
let a: IStage, b: IStage, c: IStage, d: IStage;
|
|
147
165
|
let pipeline: IPipeline;
|
|
@@ -30,6 +30,10 @@ export class PipelineConfigService {
|
|
|
30
30
|
});
|
|
31
31
|
}
|
|
32
32
|
|
|
33
|
+
public static getPipelineForApplication(applicationName: string, pipelineName: string): PromiseLike<IPipeline> {
|
|
34
|
+
return REST('/applications').path(applicationName, 'pipelineConfigs', pipelineName).get();
|
|
35
|
+
}
|
|
36
|
+
|
|
33
37
|
public static getStrategiesForApplication(applicationName: string): PromiseLike<IPipeline[]> {
|
|
34
38
|
return REST('/applications')
|
|
35
39
|
.path(applicationName, 'strategyConfigs')
|
|
@@ -9,6 +9,7 @@ import { MigrationTag } from './MigrationTag';
|
|
|
9
9
|
import { AccountTag } from '../../../account';
|
|
10
10
|
import type { Application } from '../../../application/application.model';
|
|
11
11
|
import { CollapsibleSectionStateCache } from '../../../cache';
|
|
12
|
+
import { PipelineConfigService } from '../../config/services/PipelineConfigService';
|
|
12
13
|
import { SETTINGS } from '../../../config/settings';
|
|
13
14
|
import { PipelineTemplateReader, PipelineTemplateV2Service } from '../../config/templates';
|
|
14
15
|
import type {
|
|
@@ -153,7 +154,9 @@ export class ExecutionGroup extends React.PureComponent<IExecutionGroupProps, IE
|
|
|
153
154
|
.then((plan) => resolve(plan))
|
|
154
155
|
.catch(() => resolve(config));
|
|
155
156
|
} else {
|
|
156
|
-
|
|
157
|
+
PipelineConfigService.getPipelineForApplication(this.props.application.name, config.name)
|
|
158
|
+
.then((pipeline) => resolve(pipeline))
|
|
159
|
+
.catch(() => resolve(config));
|
|
157
160
|
}
|
|
158
161
|
}),
|
|
159
162
|
)
|