Class BatchTrackingDAO

java.lang.Object
com.smeup.kokos.sdk.dao.BaseMongoDAO
com.smeup.kokos.sdk.dao.BatchTrackingDAO
All Implemented Interfaces:
TrackingDAO

public class BatchTrackingDAO extends BaseMongoDAO implements TrackingDAO
Implementation of TrackingDAO for tracking batch job executions in MongoDB.
  • Constructor Details

    • BatchTrackingDAO

      public BatchTrackingDAO()
  • Method Details

    • trackFun

      public void trackFun(String meId, ExecutionContext context, Fun fun, FunStatus status)
    • trackFun

      public void trackFun(String meId, ExecutionContext context, Fun fun, FunStatus status, Throwable exception)
      Tracks the execution status of a Fun within a batch job context by logging the execution details to a MongoDB collection.
      Specified by:
      trackFun in interface TrackingDAO
      Parameters:
      meId -
      context -
      fun -
      status -
      exception -
    • trackProgress

      public void trackProgress(ExecutionContext context, int progress)
      Tracks the progress of a batch job by updating the progress percentage in MongoDB.
      Specified by:
      trackProgress in interface TrackingDAO
      Parameters:
      context - The execution context of the batch job.
      progress - The progress percentage (0-100).
    • probe

      public boolean probe(ExecutionContext context)
      Description copied from interface: TrackingDAO
      Checks whether the DAO is operational and ready to use.
      Specified by:
      probe in interface TrackingDAO
      Returns:
      true if the DAO is usable, false otherwise