全部文档
当前文档

暂无内容

如果没有找到您期望的内容,请尝试其他搜索词

文档中心

查询监控采集配置

请求参数

以下请求参数列表仅列出了接口请求参数和部分公共参数,完整公共参数列表见公共请求参数
参数名称
类型
必填
描述
Action String
公共参数,本接口取值:DescribeMonitorCollectionConfig。
Version String
公共参数,本接口取值:2023-03-06。
InstanceId String

实例id

ClusterId String

集群id

MonitorName String

监控采集配置名称

Type String

监控采集配置类型,有效值:
RawJob
PodMonitor
ServiceMonitor

返回参数

参数名称
类型
描述
RequestId String

请求id

ConfigYaml String

监控采集配置yaml

请求示例

curl -X GET|POST
'http://kce.api.ksyun.com/?Action=DescribeMonitorCollectionConfig&Version=2023-03-06'
-H 'authorization: xxx, SignedHeaders=content-type;host;x-amz-date, Signature=xxx'
-H 'cache-control: no-cache'
-H 'content-type: application/x-www-form-urlencoded'
-H 'host: kce.api.ksyun.com'
-H 'x-amz-date: 20170720T022802Z'
-d 'InstanceId=xxx&ClusterId=xxx&MonitorName=xxx&Type=xxx'

返回示例

JSON格式

