}
catch(VnfmDriverException e)
{
- try {
- httpResponse.setStatus(HttpStatus.SC_BAD_REQUEST);
- httpResponse.sendError(e.getHttpStatus(), e.getMessage());
- } catch (IOException e1) {
-
- }
+ processControllerException(httpResponse, e);
}
return null;
}
catch(VnfmDriverException e)
{
- try {
- httpResponse.setStatus(HttpStatus.SC_BAD_REQUEST);
- httpResponse.sendError(e.getHttpStatus(), e.getMessage());
- } catch (IOException e1) {
-
- }
+ processControllerException(httpResponse, e);
}
return null;
}
catch(VnfmDriverException e)
{
- try {
- httpResponse.sendError(e.getHttpStatus(), e.getMessage());
- } catch (IOException e1) {
-
- }
+ processControllerException(httpResponse, e);
}
return null;
}
catch(VnfmDriverException e)
{
- try {
- httpResponse.sendError(e.getHttpStatus(), e.getMessage());
- } catch (IOException e1) {
-
- }
+ processControllerException(httpResponse, e);
}
return null;
}
catch(VnfmDriverException e)
{
- try {
- httpResponse.sendError(e.getHttpStatus(), e.getMessage());
- } catch (IOException e1) {
-
- }
+ processControllerException(httpResponse, e);
}
return null;
}
+ private void processControllerException(HttpServletResponse httpResponse, VnfmDriverException e) {
+ try {
+ logger.error(" VnfmDriverController --> processControllerException", e);
+ httpResponse.setStatus(HttpStatus.SC_BAD_REQUEST);
+ httpResponse.sendError(e.getHttpStatus(), e.getMessage());
+ } catch (IOException e1) {
+ logger.error("VnfmDriverController --> processControllerException error to sendError ", e1);
+ }
+ }
+
}