Class SyncService

java.lang.Object
org.imixs.archive.service.SyncService

public class SyncService extends Object
The SyncService pulls a Snapshot into an Apache Cassandra archive. The service uses an asynchronous mechanism based on the Imixs EventLog.

The service connects to an Imixs-Workflow instance by the Rest Client to read new snapshot data.

The service is triggered by the SyncScheduler implementing a ManagedScheduledExecutorService.

Version:
2.0
Author:
ralph.soika@imixs.com
  • Field Details

  • Constructor Details

    • SyncService

      public SyncService()
  • Method Details

    • processEventLog

      public void processEventLog(org.imixs.melman.EventLogClient eventLogClient, org.imixs.melman.DocumentClient documentClient) throws org.imixs.melman.RestAPIException
      This method is called by the ManagedScheduledExecutorService. The method lookups the event log entries and pushes new snapshots into the archive service.

      Each eventLogEntry is locked to guaranty exclusive processing.

      Throws:
      org.imixs.melman.RestAPIException
    • releaseDeadLocks

      public void releaseDeadLocks(org.imixs.melman.EventLogClient eventLogClient) throws org.imixs.melman.RestAPIException
      Asynchronous method to release dead locks
      Parameters:
      eventLogClient -
      deadLockInterval -
      topic -
      Throws:
      org.imixs.melman.RestAPIException
    • pullSnapshot

      public org.imixs.workflow.ItemCollection pullSnapshot(org.imixs.workflow.ItemCollection eventLogEntry, org.imixs.melman.DocumentClient documentClient, org.imixs.melman.EventLogClient eventLogClient) throws ArchiveException
      This method lookups the event log entries and pushes new snapshots into the archive service.

      The method returns a AsyncResult to indicate the completion of the push. A client can use this information for further control.

      The method returns the snapshot ItemCollection

      Throws:
      ArchiveException
      org.imixs.melman.RestAPIException