Class RetryableRecordProcessor<I,​O>

  • All Implemented Interfaces:
    RecordProcessor<I,​O>

    public class RetryableRecordProcessor<I,​O>
    extends java.lang.Object
    implements RecordProcessor<I,​O>
    Decorator that makes a RecordProcessor retryable whenever an exception is thrown while processing a record. This decorator is useful in case of a transient error where a retry might succeed.
    Author:
    Mahmoud Ben Hassine ([email protected])
    • Method Detail

      • processRecord

        public Record<O> processRecord​(Record<I> record)
                                throws java.lang.Exception
        Description copied from interface: RecordProcessor
        Process a record.
        Specified by:
        processRecord in interface RecordProcessor<I,​O>
        Parameters:
        record - to process.
        Returns:
        the processed record, may be of a different type than the input record, or null to skip next processors
        Throws:
        java.lang.Exception - if an error occurs during record processing