修改现有的 Solr 7.6.0 / Lucene 索引(将另一个字段 'URL' 添加到已经索引的文件(.pdf、.docx 等))

Modify existing Solr 7.6.0 / Lucene index (add another field 'URL' to an already indexed file (.pdf, .docx etc.))

我有一个 Solr 7.6.0 Lucene 索引(很多 .pdf、.docx 和 .xlsx 文件)

索引是在命令 window 中使用 post 命令创建的,指向文件所在的目录共享(映射的文件路径)。

我在数据库中的文档还有一个 Web URL,而 Lucene 目前对此一无所知。我想 'enrich' 这个 URL 数据的现有索引。

我可以提取当前索引文件的id,然后使用Solr web 界面修改现有索引,注入URL吗?

我正在查看以下教程以寻求建议: https://www.tutorialspoint.com/apache_solr/apache_solr_indexing_data.htm

该教程显示了一个添加文档但不修改文档的示例。

谢谢@MatsLindh 我设法让它工作:

我使用 Solr GUI 运行 JSON add-field 更新:

{
    "add-field" : {
    "name":"URL",
    "type":"string",
    "stored":true
    "indexed":true
    }
}

我然后inserted/set 属性:

{"id":"S:\Docs\forIndexing\indexThisFile_001.pdf",
 "URL":{"set":"https//localhost/urlToFiles/indexThisFile_001.pdf:"}
}