Skip to content

SED-4770 handle more keyword types#659

Draft
cmisev wants to merge 6 commits into
SED-4672-fragments-newly-added-via-fragment-manager-are-not-registered-in-automation-package-yamlfrom
SED-4770-handle-more-keyword-types
Draft

SED-4770 handle more keyword types#659
cmisev wants to merge 6 commits into
SED-4672-fragments-newly-added-via-fragment-manager-are-not-registered-in-automation-package-yamlfrom
SED-4770-handle-more-keyword-types

Conversation

@cmisev

@cmisev cmisev commented Jun 19, 2026

Copy link
Copy Markdown

No description provided.

@cmisev

cmisev commented Jun 19, 2026

Copy link
Copy Markdown
Author

Will add some unit tests for jmeter and node keywords

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the automation package collections and fragment management to use a generic, mapper-based architecture, replacing specific collection classes with a single generic AutomationPackageCollection that dynamically scans and utilizes business-object-to-YAML mappers. The review feedback focuses on improving robustness and type safety, recommending defensive null checks in AutomationPackageYamlFragmentManager and CompositeFunctionToYamlMapper to prevent potential NullPointerExceptions, avoiding unsafe casting in AbstractAutomationPackageFragmentYaml, and correcting a typo in a base mapper method name.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment on lines +44 to +46
YamlPlan plan = planReader.planToYamlPlan(compositeFunction.getPlan());
plan.setName(null);
yamlComposite.setPlan(plan);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

If compositeFunction.getPlan() is null, planReader.planToYamlPlan(null) might return null. Calling plan.setName(null) on a null plan will result in a NullPointerException. Adding a defensive null check for plan prevents this potential crash.

Suggested change
YamlPlan plan = planReader.planToYamlPlan(compositeFunction.getPlan());
plan.setName(null);
yamlComposite.setPlan(plan);
YamlPlan plan = planReader.planToYamlPlan(compositeFunction.getPlan());
if (plan != null) {
plan.setName(null);
}
yamlComposite.setPlan(plan);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant