dart_postgresql
dart_postgresql copied to clipboard
Implement metrics logging from Hikari
https://github.com/brettwooldridge/HikariCP/wiki/Codahale-Metrics
https://dropwizard.github.io/metrics/ http://graphite.readthedocs.org/en/latest/overview.html
Also log metrics to observatory:
https://api.dartlang.org/apidocs/channels/be/dartdoc-viewer/dart:profiler https://www.dartlang.org/tools/observatory/tags.html
If I get it clear we have this "MetricRegistry" and everything is logged there(nothing to the console), and we fetch it on demand ?
Not sure yet. This is ticket is a note to self for me to do some research.
Perhaps I will do something like this:
Adding this to pool:
Stream<Metric> metrics;
class Metric {
String name;
num value;
DateTime time;
}
Another library can then be used to push these metrics into collectd, graphite or observatory. Standard system monitory tools can then be used to view realtime graphs, and set up alert emails/sms if connection times reach some threshold.
https://github.com/a14n/dart-metrics