aboutsummaryrefslogtreecommitdiffstats
path: root/vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt
diff options
context:
space:
mode:
authorIttay Stern <ittay.stern@att.com>2020-03-08 15:24:35 +0200
committerIttay Stern <ittay.stern@att.com>2020-03-08 15:24:35 +0200
commit455f47766ce554ed9354d707992353353753745e (patch)
tree7180cff16ce16d076fa6abfa8d95a1613bd932f4 /vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt
parent17b63f0c432f9edf407e4c9f465a295bfd870485 (diff)
Don't use EELFLoggerDelegate.errorLogger in Async jobs
The Logger.error(EELFLoggerDelegate.errorLogger, ...) idiom is flawed. Using direct invocation of LOGGER.error("msg..."). Issue-ID: VID-253 Issue-ID: PORTAL-835 Change-Id: Ibbc7da3a081675d2edbbb782732a14de9c865a3a Signed-off-by: Ittay Stern <ittay.stern@att.com>
Diffstat (limited to 'vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt')
-rw-r--r--vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt6
1 files changed, 3 insertions, 3 deletions
diff --git a/vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt b/vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt
index 4477a9f24..2b5ec0127 100644
--- a/vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt
+++ b/vid-app-common/src/main/java/org/onap/vid/job/command/ResourceCommand.kt
@@ -153,7 +153,7 @@ abstract class ResourceCommand(
JobStatus.IN_PROGRESS
}
catch (exception: AbortingException) {
- Logger.error(EELFLoggerDelegate.errorLogger, "caught AbortingException. Set job status to FAILED")
+ Logger.error("caught AbortingException. Set job status to FAILED")
JobStatus.FAILED;
}
}
@@ -330,13 +330,13 @@ abstract class ResourceCommand(
handleInProgressStatus(jobStatus)
} catch (e: javax.ws.rs.ProcessingException) {
// Retry when we can't connect MSO during getStatus
- Logger.error(EELFLoggerDelegate.errorLogger, "Cannot get orchestration status for {}, will retry: {}", requestId, e, e)
+ Logger.error("Cannot get orchestration status for {}, will retry: {}", requestId, e, e)
JobStatus.IN_PROGRESS;
} catch (e: InProgressStatusService.BadResponseFromMso) {
inProgressStatusService.handleFailedMsoResponse(sharedData.jobUuid, requestId, e.msoResponse)
JobStatus.IN_PROGRESS
} catch (e: RuntimeException) {
- Logger.error(EELFLoggerDelegate.errorLogger, "Cannot get orchestration status for {}, stopping: {}", requestId, e, e)
+ Logger.error("Cannot get orchestration status for {}, stopping: {}", requestId, e, e)
JobStatus.STOPPED
}
}