solr配置增量更新和定時更新資料庫索引
阿新 • • 發佈:2019-02-09
#################################################
# #
# dataimport scheduler properties #
# #
#################################################
# to sync or not to sync
# 1 - active; anything else - inactive
syncEnabled=1
# which cores to schedule
# in a multi-core environment you can decide which cores you want syncronized
# leave empty or comment it out if using single-core deployment
syncCores=forumTopic //更新的solr的core名稱
# solr server name or IP address
# [defaults to localhost if empty]
server=localhost //伺服器端地址
# solr server port
# [defaults to 80 if empty]
port=8080 //埠號
# application name/context
# [defaults to current ServletContextListener's context (app) name]
webapp=solr
# URL params [mandatory]
# remainder of URL
#增量,注意entity=forumTopic 即自己core的名稱
params=/dataimport?command=delta-import&clean=false&commit=true&optimize=false&wt=json&indent=true&entity=forumTopic&verbose=false&debug=false
# schedule interval
# number of minutes between two runs
# [defaults to 30 if empty] 增量更新的時間間隔
interval=1
# 重做索引的時間間隔,單位分鐘,預設7200,即1天;
# 為空,為0,或者註釋掉:表示永不重做索引
reBuildIndexInterval=1
# 重做索引的引數
reBuildIndexParams=/dataimport?command=full-import&clean=true&commit=true&optimize=true&wt=json&indent=true&entity=forumTopic&verbose=false&debug=false
# 重做索引時間間隔的計時開始時間,第一次真正執行的時間=reBuildIndexBeginTime+reBuildIndexInterval*60*1000;
# 兩種格式:2012-04-11 03:10:00 或者 03:10:00,後一種會自動補全日期部分為服務啟動時的日期
reBuildIndexBeginTime=09:30:44