[jboss-jira] [JBoss JIRA] (WFCORE-5070) List to Set ParameterCorrectors and ParameterValidators

Brian Stansberry (Jira) issues at jboss.org
Tue Jul 28 15:17:00 EDT 2020


     [ https://issues.redhat.com/browse/WFCORE-5070?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Brian Stansberry updated WFCORE-5070:
-------------------------------------
    Description: 
The management API doesn't have a "SET" attribute/parameter type but use cases like JBEAP-19958 shows there's some need for a bit of set-like behavior.

Idea here is the controller module could expose some static factories for ParameterCorrectors and ParameterValidators to impose set semantics on a ModelType.LIST attribute.

A validator would be used to reject lists with duplicates.

A corrector would be used to remove dups from a list without failing.

For a corrector construction could perhaps be parameterized by allowing passing in the name of the attribute and a log level. Those would be used to log when the corrector removes duplicates. The corrector would definitely need to know the attribute name to log an appropriate message. The appropriate level for a message may vary based on the attribute.

  was:
The management API doesn't have a "SET" attribute/parameter type but use cases like JBEAP-19958 shows there's some need.

Idea here is the controller module could expose some static factories for ParameterCorrectors and ParameterValidators to impose set semantics on a ModelType.LIST attribute.

A validator would be used to reject lists with duplicates.

A corrector would be used to remove dups from a list without failing.

For a corrector construction could perhaps be parameterized by allowing passing in the name of the attribute and a log level. Those would be used to log when the corrector removes duplicates. The corrector would definitely need to know the attribute name to log an appropriate message. The appropriate level for a message may vary based on the attribute.



> List to Set ParameterCorrectors and ParameterValidators
> -------------------------------------------------------
>
>                 Key: WFCORE-5070
>                 URL: https://issues.redhat.com/browse/WFCORE-5070
>             Project: WildFly Core
>          Issue Type: Enhancement
>          Components: Management
>            Reporter: Brian Stansberry
>            Assignee: Jeff Mesnil
>            Priority: Minor
>
> The management API doesn't have a "SET" attribute/parameter type but use cases like JBEAP-19958 shows there's some need for a bit of set-like behavior.
> Idea here is the controller module could expose some static factories for ParameterCorrectors and ParameterValidators to impose set semantics on a ModelType.LIST attribute.
> A validator would be used to reject lists with duplicates.
> A corrector would be used to remove dups from a list without failing.
> For a corrector construction could perhaps be parameterized by allowing passing in the name of the attribute and a log level. Those would be used to log when the corrector removes duplicates. The corrector would definitely need to know the attribute name to log an appropriate message. The appropriate level for a message may vary based on the attribute.



--
This message was sent by Atlassian Jira
(v7.13.8#713008)


More information about the jboss-jira mailing list