You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tubemq.apache.org by "viviel (Jira)" <ji...@apache.org> on 2020/06/08 14:52:00 UTC

[jira] [Updated] (TUBEMQ-228) Fixed: Exception used

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

viviel updated TUBEMQ-228:
--------------------------
    Description: 
Fix exception use
{code:java}
Exception -> IllegalArgumentException
{code}
Example
{code:java}
if (TStringUtils.isBlank(strTimeVal)) {
    throw new Exception(strValName + " value is null or blank of "
            + ruleType + " limit rule!");
}

change to 

if (TStringUtils.isBlank(strTimeVal)) {
    throw new IllegalArgumentException(strValName + " value is null or blank of "
            + ruleType + " limit rule!");
}{code}

  was:
Fixe exception used
{code:java}
Exception -> IllegalArgumentException
{code}
Example
{code:java}
if (TStringUtils.isBlank(strTimeVal)) {
    throw new Exception(strValName + " value is null or blank of "
            + ruleType + " limit rule!");
}

change to 

if (TStringUtils.isBlank(strTimeVal)) {
    throw new IllegalArgumentException(strValName + " value is null or blank of "
            + ruleType + " limit rule!");
}{code}


> Fixed: Exception used
> ---------------------
>
>                 Key: TUBEMQ-228
>                 URL: https://issues.apache.org/jira/browse/TUBEMQ-228
>             Project: Apache TubeMQ
>          Issue Type: Improvement
>            Reporter: viviel
>            Assignee: viviel
>            Priority: Low
>             Fix For: 0.5.0
>
>
> Fix exception use
> {code:java}
> Exception -> IllegalArgumentException
> {code}
> Example
> {code:java}
> if (TStringUtils.isBlank(strTimeVal)) {
>     throw new Exception(strValName + " value is null or blank of "
>             + ruleType + " limit rule!");
> }
> change to 
> if (TStringUtils.isBlank(strTimeVal)) {
>     throw new IllegalArgumentException(strValName + " value is null or blank of "
>             + ruleType + " limit rule!");
> }{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)