Github user dsmiley commented on a diff in the pull request:
https://github.com/apache/lucene-solr/pull/501#discussion_r234869970
--- Diff: solr/core/src/java/org/apache/solr/update/AddUpdateCommand.java
---
@@ -194,20 +197,33 @@ public String getHashableId() {
return null; // caller should call getLuceneDocument() instead
}
- String rootId = getHashableId();
-
- boolean isVersion = version != 0;
+ final String rootId = getHashableId();
+ final boolean hasVersion = version != 0;
+ final SolrInputField versionSif = hasVersion?
solrDoc.get(CommonParams.VERSION_FIELD): null;
--- End diff --
What I meant was that *if* the solrDoc has a \_version\_ then we can copy
it to all nested children. We need not examine this.version at all. At least
this is my understanding of reading the code; it'd be good to ensure tests pass.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]