working on preparing journal loggin

Signed-off-by: Stephan Richter <s.richter@srsoftware.de>
This commit is contained in:
2026-01-09 13:02:53 +01:00
parent 81dc30359d
commit 0dd640de30
8 changed files with 26 additions and 13 deletions

View File

@@ -8,6 +8,7 @@ import static java.lang.System.Logger.Level.ERROR;
import static java.lang.System.Logger.Level.WARNING;
import static java.net.HttpURLConnection.HTTP_FORBIDDEN;
import static java.net.HttpURLConnection.HTTP_NOT_FOUND;
import static java.text.MessageFormat.format;
public class UmbrellaException extends RuntimeException{
@@ -43,7 +44,12 @@ public class UmbrellaException extends RuntimeException{
return new UmbrellaException(HTTP_FORBIDDEN,message,fills);
}
public static UmbrellaException invalidFieldException(String field,String expected){
@Override
public String getMessage() {
return format(super.getMessage(),fills);
}
public static UmbrellaException invalidFieldException(String field, String expected){
return new UmbrellaException(HTTP_UNPROCESSABLE, ERROR_INVALID_FIELD, field, expected);
}