use of com.yahoo.athenz.zms.ResourceError in project athenz by yahoo.
the class ZMSUtils method error.
public static RuntimeException error(int code, String msg, String caller) {
LOG.error("Error: {} code: {} message: {}", caller, code, msg);
// emit our metrics if configured. the method will automatically
// return from the caller if caller is null
emitMonmetricError(code, caller);
return new ResourceException(code, new ResourceError().code(code).message(msg));
}
Aggregations