MCPcopy Create free account
hub / github.com/apache/devlake / MakePipelinePlanV200

Function MakePipelinePlanV200

backend/plugins/gitlab/api/blueprint_v200.go:43–69  ·  view source on GitHub ↗
(
	subtaskMetas []plugin.SubTaskMeta,
	connectionId uint64,
	bpScopes []*coreModels.BlueprintScope,
)

Source from the content-addressed store, hash-verified

41)
42
43func MakePipelinePlanV200(
44 subtaskMetas []plugin.SubTaskMeta,
45 connectionId uint64,
46 bpScopes []*coreModels.BlueprintScope,
47) (coreModels.PipelinePlan, []plugin.Scope, errors.Error) {
48 // load connection, scope and scopeConfig from the db
49 connection, err := dsHelper.ConnSrv.FindByPk(connectionId)
50 if err != nil {
51 return nil, nil, err
52 }
53 scopeDetails, err := dsHelper.ScopeApi.MapScopeDetails(connectionId, bpScopes)
54 if err != nil {
55 return nil, nil, err
56 }
57
58 sc, err := makeScopeV200(connectionId, scopeDetails)
59 if err != nil {
60 return nil, nil, err
61 }
62
63 pp, err := makePipelinePlanV200(subtaskMetas, connection, scopeDetails)
64 if err != nil {
65 return nil, nil, err
66 }
67
68 return pp, sc, nil
69}
70
71func makeScopeV200(
72 connectionId uint64,

Callers

nothing calls this directly

Calls 4

MapScopeDetailsMethod · 0.80
makeScopeV200Function · 0.70
makePipelinePlanV200Function · 0.70
FindByPkMethod · 0.45

Tested by

no test coverage detected