Package com.esri.gpt.control.webharvest.engine

Examples of com.esri.gpt.control.webharvest.engine.Harvester


* @param jobType job type
* @return <code>true</code> if job has been created
*/
private boolean insertJob(HrRecord record, Integer maxRecs, Date fromDate) {
  ApplicationContext appCtx = ApplicationContext.getInstance();
  Harvester harvester = appCtx.getHarvestingEngine();
  return harvester.submit(getRequestContext(), record, maxRecs, fromDate);
}
View Full Code Here


        LOGGER.log(Level.INFO, "Unable to create resource definition.", ex);
      }
    }

    // NEW in 10.0;  notify update
    Harvester harvestEngine = getRequestContext().getApplicationContext().getHarvestingEngine();
    if (_repository.getIsHarvestDue()) {
      harvestEngine.submit(getRequestContext(), _repository, null, _repository.getLastSyncDate());
    }
    harvestEngine.reselect();

  } catch (Exception ex) {
    if (con!=null) {
      con.rollback();
    }
View Full Code Here

    // create message broker
    MessageBroker messageBroker = new MessageBroker();
    messageBroker.setBundleBaseName(MessageBroker.DEFAULT_BUNDLE_BASE_NAME);

    // create web harvester
    Harvester harvester = new Harvester(messageBroker, appCtx.getConfiguration().getHarvesterConfiguration());
    appCtx.setHarvestingEngine(harvester);
   
    // start web harvester
    harvester.init();

    // schedule tasks
    schedule();
  } catch (Throwable t) {
    LogUtil.getLogger().log(Level.SEVERE, "Initialization failed.", t);
View Full Code Here

    getActionResult().setNumberOfRecordsModified(nRowCount);

    if (!isUpdate && nRowCount==1) {
      getEvent().setUuid(sUuid);
      getEvent().setHarvestDate(harvestDate);
      Harvester harvestEngine = getRequestContext().getApplicationContext().getHarvestingEngine();
      harvestEngine.reselect();
    }
   
  } finally {
    closeStatement(stInsert);
    closeStatement(stUpdate);
View Full Code Here

      int nRowCount = stHistoryDelete.executeUpdate();
      getActionResult().setNumberOfRecordsModified(nRowCount);

      // NEW in 10.0;  notify update
      Harvester harvestEngine = getRequestContext().getApplicationContext().getHarvestingEngine();
      harvestEngine.reselect();

    } finally {
      closeStatement(stHistoryDelete);
    }
  }
View Full Code Here

   ApplicationContext appCtx = ApplicationContext.getInstance();

   // create harvester engine
   MessageBroker messageBroker = new MessageBroker();
   messageBroker.setBundleBaseName(MessageBroker.DEFAULT_BUNDLE_BASE_NAME);
   Harvester harvester = new Harvester(messageBroker, appCtx.getConfiguration().getHarvesterConfiguration());
   appCtx.setHarvestingEngine(harvester);
  
   CfgConfigFileProcessor processor = new CfgConfigFileProcessor();
   processor.processConfigFile(new File(url.getPath()),this,true);
  }
View Full Code Here

TOP

Related Classes of com.esri.gpt.control.webharvest.engine.Harvester

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.