Unverified Commit d08d3d72 authored by Sebastian Schüpbach's avatar Sebastian Schüpbach
Browse files

change log level for stacktrace

parent a9e2bb0a
Pipeline #20176 passed with stages
in 7 minutes and 12 seconds
...@@ -77,7 +77,7 @@ object App extends scala.App with Logging with RecordUtils { ...@@ -77,7 +77,7 @@ object App extends scala.App with Logging with RecordUtils {
ReportingObject.addResourceOutcome(reportingObject, (resource, msg), ProcessingWarning) ReportingObject.addResourceOutcome(reportingObject, (resource, msg), ProcessingWarning)
case ProcessFatal(id, resource, msg, ex) => case ProcessFatal(id, resource, msg, ex) =>
logger.error(s"$id: $msg: ${ex.getMessage}") logger.error(s"$id: $msg: ${ex.getMessage}")
logger.debug(ex.getStackTrace.mkString("\n")) logger.info(ex.getStackTrace.mkString("\n"))
ReportingObject.addResourceOutcome(reportingObject, (resource, s"$msg: ${ex.getMessage}"), ProcessingFatal) ReportingObject.addResourceOutcome(reportingObject, (resource, s"$msg: ${ex.getMessage}"), ProcessingFatal)
}) })
reporter.send(reportingObject, headers) reporter.send(reportingObject, headers)
......
...@@ -47,7 +47,6 @@ class FedoraClientWrapper(fc: FedoraClient) { ...@@ -47,7 +47,6 @@ class FedoraClientWrapper(fc: FedoraClient) {
for { for {
u <- Try(new URL(url)) u <- Try(new URL(url))
ip <- Try(io.Source.fromURL(u)) ip <- Try(io.Source.fromURL(u))
//resource <- Try(fc.fetchBinaryResource(u))
outputStream <- copyDataAndCloseResource(ip) outputStream <- copyDataAndCloseResource(ip)
} yield outputStream } yield outputStream
} }
......
...@@ -69,7 +69,7 @@ class RecordProcessor(fileHandler: DisseminationCopyHandler, ...@@ -69,7 +69,7 @@ class RecordProcessor(fileHandler: DisseminationCopyHandler,
binaryResource.resource, binaryResource.resource,
data) data)
case Failure(ex) => List(ProcessFatal(recordKey, binaryResource.resource, case Failure(ex) => List(ProcessFatal(recordKey, binaryResource.resource,
s"Failed to retrieve binary from Fedora on ${binaryResource.filePath}", ex)) s"Failed to retrieve binary from Media File Distributor with URL ${binaryResource.filePath}", ex))
} }
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment