Interface TransactionalSegmentPublisher


  • public interface TransactionalSegmentPublisher
    • Method Detail

      • publishAnnotatedSegments

        SegmentPublishResult publishAnnotatedSegments​(@Nullable
                                                      Set<org.apache.druid.timeline.DataSegment> segmentsToBeOverwritten,
                                                      Set<org.apache.druid.timeline.DataSegment> segmentsToPublish,
                                                      @Nullable
                                                      Object commitMetadata)
                                               throws IOException
        Publish segments, along with some commit metadata, in a single transaction.
        Returns:
        publish result that indicates if segments were published or not. If it is unclear if the segments were published or not, this method must throw an exception. The behavior is similar to IndexerSQLMetadataStorageCoordinator's announceHistoricalSegments.
        Throws:
        IOException - if there was an I/O error when publishing
        RuntimeException - if we cannot tell if the segments were published or not, for some other reason
      • supportsEmptyPublish

        default boolean supportsEmptyPublish()
        Returns:
        true if this publisher has action to take when publishing with an empty segment set. The publisher used by the seekable stream tasks is an example where this is true.