Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add metrics for scheduler #747

Merged
merged 1 commit into from
Sep 29, 2021
Merged

Conversation

qianjun1993
Copy link
Contributor

Signed-off-by: junqian junqian@tencent.com

What type of PR is this?
/kind feature

What this PR does / why we need it:

Which issue(s) this PR fixes:
Fixes First Four part of # 695

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

NONE

@karmada-bot karmada-bot added kind/feature Categorizes issue or PR as related to a new feature. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Sep 22, 2021
@kerthcet
Copy link
Member

refer to: #695 (comment)

@RainbowMango
Copy link
Member

Hi @qianjun1993
How do you test it? Can you post the metrics here?

@RainbowMango
Copy link
Member

RainbowMango commented Sep 22, 2021

I get it from my side:

All metrics
# curl localhost:10351/metrics
# HELP apiserver_audit_event_total [ALPHA] Counter of audit events generated and sent to the audit backend.
# TYPE apiserver_audit_event_total counter
apiserver_audit_event_total 0
# HELP apiserver_audit_requests_rejected_total [ALPHA] Counter of apiserver requests rejected due to an error in audit logging backend.
# TYPE apiserver_audit_requests_rejected_total counter
apiserver_audit_requests_rejected_total 0
# HELP apiserver_client_certificate_expiration_seconds [ALPHA] Distribution of the remaining lifetime on the certificate used to authenticate a request.
# TYPE apiserver_client_certificate_expiration_seconds histogram
apiserver_client_certificate_expiration_seconds_bucket{le="0"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="1800"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="3600"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="7200"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="21600"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="43200"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="86400"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="172800"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="345600"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="604800"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="2.592e+06"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="7.776e+06"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="1.5552e+07"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="3.1104e+07"} 0
apiserver_client_certificate_expiration_seconds_bucket{le="+Inf"} 0
apiserver_client_certificate_expiration_seconds_sum 0
apiserver_client_certificate_expiration_seconds_count 0
# HELP apiserver_storage_data_key_generation_duration_seconds [ALPHA] Latencies in seconds of data encryption key(DEK) generation operations.
# TYPE apiserver_storage_data_key_generation_duration_seconds histogram
apiserver_storage_data_key_generation_duration_seconds_bucket{le="5e-06"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="1e-05"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="2e-05"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="4e-05"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="8e-05"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.00016"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.00032"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.00064"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.00128"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.00256"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.00512"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.01024"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.02048"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="0.04096"} 0
apiserver_storage_data_key_generation_duration_seconds_bucket{le="+Inf"} 0
apiserver_storage_data_key_generation_duration_seconds_sum 0
apiserver_storage_data_key_generation_duration_seconds_count 0
# HELP apiserver_storage_data_key_generation_failures_total [ALPHA] Total number of failed data encryption key(DEK) generation operations.
# TYPE apiserver_storage_data_key_generation_failures_total counter
apiserver_storage_data_key_generation_failures_total 0
# HELP apiserver_storage_envelope_transformation_cache_misses_total [ALPHA] Total number of cache misses while accessing key decryption key(KEK).
# TYPE apiserver_storage_envelope_transformation_cache_misses_total counter
apiserver_storage_envelope_transformation_cache_misses_total 0
# HELP go_gc_duration_seconds A summary of the pause duration of garbage collection cycles.
# TYPE go_gc_duration_seconds summary
go_gc_duration_seconds{quantile="0"} 4.1643e-05
go_gc_duration_seconds{quantile="0.25"} 6.2032e-05
go_gc_duration_seconds{quantile="0.5"} 7.8924e-05
go_gc_duration_seconds{quantile="0.75"} 0.000126582
go_gc_duration_seconds{quantile="1"} 0.000544009
go_gc_duration_seconds_sum 0.001767746
go_gc_duration_seconds_count 15
# HELP go_goroutines Number of goroutines that currently exist.
# TYPE go_goroutines gauge
go_goroutines 57
# HELP go_info Information about the Go environment.
# TYPE go_info gauge
go_info{version="go1.16.7"} 1
# HELP go_memstats_alloc_bytes Number of bytes allocated and still in use.
# TYPE go_memstats_alloc_bytes gauge
go_memstats_alloc_bytes 6.590856e+06
# HELP go_memstats_alloc_bytes_total Total number of bytes allocated, even if freed.
# TYPE go_memstats_alloc_bytes_total counter
go_memstats_alloc_bytes_total 3.89742e+07
# HELP go_memstats_buck_hash_sys_bytes Number of bytes used by the profiling bucket hash table.
# TYPE go_memstats_buck_hash_sys_bytes gauge
go_memstats_buck_hash_sys_bytes 1.467964e+06
# HELP go_memstats_frees_total Total number of frees.
# TYPE go_memstats_frees_total counter
go_memstats_frees_total 387393
# HELP go_memstats_gc_cpu_fraction The fraction of this program's available CPU time used by the GC since the program started.
# TYPE go_memstats_gc_cpu_fraction gauge
go_memstats_gc_cpu_fraction 9.613305431255882e-06
# HELP go_memstats_gc_sys_bytes Number of bytes used for garbage collection system metadata.
# TYPE go_memstats_gc_sys_bytes gauge
go_memstats_gc_sys_bytes 5.58144e+06
# HELP go_memstats_heap_alloc_bytes Number of heap bytes allocated and still in use.
# TYPE go_memstats_heap_alloc_bytes gauge
go_memstats_heap_alloc_bytes 6.590856e+06
# HELP go_memstats_heap_idle_bytes Number of heap bytes waiting to be used.
# TYPE go_memstats_heap_idle_bytes gauge
go_memstats_heap_idle_bytes 5.7344e+07
# HELP go_memstats_heap_inuse_bytes Number of heap bytes that are in use.
# TYPE go_memstats_heap_inuse_bytes gauge
go_memstats_heap_inuse_bytes 8.880128e+06
# HELP go_memstats_heap_objects Number of allocated objects.
# TYPE go_memstats_heap_objects gauge
go_memstats_heap_objects 54850
# HELP go_memstats_heap_released_bytes Number of heap bytes released to OS.
# TYPE go_memstats_heap_released_bytes gauge
go_memstats_heap_released_bytes 5.6467456e+07
# HELP go_memstats_heap_sys_bytes Number of heap bytes obtained from system.
# TYPE go_memstats_heap_sys_bytes gauge
go_memstats_heap_sys_bytes 6.6224128e+07
# HELP go_memstats_last_gc_time_seconds Number of seconds since 1970 of last garbage collection.
# TYPE go_memstats_last_gc_time_seconds gauge
go_memstats_last_gc_time_seconds 1.6323118646324043e+09
# HELP go_memstats_lookups_total Total number of pointer lookups.
# TYPE go_memstats_lookups_total counter
go_memstats_lookups_total 0
# HELP go_memstats_mallocs_total Total number of mallocs.
# TYPE go_memstats_mallocs_total counter
go_memstats_mallocs_total 442243
# HELP go_memstats_mcache_inuse_bytes Number of bytes in use by mcache structures.
# TYPE go_memstats_mcache_inuse_bytes gauge
go_memstats_mcache_inuse_bytes 4800
# HELP go_memstats_mcache_sys_bytes Number of bytes used for mcache structures obtained from system.
# TYPE go_memstats_mcache_sys_bytes gauge
go_memstats_mcache_sys_bytes 16384
# HELP go_memstats_mspan_inuse_bytes Number of bytes in use by mspan structures.
# TYPE go_memstats_mspan_inuse_bytes gauge
go_memstats_mspan_inuse_bytes 140624
# HELP go_memstats_mspan_sys_bytes Number of bytes used for mspan structures obtained from system.
# TYPE go_memstats_mspan_sys_bytes gauge
go_memstats_mspan_sys_bytes 163840
# HELP go_memstats_next_gc_bytes Number of heap bytes when next garbage collection will take place.
# TYPE go_memstats_next_gc_bytes gauge
go_memstats_next_gc_bytes 8.826064e+06
# HELP go_memstats_other_sys_bytes Number of bytes used for other system allocations.
# TYPE go_memstats_other_sys_bytes gauge
go_memstats_other_sys_bytes 979788
# HELP go_memstats_stack_inuse_bytes Number of bytes in use by the stack allocator.
# TYPE go_memstats_stack_inuse_bytes gauge
go_memstats_stack_inuse_bytes 884736
# HELP go_memstats_stack_sys_bytes Number of bytes obtained from system for stack allocator.
# TYPE go_memstats_stack_sys_bytes gauge
go_memstats_stack_sys_bytes 884736
# HELP go_memstats_sys_bytes Number of bytes obtained from system.
# TYPE go_memstats_sys_bytes gauge
go_memstats_sys_bytes 7.531828e+07
# HELP go_threads Number of OS threads created.
# TYPE go_threads gauge
go_threads 9
# HELP karmada_scheduler_e2e_scheduling_duration_seconds [ALPHA] E2e scheduling latency in seconds
# TYPE karmada_scheduler_e2e_scheduling_duration_seconds histogram
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.001"} 0
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.002"} 0
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.004"} 0
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.008"} 0
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.016"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.032"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.064"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.128"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.256"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="0.512"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="1.024"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="2.048"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="4.096"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="8.192"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="16.384"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_bucket{result="scheduled",scheduleType="FirstSchedule",le="+Inf"} 1
karmada_scheduler_e2e_scheduling_duration_seconds_sum{result="scheduled",scheduleType="FirstSchedule"} 0.008659525
karmada_scheduler_e2e_scheduling_duration_seconds_count{result="scheduled",scheduleType="FirstSchedule"} 1
# HELP karmada_scheduler_queue_incoming_binding_total [ALPHA] Number of binding added to scheduling queues by event type.
# TYPE karmada_scheduler_queue_incoming_binding_total counter
karmada_scheduler_queue_incoming_binding_total{event="BindingAdd"} 1
karmada_scheduler_queue_incoming_binding_total{event="BindingUpdate"} 8
# HELP karmada_scheduler_schedule_attempts_total [ALPHA] Number of attempts to schedule resourceBinding
# TYPE karmada_scheduler_schedule_attempts_total counter
karmada_scheduler_schedule_attempts_total{result="scheduled",scheduleType="FirstSchedule"} 1
# HELP karmada_scheduler_scheduling_algorithm_duration_seconds [ALPHA] Scheduling algorithm latency in seconds(exclude scale scheduler)
# TYPE karmada_scheduler_scheduling_algorithm_duration_seconds histogram
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.001"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.002"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.004"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.008"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.016"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.032"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.064"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.128"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.256"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="0.512"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="1.024"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="2.048"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="4.096"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="8.192"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="16.384"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="AssignReplicas",le="+Inf"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_sum{scheduleStep="AssignReplicas"} 4.743e-06
karmada_scheduler_scheduling_algorithm_duration_seconds_count{scheduleStep="AssignReplicas"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.001"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.002"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.004"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.008"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.016"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.032"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.064"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.128"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.256"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="0.512"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="1.024"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="2.048"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="4.096"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="8.192"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="16.384"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Filter",le="+Inf"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_sum{scheduleStep="Filter"} 3.1025e-05
karmada_scheduler_scheduling_algorithm_duration_seconds_count{scheduleStep="Filter"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.001"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.002"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.004"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.008"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.016"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.032"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.064"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.128"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.256"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="0.512"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="1.024"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="2.048"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="4.096"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="8.192"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="16.384"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Score",le="+Inf"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_sum{scheduleStep="Score"} 5.913e-06
karmada_scheduler_scheduling_algorithm_duration_seconds_count{scheduleStep="Score"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.001"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.002"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.004"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.008"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.016"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.032"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.064"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.128"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.256"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="0.512"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="1.024"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="2.048"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="4.096"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="8.192"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="16.384"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_bucket{scheduleStep="Select",le="+Inf"} 1
karmada_scheduler_scheduling_algorithm_duration_seconds_sum{scheduleStep="Select"} 1.687e-06
karmada_scheduler_scheduling_algorithm_duration_seconds_count{scheduleStep="Select"} 1
# HELP process_cpu_seconds_total Total user and system CPU time spent in seconds.
# TYPE process_cpu_seconds_total counter
process_cpu_seconds_total 0.94
# HELP process_max_fds Maximum number of open file descriptors.
# TYPE process_max_fds gauge
process_max_fds 1.048576e+06
# HELP process_open_fds Number of open file descriptors.
# TYPE process_open_fds gauge
process_open_fds 11
# HELP process_resident_memory_bytes Resident memory size in bytes.
# TYPE process_resident_memory_bytes gauge
process_resident_memory_bytes 2.8422144e+07
# HELP process_start_time_seconds Start time of the process since unix epoch in seconds.
# TYPE process_start_time_seconds gauge
process_start_time_seconds 1.63231072485e+09
# HELP process_virtual_memory_bytes Virtual memory size in bytes.
# TYPE process_virtual_memory_bytes gauge
process_virtual_memory_bytes 7.653376e+08
# HELP process_virtual_memory_max_bytes Maximum amount of virtual memory available in bytes.
# TYPE process_virtual_memory_max_bytes gauge
process_virtual_memory_max_bytes 1.8446744073709552e+19

@RainbowMango
Copy link
Member

I noticed you used the k8s.io/component-base/metrics, but I'm afraid we can't re-use it because we can't get the version info.
That means, if we use the framework to deprecate metrics, that won't work.

@qianjun1993 qianjun1993 force-pushed the metrics branch 2 times, most recently from 6f30d20 to 8ed7dcc Compare September 26, 2021 07:20
@RainbowMango
Copy link
Member

/assign
Thanks for your hard work!!

ClusterNotReady = "ClusterNotReady"
)

// BindingSchedule can records a scheduling attempt and the duration
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// BindingSchedule can records a scheduling attempt and the duration
// BindingSchedule can record a scheduling attempt and the duration

var err error
switch s.getScheduleType(key.(string)) {
case FirstSchedule:
err = s.scheduleOne(key.(string))
klog.Infof("Start scheduling binding(%s)", key.(string))
metrics.BindingSchedule("FirstSchedule", metrics.SinceInSeconds(start), err)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not use the const FirstSchedule, like string(FirstSchedule)?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

prometheus.CounterOpts{
Subsystem: SchedulerSubsystem,
Name: "queue_incoming_bindings_total",
Help: "Number of pods added to scheduling queues by event type.",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo: Number of pods.

scheduleAttempts.WithLabelValues(result, scheduleType).Inc()
}

// ScheduleStep can records each scheduling duration
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// ScheduleStep can records each scheduling duration
// ScheduleStep can record each scheduling step duration.

pkg/scheduler/metrics/metrics_record.go Show resolved Hide resolved
@RainbowMango
Copy link
Member

/lgtm

But please resolve the conflicts.

@karmada-bot karmada-bot added the lgtm Indicates that a PR is ready to be merged. label Sep 29, 2021
Signed-off-by: junqian <junqian@tencent.com>
@karmada-bot karmada-bot removed the lgtm Indicates that a PR is ready to be merged. label Sep 29, 2021
@RainbowMango
Copy link
Member

/lgtm
/approve

/hold
Please feel free to cancel the hold after all checks succeed.

@karmada-bot karmada-bot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm Indicates that a PR is ready to be merged. labels Sep 29, 2021
@RainbowMango RainbowMango added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 29, 2021
@karmada-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by: RainbowMango

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@RainbowMango
Copy link
Member

/hold cancel

@karmada-bot karmada-bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Sep 29, 2021
@karmada-bot karmada-bot merged commit a072055 into karmada-io:master Sep 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/feature Categorizes issue or PR as related to a new feature. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants