Class FailsafeElement<OriginalT,​CurrentT>


  • @DefaultCoder(FailsafeElementCoder.class)
    public class FailsafeElement<OriginalT,​CurrentT>
    extends java.lang.Object
    The FailsafeElement class holds the current value and original value of a record within a pipeline. This class allows pipelines to not lose valuable information about an incoming record throughout the processing of that record. The use of this class allows for more robust dead-letter strategies as the original record information is not lost throughout the pipeline and can be output to a dead-letter in the event of a failure during one of the pipelines transforms.
    • Method Detail

      • of

        public static <OriginalT,​CurrentT> FailsafeElement<OriginalT,​CurrentT> of​(OriginalT originalPayload,
                                                                                              CurrentT currentPayload)
      • getOriginalPayload

        public OriginalT getOriginalPayload()
      • getPayload

        public CurrentT getPayload()
      • getErrorMessage

        public @Nullable java.lang.String getErrorMessage()
      • getStacktrace

        public @Nullable java.lang.String getStacktrace()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object