From 33ef830289f9e728331d780e09e931be1da39b5b Mon Sep 17 00:00:00 2001 From: yakunyang Date: Fri, 14 Jun 2024 18:20:23 +0800 Subject: [PATCH] =?UTF-8?q?[6.4.4]=20[fea]=20=E6=8E=A5=E5=8F=A3=E6=97=A5?= =?UTF-8?q?=E5=BF=97=E6=B7=BB=E5=8A=A0tag?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../common/module/network/OchCommonSubscribeImpl.kt | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/OCH/common/common/src/main/java/com/mogo/och/common/module/network/OchCommonSubscribeImpl.kt b/OCH/common/common/src/main/java/com/mogo/och/common/module/network/OchCommonSubscribeImpl.kt index 1f008ebf20..f656eb1d1b 100644 --- a/OCH/common/common/src/main/java/com/mogo/och/common/module/network/OchCommonSubscribeImpl.kt +++ b/OCH/common/common/src/main/java/com/mogo/och/common/module/network/OchCommonSubscribeImpl.kt @@ -18,10 +18,12 @@ class OchCommonSubscribeImpl( const val TAG = "OchCommonSubscribeImpl" } + private var tag:Long = System.currentTimeMillis() + init { CallerLogger.e("$flavorTag$TAG", "$apiName: 去请求()") if(writeLog) { - OchChainLogManager.writeChainLogNet("接口:${apiName}", "去请求") + OchChainLogManager.writeChainLogNet("接口:${apiName}_${tag}", "去请求") } } @@ -29,7 +31,7 @@ class OchCommonSubscribeImpl( super.onSuccess(o) CallerLogger.d("$flavorTag$TAG", "$apiName: onSuccess() ${o.msg}") if(writeLog) { - OchChainLogManager.writeChainLogNet("接口:${apiName}", "请求成功:${o}") + OchChainLogManager.writeChainLogNet("接口:${apiName}_${tag}", "请求成功:${o}") } callback?.onSuccess(o) } @@ -38,7 +40,7 @@ class OchCommonSubscribeImpl( super.onError(e) CallerLogger.e("$flavorTag$TAG", "$apiName: onError() ${e.message}") if(writeLog) { - OchChainLogManager.writeChainLogNet("接口:${apiName}", "请求失败:${e.message}") + OchChainLogManager.writeChainLogNet("接口:${apiName}_${tag}", "请求失败:${e.message}") } callback?.onError("$apiName: onError() ${e.message}") callback?.onError() @@ -49,7 +51,7 @@ class OchCommonSubscribeImpl( CallerLogger.e("$flavorTag$TAG", "$apiName: onError() code = $code; message = $message") if(writeLog) { OchChainLogManager.writeChainLogNet( - "接口:${apiName}", + "接口:${apiName}_${tag}", "请求失败: onError() code = $code; message = $message\"" ) }