-
Notifications
You must be signed in to change notification settings - Fork 9
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 from Tinkoff libvirt exporter #63
base: master
Are you sure you want to change the base?
Conversation
Thanks for the contribution @Dmitry-Eremeev
Thank you |
|
||
// https://libvirt.org/html/libvirt-libvirt-domain.html#virConnectGetAllDomainStats | ||
if domainsBlockStats, err = l.ConnectGetAllDomainStats(domains, uint32(libvirt.DomainStatsBlock), 0); err != nil { | ||
_ = level.Warn(logger).Log("warn", "failed to get additional block stats", "domain", domain.libvirtDomain.Name, "msg", err) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change to the new std logging system
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
statsIndex := "0" | ||
var capacity, flushRequests, flushTimes, readTime, writeTime uint64 | ||
var prometheusDiskLabels []string | ||
StatName := regexp.MustCompile(`block\.(\d+)\.(.+)`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible to extract the regex in a static variable so the regex is not compiled on every function call
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Added metrics from archived Tinkoff exporter: libvirt_domain_block_stats_read_time_seconds_total libvirt_domain_block_stats_write_time_seconds_total libvirt_domain_block_stats_flush_requests_total libvirt_domain_block_stats_flush_time_seconds_total libvirt_domain_block_stats_capacity_bytes libvirt_domain_memory_stats_used_percent libvirt_domain_memory_stats_actual_balloon_bytes libvirt_domain_memory_stats_major_fault_total libvirt_domain_memory_stats_minor_fault_total inovex#22
d1078b3
to
f5fab14
Compare
done
it's already there
|
Added metrics from archived Tinkoff exporter:
libvirt_domain_block_stats_read_time_seconds_total
libvirt_domain_block_stats_write_time_seconds_total
libvirt_domain_block_stats_flush_requests_total
libvirt_domain_block_stats_flush_time_seconds_total
libvirt_domain_block_stats_capacity_bytes
libvirt_domain_memory_stats_used_percent
libvirt_domain_memory_stats_actual_balloon_bytes
libvirt_domain_memory_stats_major_fault_total
libvirt_domain_memory_stats_minor_fault_total
#22