org.camunda.bpm.engine.rest.exception
Class ExceptionHandler

java.lang.Object
  extended by org.camunda.bpm.engine.rest.exception.ExceptionHandler
All Implemented Interfaces:
javax.ws.rs.ext.ExceptionMapper<Exception>

@Provider
public class ExceptionHandler
extends Object
implements javax.ws.rs.ext.ExceptionMapper<Exception>

Translates any Exception to a HTTP 500 error and a JSON response. Response content format: {"type" : "ExceptionType", "message" : "some exception message"}

Author:
nico.rehwaldt

Constructor Summary
ExceptionHandler()
           
 
Method Summary
protected  String getStackTrace(Throwable aThrowable)
           
 javax.ws.rs.core.Response toResponse(Exception exception)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExceptionHandler

public ExceptionHandler()
Method Detail

toResponse

public javax.ws.rs.core.Response toResponse(Exception exception)
Specified by:
toResponse in interface javax.ws.rs.ext.ExceptionMapper<Exception>

getStackTrace

protected String getStackTrace(Throwable aThrowable)


Copyright © 2016 camunda services GmbH. All rights reserved.