@finos/legend-application-studio 28.18.145 → 28.18.147

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.
Files changed (46) hide show
  1. package/lib/components/editor/editor-group/dataProduct/DataPoductEditor.d.ts.map +1 -1
  2. package/lib/components/editor/editor-group/dataProduct/DataPoductEditor.js +31 -7
  3. package/lib/components/editor/editor-group/dataProduct/DataPoductEditor.js.map +1 -1
  4. package/lib/components/editor/editor-group/function-activator/FunctionEditor.d.ts.map +1 -1
  5. package/lib/components/editor/editor-group/function-activator/FunctionEditor.js +7 -4
  6. package/lib/components/editor/editor-group/function-activator/FunctionEditor.js.map +1 -1
  7. package/lib/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.d.ts.map +1 -1
  8. package/lib/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.js +21 -16
  9. package/lib/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.js.map +1 -1
  10. package/lib/components/editor/ingest-definition-editor.css +1 -0
  11. package/lib/components/editor/ingest-definition-editor.css.map +1 -0
  12. package/lib/index.css +2 -2
  13. package/lib/index.css.map +1 -1
  14. package/lib/package.json +1 -1
  15. package/lib/stores/editor/GraphEditFormModeState.d.ts.map +1 -1
  16. package/lib/stores/editor/GraphEditFormModeState.js +1 -0
  17. package/lib/stores/editor/GraphEditFormModeState.js.map +1 -1
  18. package/lib/stores/editor/editor-state/element-editor-state/ingest/IngestDefinitionEditorState.d.ts.map +1 -1
  19. package/lib/stores/editor/editor-state/element-editor-state/ingest/IngestDefinitionEditorState.js +7 -33
  20. package/lib/stores/editor/editor-state/element-editor-state/ingest/IngestDefinitionEditorState.js.map +1 -1
  21. package/lib/stores/graph-modifier/DSL_DataProduct_GraphModifierHelper.d.ts +1 -0
  22. package/lib/stores/graph-modifier/DSL_DataProduct_GraphModifierHelper.d.ts.map +1 -1
  23. package/lib/stores/graph-modifier/DSL_DataProduct_GraphModifierHelper.js +3 -0
  24. package/lib/stores/graph-modifier/DSL_DataProduct_GraphModifierHelper.js.map +1 -1
  25. package/lib/stores/ingestion/IngestDeploymentServerClient.d.ts +2 -0
  26. package/lib/stores/ingestion/IngestDeploymentServerClient.d.ts.map +1 -1
  27. package/lib/stores/ingestion/IngestDeploymentServerClient.js +7 -3
  28. package/lib/stores/ingestion/IngestDeploymentServerClient.js.map +1 -1
  29. package/lib/stores/ingestion/IngestionDeploymentResponse.d.ts +1 -0
  30. package/lib/stores/ingestion/IngestionDeploymentResponse.d.ts.map +1 -1
  31. package/lib/stores/ingestion/IngestionDeploymentResponse.js +1 -0
  32. package/lib/stores/ingestion/IngestionDeploymentResponse.js.map +1 -1
  33. package/lib/stores/ingestion/IngestionManager.d.ts +1 -0
  34. package/lib/stores/ingestion/IngestionManager.d.ts.map +1 -1
  35. package/lib/stores/ingestion/IngestionManager.js +11 -1
  36. package/lib/stores/ingestion/IngestionManager.js.map +1 -1
  37. package/package.json +3 -3
  38. package/src/components/editor/editor-group/dataProduct/DataPoductEditor.tsx +111 -29
  39. package/src/components/editor/editor-group/function-activator/FunctionEditor.tsx +12 -5
  40. package/src/components/editor/editor-group/ingest-editor/IngestDefinitionEditor.tsx +82 -53
  41. package/src/stores/editor/GraphEditFormModeState.ts +1 -0
  42. package/src/stores/editor/editor-state/element-editor-state/ingest/IngestDefinitionEditorState.ts +9 -41
  43. package/src/stores/graph-modifier/DSL_DataProduct_GraphModifierHelper.ts +6 -0
  44. package/src/stores/ingestion/IngestDeploymentServerClient.ts +14 -3
  45. package/src/stores/ingestion/IngestionDeploymentResponse.ts +1 -0
  46. package/src/stores/ingestion/IngestionManager.ts +18 -1
