Class WriteableWorkspaceSnapshot

java.lang.Object
com.illumon.iris.db.util.WorkspaceDataSnapshot
com.illumon.iris.utils.WriteableWorkspaceSnapshot

public class WriteableWorkspaceSnapshot extends WorkspaceDataSnapshot
Utility class to merge into DbInternal/WorkspaceDataSnapshot
  • Constructor Details

    • WriteableWorkspaceSnapshot

      public WriteableWorkspaceSnapshot(@NotNull com.fishlib.io.logger.Logger log, @NotNull Database db)
      Parameters:
      log - a Logger
      db - reference to the Database to use
  • Method Details

    • writeSnapshot

      public void writeSnapshot(String snapshotDate, Table snapshot)
      commit current keyframe to persistent storage if possible (able to write and partition doesn't exist yet)
      Parameters:
      snapshotDate - string date used as Date partitioning key for new partition
      snapshot - a Table containing the new workspace snapshot "keyframe" rows.
    • updateSnapshot

      @ScriptApi public boolean updateSnapshot()
      compute a new keyframe and write it to persistent storage if possible,
      Returns:
      true on success, false on failure, usually due to policy checks.