Package com.smeup.kokos.sdk.dao
Class BatchTrackingDAO
java.lang.Object
com.smeup.kokos.sdk.dao.BaseMongoDAO
com.smeup.kokos.sdk.dao.BatchTrackingDAO
- All Implemented Interfaces:
TrackingDAO
Implementation of TrackingDAO for tracking batch job executions in MongoDB.
-
Field Summary
Fields inherited from class com.smeup.kokos.sdk.dao.BaseMongoDAO
TTL_SECONDS -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanprobe(ExecutionContext context) Checks whether the DAO is operational and ready to use.voidtrackFun(String meId, ExecutionContext context, Fun fun, FunStatus status) voidTracks the execution status of a Fun within a batch job context by logging the execution details to a MongoDB collection.voidtrackProgress(ExecutionContext context, int progress) Tracks the progress of a batch job by updating the progress percentage in MongoDB.Methods inherited from class com.smeup.kokos.sdk.dao.BaseMongoDAO
createTTLIndex, getDbInstance, probe
-
Constructor Details
-
BatchTrackingDAO
public BatchTrackingDAO()
-
-
Method Details
-
trackFun
-
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:
trackFunin interfaceTrackingDAO- Parameters:
meId-context-fun-status-exception-
-
trackProgress
Tracks the progress of a batch job by updating the progress percentage in MongoDB.- Specified by:
trackProgressin interfaceTrackingDAO- Parameters:
context- The execution context of the batch job.progress- The progress percentage (0-100).
-
probe
Description copied from interface:TrackingDAOChecks whether the DAO is operational and ready to use.- Specified by:
probein interfaceTrackingDAO- Returns:
- true if the DAO is usable, false otherwise
-