wankai123 commented on code in PR #12316:
URL: https://github.com/apache/skywalking/pull/12316#discussion_r1634009482


##########
oap-server/server-query-plugin/promql-plugin/src/main/java/org/apache/skywalking/oap/query/promql/rt/PromQLExprQueryVisitor.java:
##########
@@ -440,6 +440,32 @@ private Entity buildEntity(Layer layer,
                 checkLabels(labelMap, LabelName.ENDPOINT);
                 entity.setEndpointName(labelMap.get(LabelName.ENDPOINT));
                 break;
+            case ServiceRelation:
+                checkLabels(labelMap, LabelName.DEST_SERVICE);
+                checkLabels(labelMap, LabelName.DEST_LAYER);
+                
entity.setDestServiceName(labelMap.get(LabelName.DEST_SERVICE));
+                
entity.setDestNormal(Layer.nameOf(labelMap.get(LabelName.DEST_LAYER)).isNormal());
+                break;
+            case ServiceInstanceRelation:
+                checkLabels(labelMap, LabelName.DEST_SERVICE);
+                checkLabels(labelMap, LabelName.DEST_SERVICE_INSTANCE);
+                checkLabels(labelMap, LabelName.SERVICE_INSTANCE);
+                checkLabels(labelMap, LabelName.DEST_LAYER);

Review Comment:
   ```suggestion
                   checkLabels(labelMap, , LabelName.SERVICE_INSTANCE, 
LabelName.DEST_SERVICE, LabelName.DEST_SERVICE_INSTANCE,  
LabelName.SERVICE_INSTANCE, LabelName.DEST_LAYER);
   ```



-- 
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]

Reply via email to