@finos/legend-graph 32.3.39 → 32.4.1
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/lib/graph/metamodel/pure/dataProduct/DataProduct.d.ts +5 -0
- package/lib/graph/metamodel/pure/dataProduct/DataProduct.d.ts.map +1 -1
- package/lib/graph/metamodel/pure/dataProduct/DataProduct.js +6 -0
- package/lib/graph/metamodel/pure/dataProduct/DataProduct.js.map +1 -1
- package/lib/graph/metamodel/pure/packageableElements/store/relational/model/Join.d.ts +1 -1
- package/lib/graph/metamodel/pure/packageableElements/store/relational/model/Join.d.ts.map +1 -1
- package/lib/graph/metamodel/pure/packageableElements/store/relational/model/Join.js +1 -2
- package/lib/graph/metamodel/pure/packageableElements/store/relational/model/Join.js.map +1 -1
- package/lib/graph-manager/AbstractPureGraphManager.d.ts +13 -1
- package/lib/graph-manager/AbstractPureGraphManager.d.ts.map +1 -1
- package/lib/graph-manager/AbstractPureGraphManager.js.map +1 -1
- package/lib/graph-manager/action/analytics/data-product/DataProductAnalysis.d.ts +30 -0
- package/lib/graph-manager/action/analytics/data-product/DataProductAnalysis.d.ts.map +1 -0
- package/lib/graph-manager/action/analytics/data-product/DataProductAnalysis.js +32 -0
- package/lib/graph-manager/action/analytics/data-product/DataProductAnalysis.js.map +1 -0
- package/lib/graph-manager/action/query/Query.d.ts +12 -3
- package/lib/graph-manager/action/query/Query.d.ts.map +1 -1
- package/lib/graph-manager/action/query/Query.js +9 -0
- package/lib/graph-manager/action/query/Query.js.map +1 -1
- package/lib/graph-manager/helpers/DataProductHelper.d.ts.map +1 -1
- package/lib/graph-manager/helpers/DataProductHelper.js +2 -1
- package/lib/graph-manager/helpers/DataProductHelper.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/V1_PureGraphManager.d.ts +12 -4
- package/lib/graph-manager/protocol/pure/v1/V1_PureGraphManager.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/V1_PureGraphManager.js +128 -11
- package/lib/graph-manager/protocol/pure/v1/V1_PureGraphManager.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/engine/V1_EngineHelper.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/engine/V1_EngineHelper.js +34 -4
- package/lib/graph-manager/protocol/pure/v1/engine/V1_EngineHelper.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/engine/query/V1_Query.d.ts +11 -4
- package/lib/graph-manager/protocol/pure/v1/engine/query/V1_Query.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/engine/query/V1_Query.js +26 -8
- package/lib/graph-manager/protocol/pure/v1/engine/query/V1_Query.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/lakehouse/deploy/V1_DataProductArtifact.d.ts +2 -0
- package/lib/graph-manager/protocol/pure/v1/lakehouse/deploy/V1_DataProductArtifact.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/lakehouse/deploy/V1_DataProductArtifact.js +3 -0
- package/lib/graph-manager/protocol/pure/v1/lakehouse/deploy/V1_DataProductArtifact.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_CoreEntitlements.d.ts +5 -5
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_CoreEntitlements.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_CoreEntitlements.js +5 -5
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_CoreEntitlements.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_DataAccessRequest.d.ts +3 -0
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_DataAccessRequest.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_DataAccessRequest.js +3 -0
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_DataAccessRequest.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_Workflow.d.ts +27 -0
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_Workflow.d.ts.map +1 -0
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_Workflow.js +27 -0
- package/lib/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_Workflow.js.map +1 -0
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementFourthPassBuilder.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementFourthPassBuilder.js +9 -3
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementFourthPassBuilder.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementSecondPassBuilder.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementSecondPassBuilder.js +2 -0
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementSecondPassBuilder.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/helpers/V1_DatabaseBuilderHelper.d.ts +2 -2
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/helpers/V1_DatabaseBuilderHelper.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/helpers/V1_DatabaseBuilderHelper.js +3 -4
- package/lib/graph-manager/protocol/pure/v1/transformation/pureGraph/to/helpers/V1_DatabaseBuilderHelper.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_CoreEntitlementsSerializationHelper.d.ts.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_CoreEntitlementsSerializationHelper.js.map +1 -1
- package/lib/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_WorkflowSerializationHelper.d.ts +18 -0
- package/lib/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_WorkflowSerializationHelper.d.ts.map +1 -0
- package/lib/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_WorkflowSerializationHelper.js +29 -0
- package/lib/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_WorkflowSerializationHelper.js.map +1 -0
- package/lib/index.d.ts +4 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +4 -1
- package/lib/index.js.map +1 -1
- package/lib/package.json +1 -1
- package/package.json +1 -1
- package/src/graph/metamodel/pure/dataProduct/DataProduct.ts +6 -0
- package/src/graph/metamodel/pure/packageableElements/store/relational/model/Join.ts +2 -3
- package/src/graph-manager/AbstractPureGraphManager.ts +35 -1
- package/src/graph-manager/action/analytics/data-product/DataProductAnalysis.ts +47 -0
- package/src/graph-manager/action/query/Query.ts +15 -3
- package/src/graph-manager/helpers/DataProductHelper.ts +2 -1
- package/src/graph-manager/protocol/pure/v1/V1_PureGraphManager.ts +236 -16
- package/src/graph-manager/protocol/pure/v1/engine/V1_EngineHelper.ts +41 -4
- package/src/graph-manager/protocol/pure/v1/engine/query/V1_Query.ts +41 -10
- package/src/graph-manager/protocol/pure/v1/lakehouse/deploy/V1_DataProductArtifact.ts +5 -0
- package/src/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_CoreEntitlements.ts +6 -6
- package/src/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_DataAccessRequest.ts +4 -0
- package/src/graph-manager/protocol/pure/v1/lakehouse/entitlements/V1_Workflow.ts +27 -0
- package/src/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementFourthPassBuilder.ts +11 -4
- package/src/graph-manager/protocol/pure/v1/transformation/pureGraph/to/V1_ElementSecondPassBuilder.ts +2 -0
- package/src/graph-manager/protocol/pure/v1/transformation/pureGraph/to/helpers/V1_DatabaseBuilderHelper.ts +9 -12
- package/src/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_CoreEntitlementsSerializationHelper.ts +0 -1
- package/src/graph-manager/protocol/pure/v1/transformation/pureProtocol/serializationHelpers/lakehouse/V1_WorkflowSerializationHelper.ts +33 -0
- package/src/index.ts +7 -0
- package/tsconfig.json +3 -0
|
@@ -147,6 +147,7 @@ import { V1_GenerationSpecification } from './model/packageableElements/generati
|
|
|
147
147
|
import { V1_Mapping } from './model/packageableElements/mapping/V1_Mapping.js';
|
|
148
148
|
import { V1_ConcreteFunctionDefinition } from './model/packageableElements/function/V1_ConcreteFunctionDefinition.js';
|
|
149
149
|
import { V1_PureModelContextComposite } from './model/context/V1_PureModelContextComposite.js';
|
|
150
|
+
import { V1_PureModelContextCombination } from './model/context/V1_PureModelContextCombination.js';
|
|
150
151
|
import { V1_LegendSDLC } from './model/context/V1_SDLC.js';
|
|
151
152
|
import { V1_Protocol } from './model/V1_Protocol.js';
|
|
152
153
|
import type { V1_PureModelContext } from './model/context/V1_PureModelContext.js';
|
|
@@ -211,6 +212,7 @@ import { V1_buildExecutionResult } from './engine/execution/V1_ExecutionHelper.j
|
|
|
211
212
|
import {
|
|
212
213
|
type Entity,
|
|
213
214
|
type EntitiesWithOrigin,
|
|
215
|
+
type ProjectGAVCoordinates,
|
|
214
216
|
ENTITY_PATH_DELIMITER,
|
|
215
217
|
} from '@finos/legend-storage';
|
|
216
218
|
import {
|
|
@@ -219,7 +221,10 @@ import {
|
|
|
219
221
|
PureClientVersion,
|
|
220
222
|
SystemGraphBuilderError,
|
|
221
223
|
} from '../../../../graph-manager/GraphManagerUtils.js';
|
|
222
|
-
import {
|
|
224
|
+
import {
|
|
225
|
+
PackageableElementExplicitReference,
|
|
226
|
+
PackageableElementReference,
|
|
227
|
+
} from '../../../../graph/metamodel/pure/packageableElements/PackageableElementReference.js';
|
|
223
228
|
import type { GraphManagerPluginManager } from '../../../GraphManagerPluginManager.js';
|
|
224
229
|
import type { QuerySearchSpecification } from '../../../../graph-manager/action/query/QuerySearchSpecification.js';
|
|
225
230
|
import type { ExternalFormatDescription } from '../../../../graph-manager/action/externalFormat/ExternalFormatDescription.js';
|
|
@@ -363,6 +368,22 @@ import {
|
|
|
363
368
|
V1_createGenericTypeWithElementPath,
|
|
364
369
|
} from './helpers/V1_DomainHelper.js';
|
|
365
370
|
import { V1_DataProduct } from './model/packageableElements/dataProduct/V1_DataProduct.js';
|
|
371
|
+
import {
|
|
372
|
+
V1_DataProductArtifact,
|
|
373
|
+
V1_ModelAccessPointGroupInfo,
|
|
374
|
+
type V1_NativeModelExecutionContextInfo,
|
|
375
|
+
type V1_MappingGenerationInfo,
|
|
376
|
+
} from './lakehouse/deploy/V1_DataProductArtifact.js';
|
|
377
|
+
import {
|
|
378
|
+
DataProductAnalysisQueryResult,
|
|
379
|
+
DataProductAnalysis,
|
|
380
|
+
} from '../../../action/analytics/data-product/DataProductAnalysis.js';
|
|
381
|
+
import {
|
|
382
|
+
DataProductAccessType,
|
|
383
|
+
ModelAccessPointGroup,
|
|
384
|
+
NativeModelAccess,
|
|
385
|
+
NativeModelExecutionContext,
|
|
386
|
+
} from '../../../../graph/metamodel/pure/dataProduct/DataProduct.js';
|
|
366
387
|
import { V1_MemSQLFunction } from './model/packageableElements/function/V1_MemSQLFunction.js';
|
|
367
388
|
import { LineageModel } from '../../../../graph/metamodel/pure/lineage/LineageModel.js';
|
|
368
389
|
import {
|
|
@@ -2696,18 +2717,29 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
2696
2717
|
);
|
|
2697
2718
|
}
|
|
2698
2719
|
|
|
2699
|
-
public createExecutionInput = (
|
|
2720
|
+
public createExecutionInput = async (
|
|
2700
2721
|
graph: PureModel,
|
|
2701
2722
|
mapping: Mapping | undefined,
|
|
2702
2723
|
lambda: RawLambda,
|
|
2703
2724
|
runtime: Runtime | undefined,
|
|
2704
2725
|
clientVersion: string | undefined,
|
|
2705
2726
|
options?: ExecutionOptions,
|
|
2706
|
-
): V1_ExecuteInput =>
|
|
2707
|
-
|
|
2708
|
-
graph.origin
|
|
2709
|
-
|
|
2710
|
-
|
|
2727
|
+
): Promise<V1_ExecuteInput> => {
|
|
2728
|
+
let context: V1_PureModelContext = graph.origin
|
|
2729
|
+
? this.buildPureModelSDLCPointer(graph.origin, undefined)
|
|
2730
|
+
: this.getFullGraphModelData(graph);
|
|
2731
|
+
if (
|
|
2732
|
+
options?.floatingExecutionElements &&
|
|
2733
|
+
options.floatingExecutionElements.length > 0
|
|
2734
|
+
) {
|
|
2735
|
+
const floatingData = new V1_PureModelContextData();
|
|
2736
|
+
floatingData.elements = options.floatingExecutionElements.map((element) =>
|
|
2737
|
+
this.elementToProtocol(element),
|
|
2738
|
+
);
|
|
2739
|
+
context = new V1_PureModelContextCombination([context, floatingData]);
|
|
2740
|
+
}
|
|
2741
|
+
return this.createExecutionInputWithPureModelContext(
|
|
2742
|
+
context,
|
|
2711
2743
|
mapping,
|
|
2712
2744
|
lambda,
|
|
2713
2745
|
runtime,
|
|
@@ -2715,15 +2747,16 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
2715
2747
|
new V1_ExecuteInput(),
|
|
2716
2748
|
options,
|
|
2717
2749
|
);
|
|
2750
|
+
};
|
|
2718
2751
|
|
|
2719
|
-
public createLineageInput = (
|
|
2752
|
+
public createLineageInput = async (
|
|
2720
2753
|
graph: PureModel,
|
|
2721
2754
|
mapping: Mapping | undefined,
|
|
2722
2755
|
lambda: RawLambda,
|
|
2723
2756
|
runtime: Runtime | undefined,
|
|
2724
2757
|
clientVersion: string | undefined,
|
|
2725
|
-
): V1_LineageInput => {
|
|
2726
|
-
const executionInput = this.createExecutionInput(
|
|
2758
|
+
): Promise<V1_LineageInput> => {
|
|
2759
|
+
const executionInput = await this.createExecutionInput(
|
|
2727
2760
|
graph,
|
|
2728
2761
|
mapping,
|
|
2729
2762
|
lambda,
|
|
@@ -2933,13 +2966,13 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
2933
2966
|
}
|
|
2934
2967
|
|
|
2935
2968
|
async _runQuery(
|
|
2936
|
-
createV1ExecuteInputFunc: () => V1_ExecuteInput
|
|
2969
|
+
createV1ExecuteInputFunc: () => V1_ExecuteInput | Promise<V1_ExecuteInput>,
|
|
2937
2970
|
options?: ExecutionOptions,
|
|
2938
2971
|
_report?: GraphManagerOperationReport,
|
|
2939
2972
|
): Promise<ExecutionResultWithMetadata> {
|
|
2940
2973
|
const report = _report ?? createGraphManagerOperationReport();
|
|
2941
2974
|
const stopWatch = new StopWatch();
|
|
2942
|
-
const input = createV1ExecuteInputFunc();
|
|
2975
|
+
const input = await createV1ExecuteInputFunc();
|
|
2943
2976
|
stopWatch.record(GRAPH_MANAGER_EVENT.V1_ENGINE_OPERATION_INPUT__SUCCESS);
|
|
2944
2977
|
|
|
2945
2978
|
const result = await this.engine.runQuery(input, options);
|
|
@@ -2975,7 +3008,7 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
2975
3008
|
const report = _report ?? createGraphManagerOperationReport();
|
|
2976
3009
|
const stopWatch = new StopWatch();
|
|
2977
3010
|
|
|
2978
|
-
const input = this.createExecutionInput(
|
|
3011
|
+
const input = await this.createExecutionInput(
|
|
2979
3012
|
graph,
|
|
2980
3013
|
mapping,
|
|
2981
3014
|
lambda,
|
|
@@ -3082,7 +3115,7 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
3082
3115
|
const report = _report ?? createGraphManagerOperationReport();
|
|
3083
3116
|
const stopWatch = new StopWatch();
|
|
3084
3117
|
|
|
3085
|
-
const input = this.createExecutionInput(
|
|
3118
|
+
const input = await this.createExecutionInput(
|
|
3086
3119
|
graph,
|
|
3087
3120
|
mapping,
|
|
3088
3121
|
lambda,
|
|
@@ -3116,7 +3149,7 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
3116
3149
|
const report = _report ?? createGraphManagerOperationReport();
|
|
3117
3150
|
const stopWatch = new StopWatch();
|
|
3118
3151
|
|
|
3119
|
-
const input = this.createExecutionInput(
|
|
3152
|
+
const input = await this.createExecutionInput(
|
|
3120
3153
|
graph,
|
|
3121
3154
|
mapping,
|
|
3122
3155
|
lambda,
|
|
@@ -3748,6 +3781,193 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
3748
3781
|
);
|
|
3749
3782
|
}
|
|
3750
3783
|
|
|
3784
|
+
async analyzeDataProductAndBuildMinimalGraph(
|
|
3785
|
+
dataProductPath: string,
|
|
3786
|
+
cacheRetriever: () => Promise<PlainObject>,
|
|
3787
|
+
pureGraph: PureModel,
|
|
3788
|
+
accessPointId: string,
|
|
3789
|
+
dataProductAccessType: DataProductAccessType,
|
|
3790
|
+
projectInfo: ProjectGAVCoordinates,
|
|
3791
|
+
functionEntitiesRetriever?: () => Promise<
|
|
3792
|
+
[PlainObject<Entity>[], PlainObject<Entity>[]]
|
|
3793
|
+
>,
|
|
3794
|
+
graphReport?: GraphManagerOperationReport,
|
|
3795
|
+
): Promise<DataProductAnalysisQueryResult> {
|
|
3796
|
+
// Fetch the data product artifact from cache
|
|
3797
|
+
const artifactJson = await cacheRetriever();
|
|
3798
|
+
const artifact =
|
|
3799
|
+
V1_DataProductArtifact.serialization.fromJson(artifactJson);
|
|
3800
|
+
|
|
3801
|
+
return this.buildDataProductAnalysis(
|
|
3802
|
+
artifact,
|
|
3803
|
+
dataProductPath,
|
|
3804
|
+
pureGraph,
|
|
3805
|
+
accessPointId,
|
|
3806
|
+
dataProductAccessType,
|
|
3807
|
+
projectInfo,
|
|
3808
|
+
graphReport,
|
|
3809
|
+
);
|
|
3810
|
+
}
|
|
3811
|
+
|
|
3812
|
+
async buildDataProductAnalysis(
|
|
3813
|
+
artifact: V1_DataProductArtifact,
|
|
3814
|
+
dataProductPath: string,
|
|
3815
|
+
pureGraph: PureModel,
|
|
3816
|
+
accessPointId: string,
|
|
3817
|
+
dataProductAccessType: DataProductAccessType,
|
|
3818
|
+
projectInfo: ProjectGAVCoordinates,
|
|
3819
|
+
graphReport?: GraphManagerOperationReport,
|
|
3820
|
+
): Promise<DataProductAnalysisQueryResult> {
|
|
3821
|
+
// Collect all mapping generation infos from model access point groups and native model access
|
|
3822
|
+
const allMappingGenInfos = new Map<string, V1_MappingGenerationInfo>();
|
|
3823
|
+
|
|
3824
|
+
const modelAccessPointGroups = artifact.accessPointGroups.filter(
|
|
3825
|
+
(group): group is V1_ModelAccessPointGroupInfo =>
|
|
3826
|
+
group instanceof V1_ModelAccessPointGroupInfo,
|
|
3827
|
+
);
|
|
3828
|
+
for (const group of modelAccessPointGroups) {
|
|
3829
|
+
allMappingGenInfos.set(
|
|
3830
|
+
group.mappingGeneration.path,
|
|
3831
|
+
group.mappingGeneration,
|
|
3832
|
+
);
|
|
3833
|
+
}
|
|
3834
|
+
|
|
3835
|
+
if (artifact.nativeModelAccess?.mappingGenerations) {
|
|
3836
|
+
for (const [path, genInfo] of artifact.nativeModelAccess
|
|
3837
|
+
.mappingGenerations) {
|
|
3838
|
+
if (!allMappingGenInfos.has(path)) {
|
|
3839
|
+
allMappingGenInfos.set(path, genInfo);
|
|
3840
|
+
}
|
|
3841
|
+
}
|
|
3842
|
+
}
|
|
3843
|
+
|
|
3844
|
+
// Resolve mapping path from accessPointId and dataProductAccessType
|
|
3845
|
+
let mappingPath: string | undefined;
|
|
3846
|
+
let accessGroup:
|
|
3847
|
+
| V1_ModelAccessPointGroupInfo
|
|
3848
|
+
| V1_NativeModelExecutionContextInfo
|
|
3849
|
+
| undefined = undefined;
|
|
3850
|
+
if (dataProductAccessType === DataProductAccessType.MODEL) {
|
|
3851
|
+
const group = modelAccessPointGroups.find((g) => g.id === accessPointId);
|
|
3852
|
+
if (group) {
|
|
3853
|
+
mappingPath = group.mappingGeneration.path;
|
|
3854
|
+
accessGroup = group;
|
|
3855
|
+
}
|
|
3856
|
+
} else if (dataProductAccessType === DataProductAccessType.NATIVE) {
|
|
3857
|
+
const nativeCtx =
|
|
3858
|
+
artifact.nativeModelAccess?.nativeModelExecutionContexts.find(
|
|
3859
|
+
(ctx) => ctx.key === accessPointId,
|
|
3860
|
+
);
|
|
3861
|
+
if (nativeCtx) {
|
|
3862
|
+
mappingPath = nativeCtx.mapping;
|
|
3863
|
+
accessGroup = nativeCtx;
|
|
3864
|
+
}
|
|
3865
|
+
}
|
|
3866
|
+
|
|
3867
|
+
if (!mappingPath) {
|
|
3868
|
+
throw new Error(
|
|
3869
|
+
`Can't resolve mapping path for access point '${accessPointId}' (type: ${dataProductAccessType}) in data product '${dataProductPath}'`,
|
|
3870
|
+
);
|
|
3871
|
+
}
|
|
3872
|
+
if (!accessGroup) {
|
|
3873
|
+
throw new Error(
|
|
3874
|
+
`Can't resolve access group for access point '${accessPointId}' (type: ${dataProductAccessType}) in data product '${dataProductPath}'`,
|
|
3875
|
+
);
|
|
3876
|
+
}
|
|
3877
|
+
// Build the minimal graph using ONLY the elements from the resolved mapping
|
|
3878
|
+
const resolvedMappingGenInfo = mappingPath
|
|
3879
|
+
? allMappingGenInfos.get(mappingPath)
|
|
3880
|
+
: undefined;
|
|
3881
|
+
|
|
3882
|
+
if (!resolvedMappingGenInfo) {
|
|
3883
|
+
throw new Error(
|
|
3884
|
+
`Can't find mapping generation info for access point '${accessPointId}' (type: ${dataProductAccessType}) in data product '${dataProductPath}'`,
|
|
3885
|
+
);
|
|
3886
|
+
}
|
|
3887
|
+
|
|
3888
|
+
// Create a dummy mapping for the resolved mapping path
|
|
3889
|
+
const dummyMapping = new V1_Mapping();
|
|
3890
|
+
dummyMapping.package = extractPackagePathFromPath(mappingPath) ?? '';
|
|
3891
|
+
dummyMapping.name = extractElementNameFromPath(mappingPath);
|
|
3892
|
+
|
|
3893
|
+
// Create a dummy data product element
|
|
3894
|
+
const dummyDataProduct = new V1_DataProduct();
|
|
3895
|
+
dummyDataProduct.package =
|
|
3896
|
+
extractPackagePathFromPath(dataProductPath) ?? '';
|
|
3897
|
+
dummyDataProduct.name = extractElementNameFromPath(dataProductPath);
|
|
3898
|
+
dummyDataProduct.title = artifact.dataProduct.title;
|
|
3899
|
+
dummyDataProduct.description = artifact.dataProduct.description;
|
|
3900
|
+
// Build the minimal graph from the resolved mapping's model elements + dummy mapping + dummy data product
|
|
3901
|
+
const graphEntities = resolvedMappingGenInfo.model.elements
|
|
3902
|
+
.concat([dummyMapping])
|
|
3903
|
+
.concat(dummyDataProduct)
|
|
3904
|
+
.filter((el) => !pureGraph.getNullableElement(el.path, false))
|
|
3905
|
+
.map((el) => this.elementProtocolToEntity(el));
|
|
3906
|
+
await this.buildGraph(
|
|
3907
|
+
pureGraph,
|
|
3908
|
+
graphEntities,
|
|
3909
|
+
ActionState.create(),
|
|
3910
|
+
{
|
|
3911
|
+
origin: new LegendSDLC(
|
|
3912
|
+
projectInfo.groupId,
|
|
3913
|
+
projectInfo.artifactId,
|
|
3914
|
+
projectInfo.versionId,
|
|
3915
|
+
),
|
|
3916
|
+
},
|
|
3917
|
+
graphReport,
|
|
3918
|
+
);
|
|
3919
|
+
|
|
3920
|
+
const data = pureGraph.getDataProduct(dataProductPath);
|
|
3921
|
+
// build access point group
|
|
3922
|
+
let exec: ModelAccessPointGroup | NativeModelExecutionContext;
|
|
3923
|
+
if (accessGroup instanceof V1_ModelAccessPointGroupInfo) {
|
|
3924
|
+
const group = new ModelAccessPointGroup();
|
|
3925
|
+
group.id = accessGroup.id;
|
|
3926
|
+
data.accessPointGroups = [group];
|
|
3927
|
+
group.mapping = PackageableElementExplicitReference.create(
|
|
3928
|
+
pureGraph.getMapping(mappingPath),
|
|
3929
|
+
);
|
|
3930
|
+
exec = group;
|
|
3931
|
+
} else {
|
|
3932
|
+
const nativeAccess = new NativeModelExecutionContext();
|
|
3933
|
+
nativeAccess.key = accessGroup.key;
|
|
3934
|
+
nativeAccess.mapping = PackageableElementExplicitReference.create(
|
|
3935
|
+
pureGraph.getMapping(mappingPath),
|
|
3936
|
+
);
|
|
3937
|
+
const na = new NativeModelAccess();
|
|
3938
|
+
na.nativeModelExecutionContexts = [nativeAccess];
|
|
3939
|
+
data.nativeModelAccess = na;
|
|
3940
|
+
exec = nativeAccess;
|
|
3941
|
+
}
|
|
3942
|
+
|
|
3943
|
+
// Build MappingModelCoverageAnalysisResult for the resolved mapping only
|
|
3944
|
+
const mappingToMappingCoverageResult = new Map<
|
|
3945
|
+
string,
|
|
3946
|
+
MappingModelCoverageAnalysisResult
|
|
3947
|
+
>();
|
|
3948
|
+
const v1Result = new V1_MappingModelCoverageAnalysisResult();
|
|
3949
|
+
v1Result.mappedEntities = resolvedMappingGenInfo.mappedEntities;
|
|
3950
|
+
v1Result.model = resolvedMappingGenInfo.model;
|
|
3951
|
+
mappingToMappingCoverageResult.set(
|
|
3952
|
+
mappingPath,
|
|
3953
|
+
V1_buildModelCoverageAnalysisResult(
|
|
3954
|
+
v1Result,
|
|
3955
|
+
this,
|
|
3956
|
+
pureGraph.getMapping(mappingPath),
|
|
3957
|
+
resolvedMappingGenInfo.model,
|
|
3958
|
+
),
|
|
3959
|
+
);
|
|
3960
|
+
|
|
3961
|
+
// Build the analysis result
|
|
3962
|
+
const result = new DataProductAnalysis();
|
|
3963
|
+
result.path = dataProductPath;
|
|
3964
|
+
result.title = artifact.dataProduct.title;
|
|
3965
|
+
result.description = artifact.dataProduct.description;
|
|
3966
|
+
result.mappingToMappingCoverageResult = mappingToMappingCoverageResult;
|
|
3967
|
+
|
|
3968
|
+
return new DataProductAnalysisQueryResult(mappingPath, result, exec);
|
|
3969
|
+
}
|
|
3970
|
+
|
|
3751
3971
|
async buildDatabase(input: DatabaseBuilderInput): Promise<Entity[]> {
|
|
3752
3972
|
const dbBuilderInput = new V1_DatabaseBuilderInput();
|
|
3753
3973
|
dbBuilderInput.connection = V1_transformRelationalDatabaseConnection(
|
|
@@ -4764,7 +4984,7 @@ export class V1_PureGraphManager extends AbstractPureGraphManager {
|
|
|
4764
4984
|
const report = _report ?? createGraphManagerOperationReport();
|
|
4765
4985
|
const stopWatch = new StopWatch();
|
|
4766
4986
|
|
|
4767
|
-
const input = this.createLineageInput(
|
|
4987
|
+
const input = await this.createLineageInput(
|
|
4768
4988
|
graph,
|
|
4769
4989
|
mapping,
|
|
4770
4990
|
lambda,
|
|
@@ -32,7 +32,10 @@ import {
|
|
|
32
32
|
type QueryExecutionContextInfo,
|
|
33
33
|
QueryExplicitExecutionContextInfo,
|
|
34
34
|
QueryDataSpaceExecutionContextInfo,
|
|
35
|
-
|
|
35
|
+
QueryDataProductNativeExecutionContext,
|
|
36
|
+
QueryDataProductModelAccessExecutionContext,
|
|
37
|
+
QueryDataProductNativeExecutionContextInfo,
|
|
38
|
+
QueryDataProductModelAccessExecutionContextInfo,
|
|
36
39
|
} from '../../../../../graph-manager/action/query/Query.js';
|
|
37
40
|
import {
|
|
38
41
|
type V1_LightQuery,
|
|
@@ -41,7 +44,8 @@ import {
|
|
|
41
44
|
V1_QueryExplicitExecutionContext,
|
|
42
45
|
V1_QueryDataSpaceExecutionContext,
|
|
43
46
|
type V1_QueryExecutionContext,
|
|
44
|
-
|
|
47
|
+
V1_DataProductNativeExecutionContext,
|
|
48
|
+
V1_DataProductModelAccessExecutionContext,
|
|
45
49
|
} from './query/V1_Query.js';
|
|
46
50
|
import type { PureModel } from '../../../../../graph/PureModel.js';
|
|
47
51
|
import { DEPRECATED__ServiceTestResult } from '../../../../../graph-manager/action/service/DEPRECATED__ServiceTestResult.js';
|
|
@@ -202,6 +206,20 @@ export const V1_buildExecutionContext = (
|
|
|
202
206
|
exec.dataSpacePath = protocolExecContext.dataSpacePath;
|
|
203
207
|
exec.executionKey = protocolExecContext.executionKey;
|
|
204
208
|
return exec;
|
|
209
|
+
} else if (
|
|
210
|
+
protocolExecContext instanceof V1_DataProductNativeExecutionContext
|
|
211
|
+
) {
|
|
212
|
+
const exec = new QueryDataProductNativeExecutionContext();
|
|
213
|
+
exec.dataProductPath = protocolExecContext.dataProductPath;
|
|
214
|
+
exec.executionKey = protocolExecContext.executionKey;
|
|
215
|
+
return exec;
|
|
216
|
+
} else if (
|
|
217
|
+
protocolExecContext instanceof V1_DataProductModelAccessExecutionContext
|
|
218
|
+
) {
|
|
219
|
+
const exec = new QueryDataProductModelAccessExecutionContext();
|
|
220
|
+
exec.dataProductPath = protocolExecContext.dataProductPath;
|
|
221
|
+
exec.accessPointGroupId = protocolExecContext.accessPointGroupId;
|
|
222
|
+
return exec;
|
|
205
223
|
}
|
|
206
224
|
throw new UnsupportedOperationError('Unsupported query execution context');
|
|
207
225
|
};
|
|
@@ -233,6 +251,18 @@ export const V1_buildExecutionContextInfo = (
|
|
|
233
251
|
exec.dataSpacePath = v1_execContext.dataSpacePath;
|
|
234
252
|
exec.executionKey = v1_execContext.executionKey;
|
|
235
253
|
return exec;
|
|
254
|
+
} else if (v1_execContext instanceof V1_DataProductNativeExecutionContext) {
|
|
255
|
+
const exec = new QueryDataProductNativeExecutionContextInfo();
|
|
256
|
+
exec.dataProductPath = v1_execContext.dataProductPath;
|
|
257
|
+
exec.executionKey = v1_execContext.executionKey;
|
|
258
|
+
return exec;
|
|
259
|
+
} else if (
|
|
260
|
+
v1_execContext instanceof V1_DataProductModelAccessExecutionContext
|
|
261
|
+
) {
|
|
262
|
+
const exec = new QueryDataProductModelAccessExecutionContextInfo();
|
|
263
|
+
exec.dataProductPath = v1_execContext.dataProductPath;
|
|
264
|
+
exec.accessPointGroupId = v1_execContext.accessPointGroupId;
|
|
265
|
+
return exec;
|
|
236
266
|
}
|
|
237
267
|
throw new UnsupportedOperationError('Unsupported query execution context');
|
|
238
268
|
};
|
|
@@ -340,11 +370,18 @@ export const V1_transformQueryExecutionContext = (
|
|
|
340
370
|
protocol.dataSpacePath = execContext.dataSpacePath;
|
|
341
371
|
protocol.executionKey = execContext.executionKey;
|
|
342
372
|
return protocol;
|
|
343
|
-
} else if (execContext instanceof
|
|
344
|
-
const protocol = new
|
|
373
|
+
} else if (execContext instanceof QueryDataProductNativeExecutionContext) {
|
|
374
|
+
const protocol = new V1_DataProductNativeExecutionContext();
|
|
345
375
|
protocol.dataProductPath = execContext.dataProductPath;
|
|
346
376
|
protocol.executionKey = execContext.executionKey;
|
|
347
377
|
return protocol;
|
|
378
|
+
} else if (
|
|
379
|
+
execContext instanceof QueryDataProductModelAccessExecutionContext
|
|
380
|
+
) {
|
|
381
|
+
const protocol = new V1_DataProductModelAccessExecutionContext();
|
|
382
|
+
protocol.dataProductPath = execContext.dataProductPath;
|
|
383
|
+
protocol.accessPointGroupId = execContext.accessPointGroupId;
|
|
384
|
+
return protocol;
|
|
348
385
|
}
|
|
349
386
|
throw new UnsupportedOperationError('Unsupported query execution context');
|
|
350
387
|
};
|
|
@@ -65,7 +65,8 @@ export class V1_QueryExecutionContext {}
|
|
|
65
65
|
export enum V1_QueryExecutionContextType {
|
|
66
66
|
QUERY_EXPLICIT_EXECUTION_CONTEXT = 'explicitExecutionContext',
|
|
67
67
|
QUERY_DATASAPCE_EXECUTION_CONTEXT = 'dataSpaceExecutionContext',
|
|
68
|
-
|
|
68
|
+
QUERY_DATAPRODUCT_NATIVE_EXECUTION_CONTEXT = 'dataProductNativeExecutionContext',
|
|
69
|
+
QUERY_DATAPRODUCT_MODEL_ACCESS_EXECUTION_CONTEXT = 'dataProductModelAccessExecutionContext',
|
|
69
70
|
}
|
|
70
71
|
|
|
71
72
|
export class V1_QueryExplicitExecutionContext extends V1_QueryExecutionContext {
|
|
@@ -104,17 +105,37 @@ export class V1_QueryDataSpaceExecutionContext extends V1_QueryExecutionContext
|
|
|
104
105
|
);
|
|
105
106
|
}
|
|
106
107
|
|
|
107
|
-
export class V1_QueryDataProductExecutionContext extends V1_QueryExecutionContext {
|
|
108
|
+
export abstract class V1_QueryDataProductExecutionContext extends V1_QueryExecutionContext {
|
|
108
109
|
dataProductPath!: string;
|
|
109
|
-
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
export class V1_DataProductNativeExecutionContext extends V1_QueryDataProductExecutionContext {
|
|
113
|
+
executionKey!: string;
|
|
110
114
|
|
|
111
115
|
static readonly serialization = new SerializationFactory(
|
|
112
|
-
createModelSchema(
|
|
116
|
+
createModelSchema(V1_DataProductNativeExecutionContext, {
|
|
113
117
|
_type: usingConstantValueSchema(
|
|
114
|
-
V1_QueryExecutionContextType.
|
|
118
|
+
V1_QueryExecutionContextType.QUERY_DATAPRODUCT_NATIVE_EXECUTION_CONTEXT,
|
|
115
119
|
),
|
|
116
120
|
dataProductPath: primitive(),
|
|
117
|
-
executionKey:
|
|
121
|
+
executionKey: primitive(),
|
|
122
|
+
}),
|
|
123
|
+
{
|
|
124
|
+
deserializeNullAsUndefined: true,
|
|
125
|
+
},
|
|
126
|
+
);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
export class V1_DataProductModelAccessExecutionContext extends V1_QueryDataProductExecutionContext {
|
|
130
|
+
accessPointGroupId!: string;
|
|
131
|
+
|
|
132
|
+
static readonly serialization = new SerializationFactory(
|
|
133
|
+
createModelSchema(V1_DataProductModelAccessExecutionContext, {
|
|
134
|
+
_type: usingConstantValueSchema(
|
|
135
|
+
V1_QueryExecutionContextType.QUERY_DATAPRODUCT_MODEL_ACCESS_EXECUTION_CONTEXT,
|
|
136
|
+
),
|
|
137
|
+
dataProductPath: primitive(),
|
|
138
|
+
accessPointGroupId: primitive(),
|
|
118
139
|
}),
|
|
119
140
|
{
|
|
120
141
|
deserializeNullAsUndefined: true,
|
|
@@ -136,9 +157,14 @@ export const V1_deserializeQueryExecutionContext = (
|
|
|
136
157
|
V1_QueryDataSpaceExecutionContext.serialization.schema,
|
|
137
158
|
json,
|
|
138
159
|
);
|
|
139
|
-
case V1_QueryExecutionContextType.
|
|
160
|
+
case V1_QueryExecutionContextType.QUERY_DATAPRODUCT_NATIVE_EXECUTION_CONTEXT:
|
|
140
161
|
return deserialize(
|
|
141
|
-
|
|
162
|
+
V1_DataProductNativeExecutionContext.serialization.schema,
|
|
163
|
+
json,
|
|
164
|
+
);
|
|
165
|
+
case V1_QueryExecutionContextType.QUERY_DATAPRODUCT_MODEL_ACCESS_EXECUTION_CONTEXT:
|
|
166
|
+
return deserialize(
|
|
167
|
+
V1_DataProductModelAccessExecutionContext.serialization.schema,
|
|
142
168
|
json,
|
|
143
169
|
);
|
|
144
170
|
default: {
|
|
@@ -162,9 +188,14 @@ export const V1_serializeQueryExecutionContext = (
|
|
|
162
188
|
V1_QueryDataSpaceExecutionContext.serialization.schema,
|
|
163
189
|
protocol,
|
|
164
190
|
);
|
|
165
|
-
} else if (protocol instanceof
|
|
191
|
+
} else if (protocol instanceof V1_DataProductNativeExecutionContext) {
|
|
192
|
+
return serialize(
|
|
193
|
+
V1_DataProductNativeExecutionContext.serialization.schema,
|
|
194
|
+
protocol,
|
|
195
|
+
);
|
|
196
|
+
} else if (protocol instanceof V1_DataProductModelAccessExecutionContext) {
|
|
166
197
|
return serialize(
|
|
167
|
-
|
|
198
|
+
V1_DataProductModelAccessExecutionContext.serialization.schema,
|
|
168
199
|
protocol,
|
|
169
200
|
);
|
|
170
201
|
}
|
|
@@ -45,6 +45,7 @@ import { V1_relationElementModelSchema } from '../../transformation/pureProtocol
|
|
|
45
45
|
import { V1_pureModelContextDataPropSchema } from '../../transformation/pureProtocol/V1_PureProtocolSerialization.js';
|
|
46
46
|
import type { V1_PureModelContextData } from '../../model/context/V1_PureModelContextData.js';
|
|
47
47
|
import type { V1_Multiplicity } from '../../model/packageableElements/domain/V1_Multiplicity.js';
|
|
48
|
+
import { V1_MappedEntity } from '../../engine/analytics/V1_MappingModelCoverageAnalysis.js';
|
|
48
49
|
import { V1_multiplicityModelSchema } from '../../transformation/pureProtocol/serializationHelpers/V1_CoreSerializationHelper.js';
|
|
49
50
|
|
|
50
51
|
export enum V1_DataProductTypeEnum {
|
|
@@ -275,11 +276,15 @@ export class V1_DiagramInfo {
|
|
|
275
276
|
export class V1_MappingGenerationInfo {
|
|
276
277
|
path!: string;
|
|
277
278
|
model!: V1_PureModelContextData;
|
|
279
|
+
mappedEntities: V1_MappedEntity[] = [];
|
|
278
280
|
|
|
279
281
|
static readonly serialization = new SerializationFactory(
|
|
280
282
|
createModelSchema(V1_MappingGenerationInfo, {
|
|
281
283
|
path: primitive(),
|
|
282
284
|
model: V1_pureModelContextDataPropSchema,
|
|
285
|
+
mappedEntities: list(
|
|
286
|
+
usingModelSchema(V1_MappedEntity.serialization.schema),
|
|
287
|
+
),
|
|
283
288
|
}),
|
|
284
289
|
);
|
|
285
290
|
}
|
|
@@ -134,6 +134,12 @@ export class V1_DataBundle extends V1_ConsumerEntitlementResource {
|
|
|
134
134
|
|
|
135
135
|
// -------------------------------------- Contract User Membership -------------------------------------
|
|
136
136
|
|
|
137
|
+
export class V1_ContractUserMembership {
|
|
138
|
+
guid!: string;
|
|
139
|
+
user!: V1_User;
|
|
140
|
+
status!: V1_UserApprovalStatus;
|
|
141
|
+
}
|
|
142
|
+
|
|
137
143
|
export enum V1_UserApprovalStatus {
|
|
138
144
|
PENDING = 'PENDING',
|
|
139
145
|
APPROVED = 'APPROVED',
|
|
@@ -141,9 +147,3 @@ export enum V1_UserApprovalStatus {
|
|
|
141
147
|
REVOKED = 'REVOKED',
|
|
142
148
|
CLOSED = 'CLOSED',
|
|
143
149
|
}
|
|
144
|
-
|
|
145
|
-
export class V1_ContractUserMembership {
|
|
146
|
-
guid!: string;
|
|
147
|
-
user!: V1_User;
|
|
148
|
-
status!: V1_UserApprovalStatus;
|
|
149
|
-
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2026-present, Goldman Sachs
|
|
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.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
export class V1_RawWorkflowTask {
|
|
18
|
+
completed!: boolean;
|
|
19
|
+
createdDate!: Date;
|
|
20
|
+
parentTaskId!: string;
|
|
21
|
+
potentialAssignees: string[] = [];
|
|
22
|
+
processInstanceId!: string;
|
|
23
|
+
reference!: string;
|
|
24
|
+
status!: string;
|
|
25
|
+
taskId!: string;
|
|
26
|
+
type!: string;
|
|
27
|
+
}
|
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
17
|
import {
|
|
18
|
+
AssertionError,
|
|
18
19
|
UnsupportedOperationError,
|
|
19
20
|
guaranteeType,
|
|
20
21
|
isNonNullable,
|
|
@@ -47,8 +48,8 @@ import type { V1_FileGenerationSpecification } from '../../../model/packageableE
|
|
|
47
48
|
import type { V1_GenerationSpecification } from '../../../model/packageableElements/generationSpecification/V1_GenerationSpecification.js';
|
|
48
49
|
import type { V1_Measure } from '../../../model/packageableElements/domain/V1_Measure.js';
|
|
49
50
|
import {
|
|
50
|
-
V1_buildDatabaseJoin,
|
|
51
51
|
V1_buildDatabaseFilter,
|
|
52
|
+
V1_buildDatabaseJoin,
|
|
52
53
|
} from './helpers/V1_DatabaseBuilderHelper.js';
|
|
53
54
|
import type { V1_SectionIndex } from '../../../model/packageableElements/section/V1_SectionIndex.js';
|
|
54
55
|
import { V1_buildAssociationMapping } from './helpers/V1_AssociationMappingHelper.js';
|
|
@@ -174,9 +175,15 @@ export class V1_ElementFourthPassBuilder
|
|
|
174
175
|
const database = this.context.currentSubGraph.getOwnDatabase(
|
|
175
176
|
V1_buildFullPath(element.package, element.name),
|
|
176
177
|
);
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
178
|
+
element.joins.forEach((srcJoin, index) => {
|
|
179
|
+
const join = database.joins[index];
|
|
180
|
+
if (!join) {
|
|
181
|
+
throw new AssertionError(
|
|
182
|
+
`Can't find join '${srcJoin.name}' in metamodel database '${database.path}'`,
|
|
183
|
+
);
|
|
184
|
+
}
|
|
185
|
+
V1_buildDatabaseJoin(srcJoin, join, this.context, database);
|
|
186
|
+
});
|
|
180
187
|
database.filters = element.filters.map((filter) =>
|
|
181
188
|
V1_buildDatabaseFilter(filter, this.context, database),
|
|
182
189
|
);
|
|
@@ -147,6 +147,7 @@ import {
|
|
|
147
147
|
} from './helpers/V1_DataProductBuilder.js';
|
|
148
148
|
import type { V1_IngestDefinition } from '../../../model/packageableElements/ingest/V1_IngestDefinition.js';
|
|
149
149
|
import { IncludeStore } from '../../../../../../../graph/metamodel/pure/packageableElements/store/relational/model/IncludeStore.js';
|
|
150
|
+
import { Join } from '../../../../../../../STO_Relational_Exports.js';
|
|
150
151
|
|
|
151
152
|
export class V1_ElementSecondPassBuilder
|
|
152
153
|
implements V1_PackageableElementVisitor<void>
|
|
@@ -515,6 +516,7 @@ export class V1_ElementSecondPassBuilder
|
|
|
515
516
|
const database = this.context.currentSubGraph.getOwnDatabase(
|
|
516
517
|
V1_buildFullPath(element.package, element.name),
|
|
517
518
|
);
|
|
519
|
+
database.joins = element.joins.map((join) => new Join(join.name));
|
|
518
520
|
database.includes = element.includedStores.map((includedStore) =>
|
|
519
521
|
this.context.resolveDatabase(includedStore.path),
|
|
520
522
|
);
|