Interface BatchingFlushProcess

  • All Superinterfaces:
    org.datanucleus.flush.FlushProcess

    public interface BatchingFlushProcess
    extends org.datanucleus.flush.FlushProcess
    A marker interface for defining a custom flush process for RDMS that goes beyond what can be controlled by standard flush mechanisms. Interface enables custom ways of specifying when insert-, update- and delete-requests can be batched. It all enables more batching (and thereby better performance) tailored to a given implementation.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      boolean batchInDeleteRequest​(boolean optimisticChecks, org.datanucleus.ExecutionContext ec)
      Decide whether batching should be enabled for this kind of DeleteRequest
      boolean batchInInsertRequest​(boolean hasIdentityColumn, StatementMappingIndex[] externalFKStmtMappings, org.datanucleus.metadata.AbstractClassMetaData cmd, org.datanucleus.ExecutionContext ec)
      Decide whether batching should be enabled for this kind of InsertRequest
      boolean batchInUpdateRequest​(boolean optimisticChecks, org.datanucleus.ExecutionContext ec)
      Decide whether batching should be enabled for this kind of UpdateRequest
      • Methods inherited from interface org.datanucleus.flush.FlushProcess

        execute
    • Method Detail

      • batchInInsertRequest

        boolean batchInInsertRequest​(boolean hasIdentityColumn,
                                     StatementMappingIndex[] externalFKStmtMappings,
                                     org.datanucleus.metadata.AbstractClassMetaData cmd,
                                     org.datanucleus.ExecutionContext ec)
        Decide whether batching should be enabled for this kind of InsertRequest
        Parameters:
        hasIdentityColumn - see InsertRequest for details
        externalFKStmtMappings - see InsertRequest for details
        cmd - Class meta data object for InsertRequest
        ec - execution context
        Returns:
        whether batching should be enabled for this kind of InsertRequest
      • batchInUpdateRequest

        boolean batchInUpdateRequest​(boolean optimisticChecks,
                                     org.datanucleus.ExecutionContext ec)
        Decide whether batching should be enabled for this kind of UpdateRequest
        Parameters:
        optimisticChecks - whether optimistic locking is enabled for object being updated
        ec - execution context
        Returns:
        whether batching should be enabled for this kind of UpdateRequest
      • batchInDeleteRequest

        boolean batchInDeleteRequest​(boolean optimisticChecks,
                                     org.datanucleus.ExecutionContext ec)
        Decide whether batching should be enabled for this kind of DeleteRequest
        Parameters:
        optimisticChecks - whether optimistic locking is enabled for object being deleted
        ec - execution context
        Returns:
        whether batching should be enabled for this kind of DeleteRequest