提交 e7a5fd69 编写于 作者: wu-sheng's avatar wu-sheng

no message

上级 06b9f5f6
type AlarmItem {
# Typical include: Application Code + cause type. This is a short description.
title: String!
# Include all related info to trigger this alarm.
# such as: threshold, trigger value, relation(greater or lower), last time
content: String!
startTime: String!
alertType: AlarmType!
......
......@@ -35,6 +35,6 @@ type ConjecturalNode implements Node {
extend type Query {
getAllApplication(duration: Duration!): [ApplicationNode]
getApplicationTopology(applicationId: ID!, duration: Duration!): Topology
getSlowService(applicationId: ID!, duration: Duration, top: Int!!): [ServiceInfo!]
getSlowService(applicationId: ID!, duration: Duration, top: Int!): [ServiceInfo!]
getServerThroughput(applicationId: ID!, duration: Duration!, top: Int!): [AppServerInfo!]
}
......@@ -44,11 +44,11 @@ enum Step {
SECOND
}
type Pagination {
//pageNum starts in 1, the default is 1.
input Pagination {
# pageNum starts in 1, the default is 1.
pageNum: Int
pageSize: Int!
//default false
# default false
needTotal: Boolean
}
......
type TTLConfigs {
items: [TTLConfigItem]!
}
type TTLConfigItem {
input TTLConfigItem {
unit: Step!
value: Int!
}
type ExistedTTLConfigs{
ttl: [TTL!]!
}
type TTL {
unit: Step!
value: Int!
}
input AlarmThreshold {
type: AlarmType!
threshold: Int!
causeType: CauseType!
}
type ExistedAlarmThresholds {
items: [ExistedAlarmThresholdItem!]!
}
type ExistedAlarmThresholdItem {
threshold: Int!
causeType: CauseType!
}
extend type Mutation {
setDataTTLConfigs(ttl: TTLConfigs!): TTLConfigs
setDataTTLConfigs(ttl: [TTLConfigItem!]!): Boolean!
setAlarmThreshold(thresholds: [AlarmThreshold!]!): Boolean!
}
extend type Query {
queryAllDataTTLConfigs: ExistedTTLConfigs!
queryAlarmThresholds(alarmType: AlarmType): ExistedAlarmThresholds!
}
\ No newline at end of file
......@@ -15,7 +15,7 @@ type AlarmTrend {
# Query all conjectural applications based on the given duration
# All applications here are not installed agent.
type ConjecturalAppBrief {
apps: [ConjecturalApp!]
apps: [ConjecturalApp!]!
}
# The basic info of the conjectural application,
......@@ -32,6 +32,6 @@ extend type Query {
getClusterBrief(duration: Duration!): ClusterBrief
getAlarmTrend(duration: Duration!): AlarmTrend
getConjecturalApps(duration: Duration!): ConjecturalAppBrief
getTopNSlowService(duration: Duration!, topN: Int!): [ServiceInfo!]
getTopNServerThroughput(duration: Duration!, topN: Int!): [AppServerInfo!]
getTopNSlowService(duration: Duration!, topN: Int!): [ServiceInfo!]!
getTopNServerThroughput(duration: Duration!, topN: Int!): [AppServerInfo!]!
}
......@@ -35,7 +35,7 @@ enum QueryOrder {
# The trace represents a distributed trace, includes all segments and spans.
type Trace {
traceId: ID!
segments: [Segment!]
segments: [Segment!]!
}
type Segment {
......
......@@ -43,6 +43,7 @@ public class GraphQLScriptTest {
typeRegistry.merge(schemaParser.parse(loadSchema("server-layer.graphqls")));
typeRegistry.merge(schemaParser.parse(loadSchema("service-layer.graphqls")));
typeRegistry.merge(schemaParser.parse(loadSchema("alarm.graphqls")));
typeRegistry.merge(schemaParser.parse(loadSchema("config.graphqls")));
RuntimeWiring wiring = buildRuntimeWiring();
assertTrue(schemaGenerator.makeExecutableSchema(typeRegistry, wiring).getAllTypesAsList().size() > 0);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册