WillemJiang commented on a change in pull request #555: [SCB-327] Update 
metrics publish data module (Re-organized)
URL: 
https://github.com/apache/incubator-servicecomb-java-chassis/pull/555#discussion_r169887598
 
 

 ##########
 File path: 
foundations/foundation-metrics/src/main/java/org/apache/servicecomb/foundation/metrics/publish/MetricsLoader.java
 ##########
 @@ -40,7 +42,7 @@ public MetricNode getMetricTree(String id, String... 
groupTagKeys) {
     if (metrics.containsKey(id)) {
       return new MetricNode(metrics.get(id), groupTagKeys);
     }
-    return null;
+    throw new ServiceCombException("no such id");
 
 Review comment:
   Please keep the id in the exception for the developer to find out the failed 
reason.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to