Browse Source

Update RecommendService: better log

StrayWarrior 7 tháng trước cách đây
mục cha
commit
9ec1428352

+ 2 - 2
long-article-recommend-service/src/main/java/com/tzld/longarticle/recommend/server/service/recommend/RecommendService.java

@@ -101,8 +101,8 @@ public class RecommendService {
 
         RecommendResponse response = buildRecommendResponse(recallResult, rankResult, param.getPublishNum());
         long t4  = System.currentTimeMillis();
-        log.info("recommendCost param:{} response {} cost:{}", JSONObject.toJSONString(request),
-                JSONObject.toJSONString(response), t4 - start);
+        log.info("recommendCost param:{} total cost:{} recall:{} rank:{} response: {}", JSONObject.toJSONString(request),
+                t4 - start, t2 - start, t3 - t2, JSONObject.toJSONString(response));
         CostMonitor.logCost("Recommend", "Total", t4 - start);
         return response;
     }