kezhenxu94 commented on a change in pull request #6888:
URL: https://github.com/apache/skywalking/pull/6888#discussion_r624608966
##########
File path:
oap-server/server-query-plugin/query-graphql-plugin/src/main/java/org/apache/skywalking/oap/query/graphql/resolver/AlarmQuery.java
##########
@@ -62,11 +85,166 @@ public Alarms getAlarm(final Duration duration, final
Scope scope, final String
}
long startSecondTB = 0;
long endSecondTB = 0;
+ EventQueryCondition condition = new EventQueryCondition();
if (nonNull(duration)) {
startSecondTB = duration.getStartTimeBucketInSec();
endSecondTB = duration.getEndTimeBucketInSec();
+ condition.setTime(duration);
+ }
+ condition.setType(EventType.Error);
+ condition.setName("Alarm");
Review comment:
These conditions are specific to alarm events, which is not what we want.
Let's take an example, if there is an alarm saying that
`cpm(serviceA_Instance1) == 0`, we should include all events of
`serviceA_Instance1` during that period, they may be `Shutdown` event, `Crash`
event, etc. so that users can make sense of the alarm from the events quickly
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]