-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix(canvas): Display multicast/loadbalance as parallel executed processes #1431
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1431 +/- ##
=======================================
Coverage ? 67.71%
Complexity ? 25
=======================================
Files ? 269
Lines ? 7644
Branches ? 1520
=======================================
Hits ? 5176
Misses ? 2408
Partials ? 60 ☔ View full report in Codecov by Sentry. |
b177c11
to
178ab52
Compare
I am wondering if the quality check makes sense for test classes in this specific case. |
6b97379
to
9eca9e9
Compare
packages/ui/src/models/visualization/visualization-node.test.ts
Outdated
Show resolved
Hide resolved
.../ui/src/models/visualization/flows/nodes/mappers/parallel-processor-base-node-mapper.test.ts
Outdated
Show resolved
Hide resolved
expect(vizNode).toBeDefined(); | ||
expect(vizNode.data).toMatchObject({ | ||
path, | ||
icon: expect.any(String), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good idea 👍
a7e8297
to
2596938
Compare
.../ui/src/models/visualization/flows/nodes/mappers/parallel-processor-base-node-mapper.test.ts
Outdated
Show resolved
Hide resolved
packages/ui/src/models/visualization/flows/nodes/mappers/parallel-processor-base-node-mapper.ts
Outdated
Show resolved
Hide resolved
addNodeInteraction(vizNode: IVisualizationNode, processorName: keyof ProcessorDefinition): void { | ||
const stepsProperties = CamelComponentSchemaService.getProcessorStepsProperties(processorName); | ||
const canHaveChildren = stepsProperties.find((property) => property.type === 'branch') !== undefined; | ||
const canHaveSpecialChildren = Object.keys(stepsProperties).length > 1; | ||
const canReplaceStep = CamelComponentSchemaService.canReplaceStep(processorName); | ||
const canRemoveStep = !CamelComponentSchemaService.DISABLED_REMOVE_STEPS.includes(processorName); | ||
const canBeDisabled = CamelComponentSchemaService.canBeDisabled(processorName); | ||
|
||
vizNode.setNodeInteraction({ | ||
canHavePreviousStep: false, | ||
canHaveNextStep: false, | ||
canRemoveFlow: false, | ||
canHaveChildren, | ||
canHaveSpecialChildren, | ||
canReplaceStep, | ||
canRemoveStep, | ||
canBeDisabled, | ||
}); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This also seems very similar to the abstract-camel-visual-entity counterpart.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can take care of this in another PR, so we can also remove the other duplication from other visual entities as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Created a task for this- #1445
0552f29
to
d3dea74
Compare
d3dea74
to
8419b9a
Compare
packages/ui/src/models/visualization/visualization-node.test.ts
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for handling the feedback 👍 , LGTM
packages/ui/src/models/visualization/visualization-node.test.ts
Outdated
Show resolved
Hide resolved
Quality Gate passedIssues Measures |
Fixes #1347
Fixes #648
Test this change here.