public class AlipayLogger extends Object
| Constructor and Description |
|---|
AlipayLogger() |
| Modifier and Type | Method and Description |
|---|---|
static String |
getIp()
Gets ip.
|
static Boolean |
isBizDebugEnabled()
Is biz debug enabled boolean.
|
static void |
logBizDebug(String rsp)
业务/系统错误日志
|
static void |
logBizError(String rsp)
业务/系统错误日志
|
static void |
logBizError(String rsp,
Map<String,Long> costTimeMap)
业务/系统错误日志
|
static void |
logBizError(Throwable t)
业务/系统错误日志
|
static void |
logBizSummary(Map<String,Object> rt,
AlipayResponse tRsp,
Map<String,Long> costTimeMap)
发生特别错误时记录完整错误现场
|
static void |
logCommError(Exception e,
HttpURLConnection conn,
String appKey,
String method,
byte[] content)
通讯错误日志
|
static void |
logCommError(Exception e,
HttpURLConnection conn,
String appKey,
String method,
Map<String,String> params)
通讯错误日志
|
static void |
logCommError(Exception e,
String url,
String appKey,
String method,
byte[] content)
通讯错误日志
|
static void |
logCommError(Exception e,
String url,
String appKey,
String method,
Map<String,String> params)
Log comm error.
|
static void |
logErrorScene(Map<String,Object> rt,
AlipayResponse tRsp,
String appSecret)
发生特别错误时记录完整错误现场
|
static void |
logErrorScene(Map<String,Object> rt,
AlipayResponse tRsp,
String appSecret,
Map<String,Long> costTimeMap)
发生特别错误时记录完整错误现场
|
static void |
setIp(String ip)
Sets ip.
|
static void |
setJDKDebugEnabled(Boolean isEnabled)
开启DEBUG级别日志(仅针对JDK14LOGGER,LOG4J请自行修改配置文件)
|
static void |
setNeedEnableLogger(boolean needEnableLogger)
Sets need enable logger.
|
public static void setNeedEnableLogger(boolean needEnableLogger)
needEnableLogger - the need enable loggerpublic static String getIp()
public static void setIp(String ip)
ip - the ippublic static void logCommError(Exception e, HttpURLConnection conn, String appKey, String method, byte[] content)
e - the econn - the connappKey - the app keymethod - the methodcontent - the contentpublic static void logCommError(Exception e, String url, String appKey, String method, byte[] content)
e - the eurl - the urlappKey - the app keymethod - the methodcontent - the contentpublic static void logCommError(Exception e, HttpURLConnection conn, String appKey, String method, Map<String,String> params)
e - the econn - the connappKey - the app keymethod - the methodparams - the paramspublic static void logCommError(Exception e, String url, String appKey, String method, Map<String,String> params)
e - the eurl - the urlappKey - the app keymethod - the methodparams - the paramspublic static void logBizDebug(String rsp)
rsp - the rsppublic static void logBizError(String rsp)
rsp - the rsppublic static void logBizError(String rsp, Map<String,Long> costTimeMap)
rsp - the rspcostTimeMap - the cost time mappublic static void logBizError(Throwable t)
t - the tpublic static void logErrorScene(Map<String,Object> rt, AlipayResponse tRsp, String appSecret)
rt - the rttRsp - the t rspappSecret - the app secretpublic static void logErrorScene(Map<String,Object> rt, AlipayResponse tRsp, String appSecret, Map<String,Long> costTimeMap)
rt - the rttRsp - the t rspappSecret - the app secretcostTimeMap - the cost time mappublic static void logBizSummary(Map<String,Object> rt, AlipayResponse tRsp, Map<String,Long> costTimeMap)
rt - the rttRsp - the t rspcostTimeMap - the cost time mappublic static Boolean isBizDebugEnabled()
public static void setJDKDebugEnabled(Boolean isEnabled)
isEnabled - the is enabledCopyright © 2018. All rights reserved.