Permalink
Browse files

Add caught exception to the logs

This should help later to determine the cause of the exception
  • Loading branch information...
1 parent b02c712 commit 5adb2fb5f3dac226291810e143dddd25305af35f @ColinHebert ColinHebert committed Jan 23, 2013
Showing with 3 additions and 3 deletions.
  1. +3 −3 src/main/java/uk/ac/ox/oucs/sirlouie/LibraryAvailability.java
@@ -79,17 +79,17 @@ public Response get(
}
} catch (URISyntaxException e) {
- log.error("URISyntaxException ["+e.getLocalizedMessage()+"]");
+ log.error("URISyntaxException ["+e.getLocalizedMessage()+"]", e);
return Response.status(Status.INTERNAL_SERVER_ERROR)
.entity(e.getLocalizedMessage()).type("text/plain").build();
} catch (UnsupportedEncodingException e) {
- log.error("UnsupportedEncodingException ["+e.getLocalizedMessage()+"]");
+ log.error("UnsupportedEncodingException ["+e.getLocalizedMessage()+"]", e);
return Response.status(Status.INTERNAL_SERVER_ERROR)
.entity(e.getLocalizedMessage()).type("text/plain").build();
} catch (Exception e) {
- log.error("Exception ["+e.getLocalizedMessage()+"]");
+ log.error("Exception ["+e.getLocalizedMessage()+"]", e);
return Response.status(Status.INTERNAL_SERVER_ERROR)
.entity(e.getLocalizedMessage()).type("text/plain").build();

0 comments on commit 5adb2fb

Please sign in to comment.