@@ -55,9 +55,11 @@ export class IngestDeploymentServerClient extends AbstractServerClient {
55
55
  private _dataProduct = (): string =>
56
56
  `${this.baseUrl}/${this.DATA_PRODUCT_URL}/api/entitlements/sdlc/deploy/definitions`;
57
57
 
58
- private _ingest = (): string =>
58
+ private _ingestDefinitions = (): string =>
59
59
  `${this.baseUrl}/api/ingest/sdlc/deploy/definitions`;
60
60
 
61
+ private _ingest = (): string => `${this.baseUrl}/api/ingest`;
62
+
61
63
  changeServer(serverConfig: IngestDeploymentServerConfig): void {
62
64
  this.baseUrl = serverConfig.ingestServerUrl;
63
65
  this.environmentClassification = serverConfig.environmentClassification;
@@ -68,7 +70,7 @@ export class IngestDeploymentServerClient extends AbstractServerClient {
68
70
  token: string | undefined,
69
71
  ): Promise<PlainObject<IngestDefinitionValidationResponse>> {
70
72
  return this.post(
71
- `${this._ingest()}/validate`,
73
+ `${this._ingestDefinitions()}/validate`,
72
74
  validateGrammar,
73
75
  undefined,
74
76
  this._tokenWithTextPlain(token),
@@ -80,13 +82,22 @@ export class IngestDeploymentServerClient extends AbstractServerClient {
80
82
  token: string | undefined,
81
83
  ): Promise<IngestDefinitionDeploymentResponse> {
82
84
  return this.post(
83
- `${this._ingest()}`,
85
+ `${this._ingestDefinitions()}`,
84
86
  deployGrammar,
85
87
  undefined,
86
88
  this._tokenWithTextPlain(token),
87
89
  );
88
90
  }
89
91
 
92
+ write_location(urn: string, token: string | undefined): Promise<PlainObject> {
93
+ return this.post(
94
+ `${this._ingest()}/${encodeURIComponent(urn)}/write-location`,
95
+ undefined,
96
+ undefined,
97
+ this._token(token),
98
+ );
99
+ }
100
+
90
101
  deployDataProduct(
91
102
  fullGrammar: string,
92
103
  token: string | undefined,
@@ -51,6 +51,7 @@ export const createIngestDefinitionValidationResponse = (
51
51
 
52
52
  export class IngestDefinitionDeploymentResponse {
53
53
  ingestDefinitionUrn!: string;
54
+ write_location: PlainObject | undefined;
54
55
 
55
56
  static readonly serialization = new SerializationFactory(
56
57
  createModelSchema(IngestDefinitionDeploymentResponse, {
@@ -115,7 +115,13 @@ export class IngestionManager {
115
115
  undefined,
116
116
  token,
117
117
  );
118
- fullResponse.deploymentResponse = deployResponse;
118
+ try {
119
+ messageCallBack(`Deployment Success. Fetching write location...`);
120
+ await this._fetchDeployLocations(deployResponse, token);
121
+ } catch (error) {
122
+ assertErrorThrown(error);
123
+ }
124
+
119
125
  return fullResponse;
120
126
  }
121
127
 
@@ -181,6 +187,17 @@ export class IngestionManager {
181
187
  return IngestDefinitionDeploymentResponse.serialization.fromJson(response);
182
188
  }
183
189
 
190
+ private async _fetchDeployLocations(
191
+ depploymentResponse: IngestDefinitionDeploymentResponse,
192
+ token: string | undefined,
193
+ ): Promise<void> {
194
+ const response = (await this.ingestDeploymentServerClient.write_location(
195
+ depploymentResponse.ingestDefinitionUrn,
196
+ token,
197
+ )) as unknown as PlainObject;
198
+ depploymentResponse.write_location = response;
199
+ }
200
+
184
201
  private async identifyIngestDeploymentServer(
185
202
  appDirNode: AppDirNode,
186
203
  token: string | undefined,