From 4984fa8ca61441996781af75824d31619a2751ea Mon Sep 17 00:00:00 2001 From: Pim van Nierop Date: Tue, 16 Jul 2024 07:39:52 +0200 Subject: [PATCH] Add @ExceptionHandler for notification transmission exceptions --- .../exception/handler/ResponseEntityExceptionHandler.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/main/java/org/radarbase/appserver/exception/handler/ResponseEntityExceptionHandler.java b/src/main/java/org/radarbase/appserver/exception/handler/ResponseEntityExceptionHandler.java index 5a7ef43d..7b219315 100644 --- a/src/main/java/org/radarbase/appserver/exception/handler/ResponseEntityExceptionHandler.java +++ b/src/main/java/org/radarbase/appserver/exception/handler/ResponseEntityExceptionHandler.java @@ -59,6 +59,11 @@ public final ResponseEntity handleInvalidNotificationDetailsExcept return handleEntityWithoutCause(ex, request); } + @ExceptionHandler(MessageTransmitException.class) + public final ResponseEntity handleMessageTransmitException(Exception ex, WebRequest request) { + return handleEntityWithCause(ex, request); + } + @ExceptionHandler(InvalidUserDetailsException.class) public final ResponseEntity handleInvalidUserDetailsException(Exception ex, WebRequest request) { return handleEntityWithCause(ex, request);