DanGuge commented on code in PR #2262:
URL: 
https://github.com/apache/incubator-hugegraph/pull/2262#discussion_r1278763706


##########
hugegraph-api/src/main/java/org/apache/hugegraph/api/traversers/CrosspointsAPI.java:
##########
@@ -84,6 +85,9 @@ public String get(@Context GraphManager manager,
                                                       dir, edgeLabel, depth,
                                                       maxDegree, capacity,
                                                       limit);
-        return manager.serializer(g).writePaths("crosspoints", paths, true);
+        measure.addIterCount(traverser.vertexIterCounter.get(),
+                             traverser.edgeIterCounter.get());
+        return manager.serializer(g, measure.getResult())

Review Comment:
   Rejected: 
   1. `ApiMeasurer` should be passed in from an outside api implementation so 
that it can carry data
   2. not all apis need `ApiMeasurer` and keeping the `ApiMeasurer` null for 
those APIs can prevent `ApiMeasurer` from being serialized



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to