{
"RequestId":"abbe4ffc-4061-4f19-b18b-3356490715cd",
"ConfigYaml":"- job_name: apiserver scrape_interval: 15s honor_labels: true scheme: https tls_config: ca_file: /var/run/secrets/kubernetes.io/serviceaccount/ca.crt insecure_skip_verify: true bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token relabel_configs: - source_labels: [job] target_label: __tmp_prometheus_job_name - source_labels: [__meta_kubernetes_pod_label_component, __meta_kubernetes_pod_labelpresent_component] regex: (kube-apiserver);true action: keep - source_labels: [__meta_kubernetes_namespace] target_label: namespace - source_labels: [__meta_kubernetes_pod_container_name] target_label: container - source_labels: [__meta_kubernetes_pod_name] target_label: pod - target_label: job replacement: apiserver - target_label: endpoint replacement: "6443" - source_labels: [__meta_kubernetes_pod_host_ip] target_label: __address__ replacement: ${1}:6443 regex: (.+) metric_relabel_configs: - action: drop regex: kubelet_(pod_worker_latency_microseconds|pod_start_latency_microseconds|cgroup_manager_latency_microseconds|pod_worker_start_latency_microseconds|pleg_relist_latency_microseconds|pleg_relist_interval_microseconds|runtime_operations|runtime_operations_latency_microseconds|runtime_operations_errors|eviction_stats_age_microseconds|device_plugin_registration_count|device_plugin_alloc_latency_microseconds|network_plugin_operations_latency_microseconds) source_labels: [__name__] - action: drop regex: scheduler_(e2e_scheduling_latency_microseconds|scheduling_algorithm_predicate_evaluation|scheduling_algorithm_priority_evaluation|scheduling_algorithm_preemption_evaluation|scheduling_algorithm_latency_microseconds|binding_latency_microseconds|scheduling_latency_seconds) source_labels: [__name__] - action: drop regex: apiserver_(request_count|request_latencies|request_latencies_summary|dropped_requests|storage_data_key_generation_latencies_microseconds|storage_transformation_failures_total|storage_transformation_latencies_microseconds|proxy_tunnel_sync_latency_secs|longrunning_gauge|registered_watchers) source_labels: [__name__] - action: drop regex: kubelet_docker_(operations|operations_latency_microseconds|operations_errors|operations_timeout) source_labels: [__name__] - action: drop regex: reflector_(items_per_list|items_per_watch|list_duration_seconds|lists_total|short_watches_total|watch_duration_seconds|watches_total) source_labels: [__name__] - action: drop regex: etcd_(helper_cache_hit_count|helper_cache_miss_count|helper_cache_entry_count|object_counts|request_cache_get_latencies_summary|request_cache_add_latencies_summary|request_latencies_summary) source_labels: [__name__] - action: drop regex: transformation_(transformation_latencies_microseconds|failures_total) source_labels: [__name__] - action: drop regex: (admission_quota_controller_adds|admission_quota_controller_depth|admission_quota_controller_longest_running_processor_microseconds|admission_quota_controller_queue_latency|admission_quota_controller_unfinished_work_seconds|admission_quota_controller_work_duration|APIServiceOpenAPIAggregationControllerQueue1_adds|APIServiceOpenAPIAggregationControllerQueue1_depth|APIServiceOpenAPIAggregationControllerQueue1_longest_running_processor_microseconds|APIServiceOpenAPIAggregationControllerQueue1_queue_latency|APIServiceOpenAPIAggregationControllerQueue1_retries|APIServiceOpenAPIAggregationControllerQueue1_unfinished_work_seconds|APIServiceOpenAPIAggregationControllerQueue1_work_duration|APIServiceRegistrationController_adds|APIServiceRegistrationController_depth|APIServiceRegistrationController_longest_running_processor_microseconds|APIServiceRegistrationController_queue_latency|APIServiceRegistrationController_retries|APIServiceRegistrationController_unfinished_work_seconds|APIServiceRegistrationController_work_duration|autoregister_adds|autoregister_depth|autoregister_longest_running_processor_microseconds|autoregister_queue_latency|autoregister_retries|autoregister_unfinished_work_seconds|autoregister_work_duration|AvailableConditionController_adds|AvailableConditionController_depth|AvailableConditionController_longest_running_processor_microseconds|AvailableConditionController_queue_latency|AvailableConditionController_retries|AvailableConditionController_unfinished_work_seconds|AvailableConditionController_work_duration|crd_autoregistration_controller_adds|crd_autoregistration_controller_depth|crd_autoregistration_controller_longest_running_processor_microseconds|crd_autoregistration_controller_queue_latency|crd_autoregistration_controller_retries|crd_autoregistration_controller_unfinished_work_seconds|crd_autoregistration_controller_work_duration|crdEstablishing_adds|crdEstablishing_depth|crdEstablishing_longest_running_processor_microseconds|crdEstablishing_queue_latency|crdEstablishing_retries|crdEstablishing_unfinished_work_seconds|crdEstablishing_work_duration|crd_finalizer_adds|crd_finalizer_depth|crd_finalizer_longest_running_processor_microseconds|crd_finalizer_queue_latency|crd_finalizer_retries|crd_finalizer_unfinished_work_seconds|crd_finalizer_work_duration|crd_naming_condition_controller_adds|crd_naming_condition_controller_depth|crd_naming_condition_controller_longest_running_processor_microseconds|crd_naming_condition_controller_queue_latency|crd_naming_condition_controller_retries|crd_naming_condition_controller_unfinished_work_seconds|crd_naming_condition_controller_work_duration|crd_openapi_controller_adds|crd_openapi_controller_depth|crd_openapi_controller_longest_running_processor_microseconds|crd_openapi_controller_queue_latency|crd_openapi_controller_retries|crd_openapi_controller_unfinished_work_seconds|crd_openapi_controller_work_duration|DiscoveryController_adds|DiscoveryController_depth|DiscoveryController_longest_running_processor_microseconds|DiscoveryController_queue_latency|DiscoveryController_retries|DiscoveryController_unfinished_work_seconds|DiscoveryController_work_duration|kubeproxy_sync_proxy_rules_latency_microseconds|non_structural_schema_condition_controller_adds|non_structural_schema_condition_controller_depth|non_structural_schema_condition_controller_longest_running_processor_microseconds|non_structural_schema_condition_controller_queue_latency|non_structural_schema_condition_controller_retries|non_structural_schema_condition_controller_unfinished_work_seconds|non_structural_schema_condition_controller_work_duration|rest_client_request_latency_seconds|storage_operation_errors_total|storage_operation_status_count) source_labels: [__name__] - action: drop regex: etcd_(debugging|disk|server).* source_labels: [__name__] - action: drop regex: apiserver_admission_controller_admission_latencies_seconds_.* source_labels: [__name__] - action: drop regex: apiserver_admission_step_admission_latencies_seconds_.* source_labels: [__name__] - action: drop regex: apiserver_request_duration_seconds_bucket;(0.15|0.25|0.3|0.35|0.4|0.45|0.6|0.7|0.8|0.9|1.25|1.5|1.75|2.5|3|3.5|4.5|6|7|8|9|15|25|30|50) source_labels: [__name__,le] kubernetes_sd_configs: - role: pod namespaces: own_namespace: false names: - kube-system "
}

错误码

以下仅列出了接口业务逻辑相关的错误码,其他错误码详见公共错误码

纯净模式常规模式

纯净模式

点击可全屏预览文档内容