Easier usage of process parameters

Description

Consuming process parameters from code usually takes a code block like the following, taken from OrderBatchProcess:

Using this pattern is time consuming, bulky and prone to errors during development time (e.g.: typos).

The class SvrProcess2 attempts to takes care of some of these issues, but it enforces coding conventions and uses reflection on all class attributes/fields. This class has 0 usages at the core.

This ticket is created in order to explore alternatives to ease the declaration and consumption of process parameters.

Environment

N/A

Activity

Show:

Hiep Lq March 31, 2025 at 3:45 AM

SvrProcess.getFieldsWithParameters use clazz.getDeclaredFields() to query field
so inherit field isn’t count
do you think improve to query inherit field is worthy?

Saulo Gil March 14, 2022 at 2:20 AM

Feature documented at

Saulo Gil November 3, 2021 at 1:24 PM
Edited

Created pull request #963 where the proposal is to flag class fields as parameters by using a new @Parameter annotation. With this, the head of the class mentioned in the ticket definition would look like:

Fixed

Details

Assignee

Reporter

Components

Fix versions

Priority

Created November 3, 2021 at 12:53 PM
Updated March 31, 2025 at 12:33 PM
Resolved March 14, 2022 at 7:06 AM