[ https://issues.apache.org/jira/browse/SOLR-16866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17784757#comment-17784757 ]
Andreas Hubold edited comment on SOLR-16866 at 11/10/23 10:14 AM: ------------------------------------------------------------------ This bug did not occur with Solr 8.11.2. It's a regression that was introduced with [https://github.com/apache/solr/commit/3c3fb1df82c5144c0d6b36b7c0fd3bc0343cf15b] for SOLR-16074 org.apache.solr.core.StandardDirectoryFactory#removeDirectory was changed to use org.apache.commons.io.file.PathUtils#deleteDirectory(java.nio.file.Path) instead of org.apache.commons.io.FileUtils#deleteDirectory. The previously used method from commons-io returns without an error, if the directory to delete does not exist. We should add a check in StandardDirectoryFactory#removeDirectory and not call PathUtils#deleteDirectory for non-existing directories. was (Author: ahubold): This bug did not occur with Solr 8.11.2. It's a regression that was introduced with SOLR-16074 where org.apache.solr.core.StandardDirectoryFactory#removeDirectory was changed to use org.apache.commons.io.file.PathUtils#deleteDirectory(java.nio.file.Path) instead of org.apache.commons.io.FileUtils#deleteDirectory. The previously used method from commons-io returns without an error, if the directory to delete does not exist. We should add a check in StandardDirectoryFactory#removeDirectory and not call PathUtils#deleteDirectory for non-existing directories. > CachingDirectoryFactory Throwing Error When Closing > --------------------------------------------------- > > Key: SOLR-16866 > URL: https://issues.apache.org/jira/browse/SOLR-16866 > Project: Solr > Issue Type: Bug > Affects Versions: 9.2.1 > Reporter: Stefan Pieper > Priority: Major > Labels: core > Attachments: solr.blueprint_gnylctsgemcz_users.log > > > Observed occasional ERROR log entries when {{CachingDirectryFactory#close()}} > is called. The respective snippet from the log is this: > {noformat} > 2023-07-06 08:43:37.618 DEBUG (qtp212011969-1801) [ > blueprint_gnylctsgemcz_users] o.a.s.c.CachingDirectoryFactory Removing > directory after core close: /var/solr/data/blueprint_gnylctsgemcz_users/data > 2023-07-06 08:43:37.620 DEBUG (qtp212011969-1801) [ > blueprint_gnylctsgemcz_users] o.a.s.c.CachingDirectoryFactory Removing > directory after core close: > /var/solr/data/blueprint_gnylctsgemcz_users/data/index > 2023-07-06 08:43:37.620 ERROR (qtp212011969-1801) [ > blueprint_gnylctsgemcz_users] o.a.s.c.CachingDirectoryFactory Error removing > directory => java.nio.file.NoSuchFileException: > /var/solr/data/blueprint_gnylctsgemcz_users/data/index > java.nio.file.NoSuchFileException: > /var/solr/data/blueprint_gnylctsgemcz_users/data/index > {noformat} > It seems like the order of directory removal is causing this (first parent > dir _data_, then sub-dir _data/index_). Entries should be re-arranged or just > the parent dir be handled. > Full log with entries dealing with the respective core is attached. -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org