diff options
-rw-r--r-- | main/pom.xml | 7 | ||||
-rw-r--r-- | main/src/main/java/org/onap/policy/api/main/rest/CommonRestController.java | 4 |
2 files changed, 3 insertions, 8 deletions
diff --git a/main/pom.xml b/main/pom.xml index 86be7696..eb279e8d 100644 --- a/main/pom.xml +++ b/main/pom.xml @@ -4,7 +4,7 @@ Modified Copyright (C) 2018 Samsung Electronics Co., Ltd. Copyright (C) 2019,2021 AT&T Intellectual Property. All rights reserved. Modifications Copyright (C) 2020-2023 Bell Canada. - Modifications Copyright (C) 2022-2024 Nordix Foundation. + Modifications Copyright (C) 2022-2025 Nordix Foundation. ================================================================================ Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -180,11 +180,6 @@ <scope>runtime</scope> </dependency> <dependency> - <groupId>io.netty</groupId> - <artifactId>netty-codec</artifactId> - <scope>runtime</scope> - </dependency> - <dependency> <groupId>org.hibernate.orm</groupId> <artifactId>hibernate-core</artifactId> <scope>runtime</scope> diff --git a/main/src/main/java/org/onap/policy/api/main/rest/CommonRestController.java b/main/src/main/java/org/onap/policy/api/main/rest/CommonRestController.java index 97fdb242..ec4dfe2b 100644 --- a/main/src/main/java/org/onap/policy/api/main/rest/CommonRestController.java +++ b/main/src/main/java/org/onap/policy/api/main/rest/CommonRestController.java @@ -4,7 +4,7 @@ * ================================================================================
* Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
* Modifications Copyright (C) 2022 Bell Canada. All rights reserved.
- * Modifications Copyright (C) 2022-2024 Nordix Foundation.
+ * Modifications Copyright (C) 2022-2025 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -132,7 +132,7 @@ public class CommonRestController { @ExceptionHandler(value = {PolicyApiRuntimeException.class})
protected ResponseEntity<Object> handleException(PolicyApiRuntimeException ex, WebRequest req) {
- LOGGER.warn(ex.getMessage(), ex.getCause());
+ LOGGER.warn(ex.getErrorResponse().getErrorMessage(), ex.getCause());
final var requestId = req.getHeader(CommonRestController.REQUEST_ID_NAME);
final var status = ex.getErrorResponse().getResponseCode().getStatusCode();
return CommonRestController.addLoggingHeaders(
|