com.atlassian.greenhopper.web.util
Class RestCall
java.lang.Object
com.atlassian.greenhopper.web.util.RestCall
public class RestCall
- extends java.lang.Object
JIRA by default does not log REST call failures in atlassian-jira.log. So we now have a wrapper invoker class
to make the rest call and log any errors. This will ensure that they go to the JIRA log and the
GreenHopper log (if you use a com.atlassian.greenhopper logger say) and this will help with support as well.
- Since:
- 5.8.7
Constructor Summary |
RestCall(java.lang.Class restClass)
|
RestCall(org.apache.log4j.Logger logger)
|
Method Summary |
javax.ws.rs.core.Response |
response(java.util.concurrent.Callable<javax.ws.rs.core.Response> callable)
This will invoke the Callable and return the response to the callee. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RestCall
public RestCall(org.apache.log4j.Logger logger)
RestCall
public RestCall(java.lang.Class restClass)
response
public javax.ws.rs.core.Response response(java.util.concurrent.Callable<javax.ws.rs.core.Response> callable)
- This will invoke the Callable and return the response to the callee. If an exception occurs it will
log that into the appropriate logger.
- Parameters:
callable
- the REST call code that will respond to the rest call
- Returns:
- a REST
Response
Copyright © 2007-2014 Atlassian. All Rights Reserved.