dsmiley commented on code in PR #3185:
URL: https://github.com/apache/solr/pull/3185#discussion_r1957047711


##########
solr/core/src/java/org/apache/solr/handler/admin/api/ReplicationAPIBase.java:
##########
@@ -377,7 +380,7 @@ public void write(OutputStream out) throws IOException {
       try {
         initWrite();
 
-        Directory dir = solrCore.withSearcher(searcher -> 
searcher.getIndexReader().directory());
+        Directory dir = getDirectory();

Review Comment:
   I like this change (as we discussed in person)



##########
solr/core/src/java/org/apache/solr/core/DirectoryFactory.java:
##########
@@ -55,10 +55,16 @@ public abstract class DirectoryFactory implements 
NamedListInitializedPlugin, Cl
   // Absolute.
   protected Path dataHomePath;
 
-  // hint about what the directory contains - default is index directory
+  /** Hint about what the directory contains or what the directory will be 
used for. */
   public enum DirContext {
+    /** Default is index directory. */
     DEFAULT,
-    META_DATA
+    /** Directory containing metadata. */
+    META_DATA,
+    /** Directory used to copy raw files during replication. */
+    REPLICATE,
+    /** Directory used to copy raw files during backup. */
+    BACKUP,

Review Comment:
   I wonder if the EncryptionDirectory could somehow ensure that the checksum 
is of the underlying raw data and not the cleartext?  Or maybe quite simply we 
just need a flag on the DirectoryFactory that advises not to do checksum 
verification.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to