示例#1
0
 @Override
 public void crawlComplete(String type, boolean commitNeeded) {
   if (commitNeeded) {
     idxMgr.getIndex(type).commit();
   }
   synchronized (runningCrawlers) {
     runningCrawlers.remove(type);
   }
   logger.info("type " + type + " removed from runningCrawlers");
 }
示例#2
0
 public void clearIndex(String type) {
   idxMgr.getIndex(type).deleteByQuery("type:" + type);
 }
示例#3
0
 @Override
 public List<Hit> findByType(String type, String query) {
   return idxMgr.getIndex(type).doQuery(query);
 }