[ 
https://issues.apache.org/jira/browse/STORM-1084?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Boyang Jerry Peng updated STORM-1084:
-------------------------------------
    Description: 
So currently we specify validators:

 public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
"storm.messaging.netty.min_wait_ms";
 public static final Object STORM_MESSAGING_NETTY_MIN_SLEEP_MS_SCHEMA = 
ConfigValidation.IntegerValidator;

A better way to do this is using annotations.  Something like:

@IntegerValidator
 public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
"storm.messaging.netty.min_wait_ms";

Do this has many advantages. For one you can stack multiple annotations:

@IntegerValidator
@AnotherValidator
 public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
"storm.messaging.netty.min_wait_ms";


  was:
So currently we specify validators:

 public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
"storm.messaging.netty.min_wait_ms";
 public static final Object STORM_MESSAGING_NETTY_MIN_SLEEP_MS_SCHEMA = 
ConfigValidation.IntegerValidator;

A better way to do this is using annotations.  Something like:

@IntegerValidator
 public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
"storm.messaging.netty.min_wait_ms";




> Improve Storm config validation process to use java annotations instead of 
> *_SCHEMA format
> ------------------------------------------------------------------------------------------
>
>                 Key: STORM-1084
>                 URL: https://issues.apache.org/jira/browse/STORM-1084
>             Project: Apache Storm
>          Issue Type: Improvement
>            Reporter: Boyang Jerry Peng
>            Assignee: Boyang Jerry Peng
>
> So currently we specify validators:
>  public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
> "storm.messaging.netty.min_wait_ms";
>  public static final Object STORM_MESSAGING_NETTY_MIN_SLEEP_MS_SCHEMA = 
> ConfigValidation.IntegerValidator;
> A better way to do this is using annotations.  Something like:
> @IntegerValidator
>  public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
> "storm.messaging.netty.min_wait_ms";
> Do this has many advantages. For one you can stack multiple annotations:
> @IntegerValidator
> @AnotherValidator
>  public static final String STORM_MESSAGING_NETTY_MIN_SLEEP_MS = 
> "storm.messaging.netty.min_wait_ms";



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to