当我运行full_import命令时,它工作正常。更新的日期被写入dataimport.properties文件。当我运行delta-import时,索引失败。回滚所有更改。dataimport.properties文件已创建,并具有solr/conf/location中的777权限。solr DIH中的delta导入问题
请帮我解决这个问题。
@mbonaci
查询,deltaImportQuery和deltaQuery在数据-config.xml中是如下
<entity name="item" query="select group_title,description,DATE_FORMAT(created_date, '%Y-%m-%dT%H:%i:%sZ') as createdDate,group_status, 'GROUP' as itemtype,group_id as id from collaboration_groups where group_status=1"
deltaImportQuery="select group_title,description,DATE_FORMAT(created_date, '%Y-%m-%dT%H:%i:%sZ') as createdDate,group_status,group_id as id,'GROUP' as itemtype from collaboration_groups where group_status=1 and group_id=${dataimporter.delta.id} "
deltaQuery="select group_id from collaboration_groups where group_status=1 and updated_date > '${dataimporter.last_index_time}'" deletedPkQuery="select group_id from collaboration_groups where group_status = 0 and updated_date > '${dataimporter.last_index_time}'">
<field column="id" name="id" />
<field column="itemtype" name="itemtype" />
<field column="group_title" name="fullName" />
<field column="description" name="description"/>
<field column="createdDate" name="createdDate"/>
</entity>
config.xml中的dataImport请求处理程序的配置参数如下
<requestHandler name="/dataimport" class="org.apache.solr.handler.dataimport.DataImportHandler">
<lst name="defaults">
<str name="config">/var/solr/data-config.xml</str>
</lst>
</requestHandler>
请检查我的帖子 – 2011-03-06 06:13:06