Class UnexpectedException

java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
es.kukenan.smartfi.common.service.exceptions.UnexpectedException
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
RoutingDlqException

public class UnexpectedException extends RuntimeException
This is the parent exception for any exception thrown corresponding to an unexpected error condition (theoretically, due to an unknown reason or to a condition that should have never happen).

This exceptions must not be handled in an event execution contexts (the event will be redirected to the dead-letter-queue) and must be treated as a generic server error response (with no reason detail) in REST operation contexts.

See Also:
  • Field Details

    • uuid

      private final String uuid
      Universally unique identifier for this exception.
    • code

      private final String code
      Error code.
  • Constructor Details

    • UnexpectedException

      public UnexpectedException(String message, Throwable cause)
      Constructor.
      Parameters:
      message - error message.
      cause - error cause, if any.
    • UnexpectedException

      protected UnexpectedException(String message, Throwable cause, String code)
      Constructor.
      Parameters:
      message - error message.
      cause - error cause, if any.
      code - the exception code.
  • Method Details