Hi guys,

Solr Version :: 6.6.1

I am able to import the pdf files into the Solr system using the DIH and
performs the indexing as expected. But i wish to clear the folder
C:/solr-6.6.1/server/solr/core_K2_Depot*/Depot* after the successful finish
of the indexing process.

Please suggest, if there is a way to delete all the files from the folder
via the DIH data-config.xml.


<!--Local filesystem-->
<dataConfig>
  <dataSource type="BinFileDataSource"/>
  <document>
    <entity name="K2FileEntity" processor="FileListEntityProcessor"
dataSource="null"
            recursive = "true"
            *baseDir="C:/solr-6.6.1/server/solr/core_K2_Depot/Depot"*
fileName=".*pdf" rootEntity="false">

        <field column="file" name="id"/>
        <field column="fileLastModified" name="lastmodified" />

          <entity name="pdf" processor="TikaEntityProcessor" onError="skip"
                  url="${K2FileEntity.fileAbsolutePath}" format="text">

                <field column="title" name="title" meta="true"/>
                <field column="dc:format" name="format" meta="true"/>
                <field column="text" name="text"/>

          </entity>
    </entity>
  </document>
</dataConfig>

T
​hanks,

Karan​

Reply via email to