Update virtual cache e2e test case to apply MQE (#11151)
This commit is contained in:
parent
33ea0f1347
commit
f14a4b007d
|
|
@ -0,0 +1,31 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
type: TIME_SERIES_VALUES
|
||||
results:
|
||||
{{- contains .results }}
|
||||
- metric:
|
||||
labels: []
|
||||
values:
|
||||
{{- contains .values }}
|
||||
- id: {{ notEmpty .id }}
|
||||
value: {{ .value }}
|
||||
traceid: null
|
||||
- id: {{ notEmpty .id }}
|
||||
value: null
|
||||
traceid: null
|
||||
{{- end}}
|
||||
{{- end}}
|
||||
error: null
|
||||
|
|
@ -0,0 +1,28 @@
|
|||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
type: RECORD_LIST
|
||||
results:
|
||||
{{- contains .results }}
|
||||
- metric:
|
||||
labels: []
|
||||
values:
|
||||
{{- contains .values }}
|
||||
- id: {{ notEmpty .id }}
|
||||
value: {{ notEmpty .value }}
|
||||
traceid: {{ notEmpty .traceid }}
|
||||
{{- end}}
|
||||
{{- end}}
|
||||
error: null
|
||||
|
|
@ -34,18 +34,18 @@
|
|||
expected: expected/metrics-has-value.yml
|
||||
# virtual cache
|
||||
- query: |
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=cache_read_resp_time --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0 | yq e 'to_entries' -
|
||||
expected: expected/metrics-has-value.yml
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics exec --expression=cache_read_resp_time --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0
|
||||
expected: expected/virtual_cache_has_metrics.yml
|
||||
- query: |
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=cache_write_sla --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0 | yq e 'to_entries' -
|
||||
expected: expected/metrics-has-value.yml
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics exec --expression=cache_write_sla --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0
|
||||
expected: expected/virtual_cache_has_metrics.yml
|
||||
- query: |
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=cache_access_cpm --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0 | yq e 'to_entries' -
|
||||
expected: expected/metrics-has-value.yml
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics exec --expression=cache_access_cpm --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0
|
||||
expected: expected/virtual_cache_has_metrics.yml
|
||||
- query: |
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql records list --name=top_n_cache_write_command --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0 | yq e 'to_entries | with(.[] ; .value=(.value | to_entries))' -
|
||||
expected: expected/record-has-value.yml
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics exec --expression="top_n(top_n_cache_write_command,10,des)" --service-id=R3VhdmFDYWNoZS1sb2NhbA==.0
|
||||
expected: expected/virtual_cache_has_topN_records.yml
|
||||
# virtual database
|
||||
- query: |
|
||||
swctl --display yaml --base-url=http://${oap_host}:${oap_12800}/graphql metrics linear --name=database_access_resp_time --service-id=bG9jYWxob3N0Oi0x.0 | yq e 'to_entries' -
|
||||
expected: expected/metrics-has-value.yml
|
||||
expected: expected/metrics-has-value.yml
|
||||
|
|
|
|||
Loading…
Reference in New Issue