[ https://issues.apache.org/jira/browse/SOLR-13496?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16855038#comment-16855038 ]
Christine Poerschke commented on SOLR-13496: -------------------------------------------- {quote}The patch doesn't appear to include any new or modified tests. Please justify why no new tests are needed for this patch. Also please list what manual steps were performed to verify this patch. {quote} Just attached a patch which includes (a tidied up version of) my (new) {{ChaoticDistributedGroupingTest}} used to exercise the code path in question. The test configures a custom select handler which configures a {{TargettedChaosComponent}} search component which in its [modifyRequest|https://github.com/apache/lucene-solr/blob/releases/lucene-solr/8.1.1/solr/core/src/java/org/apache/solr/handler/component/SearchComponent.java#L73-L75] method potentially modifies the {{ids}} parameter of a shard request. That removal of an id value is to simulate a Solr cloud scenario where a document is deleted just before a 'get fields' request for it happens. Having said all that (unless anyone strongly thinks otherwise) I'm not planning on including the new {{ChaoticDistributedGroupingTest}} in the commit for this ticket here since just under 200 lines of non-trivial test code for essentially a one-line change to add a null-check seems excessive? > NullPointerException in JSONWriter.writeSolrDocument > ---------------------------------------------------- > > Key: SOLR-13496 > URL: https://issues.apache.org/jira/browse/SOLR-13496 > Project: Solr > Issue Type: Bug > Reporter: Christine Poerschke > Assignee: Christine Poerschke > Priority: Minor > Attachments: SOLR-13496.patch, SOLR-13496.patch > > > For non-grouped searches > [QueryComponent.regularFinishStage|https://github.com/apache/lucene-solr/blob/releases/lucene-solr/8.1.1/solr/core/src/java/org/apache/solr/handler/component/QueryComponent.java#L647-L655] > already considers the possibility of null {{SolrDocument}} values due to an > index change. > For grouped searches > [GroupedEndResultTransformer.transform|https://github.com/apache/lucene-solr/blob/releases/lucene-solr/8.1.1/solr/core/src/java/org/apache/solr/search/grouping/endresulttransformer/GroupedEndResultTransformer.java#L94-L114] > potentially adds a null element to a {{SolrDocumentList}}. > The > [TextResponseWriter.writeSolrDocumentList|https://github.com/apache/lucene-solr/blob/releases/lucene-solr/8.1.1/solr/core/src/java/org/apache/solr/response/TextResponseWriter.java#L170] > method passes any null {{SolrDocument}} through to the > [JSONWriter.writeSolrDocument|https://github.com/apache/lucene-solr/blob/releases/lucene-solr/8.1.1/solr/core/src/java/org/apache/solr/response/JSONWriter.java#L87] > method leading to a {{NullPointerException}} at line 87. -- This message was sent by Atlassian JIRA (v7.6.3#76005) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org