[ 
https://issues.apache.org/jira/browse/SOLR-4221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13682281#comment-13682281
 ] 

Noble Paul edited comment on SOLR-4221 at 6/13/13 2:35 PM:
-----------------------------------------------------------

Very interesting. This can go into a java tricks n tips book

{code:java}
  static Integer msgToStr(String val,Integer def ){
        return  val == null ? def : Integer.parseInt(val);
    }
{code}

compiles to

{code:java}
  static Integer msgToStr(String val,Integer def ){
        return Integer.valueOf(val == null ? def : Integer.parseInt(val));
    }
{code}

So NPE , if both 'val' and 'def' are null

Should I open another bug or just commit it as a SOLR-4221

                
      was (Author: noble.paul):
    Very interesting. This can go into a java tricks n tips book

{code:java}
  static Integer msgToStr(String val,Integer def ){
        return  val == null ? def : Integer.parseInt(val);
    }
{code}

compiles to

{code:java}
  static Integer msgToStr(String val,Integer def ){
        return Integer.valueOf(val == null ? def : Integer.parseInt(val));
    }
{code}

So NPE , if 'val' is null

Should I open another bug or just commit it as a SOLR-4221

                  
> Custom sharding
> ---------------
>
>                 Key: SOLR-4221
>                 URL: https://issues.apache.org/jira/browse/SOLR-4221
>             Project: Solr
>          Issue Type: New Feature
>            Reporter: Yonik Seeley
>            Assignee: Noble Paul
>         Attachments: SOLR-4221.patch
>
>
> Features to let users control everything about sharding/routing.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to