This is an automated email from the ASF dual-hosted git repository.

anshum pushed a commit to branch branch_9_0
in repository https://gitbox.apache.org/repos/asf/solr.git


The following commit(s) were added to refs/heads/branch_9_0 by this push:
     new 4918187  SOLR-16101: Add empty constructor for SolrInputDocument 
(#746) (#751) (#752)
4918187 is described below

commit 4918187cc0aa3299ba6a8addefb388b010ce2603
Author: Anshum Gupta <[email protected]>
AuthorDate: Fri Mar 18 12:13:25 2022 -0700

    SOLR-16101: Add empty constructor for SolrInputDocument (#746) (#751) (#752)
---
 solr/CHANGES.txt                                                  | 2 ++
 solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java | 5 +++++
 2 files changed, 7 insertions(+)

diff --git a/solr/CHANGES.txt b/solr/CHANGES.txt
index 1745ffb..00a46d7 100644
--- a/solr/CHANGES.txt
+++ b/solr/CHANGES.txt
@@ -578,6 +578,8 @@ and each individual module's jar will be included in its 
directory's lib/ folder
 
 * SOLR-16061: CloudSolrClient refactoring: Removed ZK specific methods 
(Haythem Khiri, David Smiley, janhoy)
 
+* SOLR-16101: Add empty constructor for SolrInputDocument (Anshum Gupta)
+
 Bug Fixes
 ---------------------
 * SOLR-15849: Fix the connection reset problem caused by the incorrect use of 
4LW with \n when monitoring zooKeeper status (Fa Ming).
diff --git a/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java 
b/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java
index f9ffaaa..db99bc0 100644
--- a/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java
+++ b/solr/solrj/src/java/org/apache/solr/common/SolrInputDocument.java
@@ -38,6 +38,11 @@ public class SolrInputDocument extends 
SolrDocumentBase<SolrInputField, SolrInpu
   private final Map<String, SolrInputField> _fields;
   private List<SolrInputDocument> _childDocuments;
 
+  // Required by reflection based libraries for (de)serialization
+  public SolrInputDocument() {
+    _fields = new LinkedHashMap<>();
+  }
+
   public SolrInputDocument(String... fields) {
     _fields = new LinkedHashMap<>();
     assert fields.length % 2 == 0;

Reply via email to