Class RootProcessingExceptionHandler

    • Field Detail

      • log

        protected transient org.slf4j.Logger log
    • Constructor Detail

      • RootProcessingExceptionHandler

        public RootProcessingExceptionHandler()
    • Method Detail

      • getUniqueId

        public java.lang.String getUniqueId()
        Description copied from interface: AdaptrisComponent
        Get the unique-id that is associated with this component.
        Specified by:
        getUniqueId in interface AdaptrisComponent
        Returns:
        the unique-id
      • setUniqueId

        public void setUniqueId​(java.lang.String uniqueId)
      • getAlwaysHandleException

        public java.lang.Boolean getAlwaysHandleException()
      • setAlwaysHandleException

        public void setAlwaysHandleException​(java.lang.Boolean b)
        Always handle any exceptions in this error handler.

        This is primarily useful if you have a chain of error handling (i.e you have configured an explicit error handling at one of the workflow / channel levels); by setting this to be true, then you fire the error handling on each of the configured error handlers in turn as they propogate back to the configured adapter error handler. This means that you can have a chain of error handling behaviour like (narrowest first).

        1. workflow-error-handler : send a HTTP 500 response.
        2. adapter-error-handler : write to filesystem /opt/adaptris/bad; always-handle-exception=true

        This will cause the adapter-error-handler to write the original message to /opt/adaptris/bad, as well as sending a 500 response back to the client.

        Note that setting this to be true may have some behavioural oddities if you have chained RetryMessageErrorHandler instances in configuration; The number of attempts that each configured RetryMessageErrorHandler will attempt to handle a message will vary; the total number of attempts should not exceed the highest configured max-retry-count on any individual RetryMessageErrorHandler

        Parameters:
        b - true or false, default null (false).