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

bd2019us updated STORM-3380:
----------------------------
    Description: 
Hello,
I found that if the Map "data" does not have the key "TYPE", the String 
"compType" may cause potential risk of NullPointerException since it is 
immediately used after initialization and there is no null checker. One 
recommended API is Objects.equals(String,String) which can avoid this exception.


  was:
Hello,
I found that if the Map "data" does not have the key "TYPE", the String 
"compType" may cause potential risk of NullPointerException since they are 
immediately used after initialization and there is no null checker. One 
recommended API is Objects.equals(String,String) which can avoid this exception.



> Change String.equals to Objects.equals(String,String) to avoid possible 
> NullPointerException
> --------------------------------------------------------------------------------------------
>
>                 Key: STORM-3380
>                 URL: https://issues.apache.org/jira/browse/STORM-3380
>             Project: Apache Storm
>          Issue Type: Bug
>            Reporter: bd2019us
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: 1.patch
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Hello,
> I found that if the Map "data" does not have the key "TYPE", the String 
> "compType" may cause potential risk of NullPointerException since it is 
> immediately used after initialization and there is no null checker. One 
> recommended API is Objects.equals(String,String) which can avoid this 
> exception.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to