pgwatch v5 beta introduces a major update to the PostgreSQL monitoring tool, focusing on enhanced stability, new features, and modernization. Key highlights include:
Major Changes
Schema migration support for PostgreSQL sinks, module version bump to v5, and migration of the web UI from react-scripts to Vite for improved performance and build efficiency.
New Features
Added metrics like stat_statements_jit, new Grafana panels (e.g., "Tables with the oldest non-frozen xid" and "Total index size"), support for reverse proxies on different paths, and functions like admin.maintain_unique_sources() for PostgreSQL sinks. Also includes graceful fallback for local log parsing and a new testutil package.
Improvements
Enhanced dashboards (e.g., Index Overview, Health Check), deprecation of old Stats Statements dashboards, refactoring of recommendation metrics, and better handling of configurations and logs. Minimum retention interval set to 1 hour.
Bug Fixes
Resolved issues with panel queries, data races in Prometheus sink, source config updates, logging, and more. Fixed circular dependencies in config upgrades and improved partition creation logic.
This beta lays the groundwork for v5 with better scalability and user experience. For full details, see the changelog. Test thoroughly before production use!
What's Changed
[!]add schema migration support for PostgreSQL sinks, closes #1110 by @pashagolub in #1111[!]bump module version to v5 by @pashagolub in #1112[!]migrate webui fromreact-scriptsto Vite by @pashagolub in #1170[+]addadmin.maintain_unique_sources()to Postgres sink by @pashagolub in #1100[+]addstat_statements_jitmetric by @0xgouda in #1054[+]addTables with the oldest non-frozen xidpanel by @0xgouda in #1133[+]addTotal index sizepanel toHealth Checkdashboard by @0xgouda in #1115[+]add graceful fallback for local log parsing by @0xgouda in #1109[+]add newtestutilpackage by @0xgouda in #1064[+]add popup dialogs for large fields, closes #1051 by @0xgouda in #1096[+]add support for reverse proxies on a different path, closes #1049 by @pashagolub in #1063[+]allow sink schema upgrades without --metrics/--sources, fixes #1114 by @pashagolub in #1175[+]apply admin functions migrations for v5, fixes #1180 by @0xgouda in #1181[+]bumpactions/cachefrom 4 to 5 by @dependabot[bot] in #1074[+]bumpactions/download-artifactfrom 6 to 7 by @dependabot[bot] in #1076[+]bumpactions/upload-artifactfrom 5 to 6 by @dependabot[bot] in #1075[+]bumpdocker.io/postgresto v18 by @pashagolub in #1102[+]bumpgolang-jwt/jwt/v5from 5.3.0 to 5.3.1 by @dependabot[bot] in #1149[+]bumpgoogle.golang.org/grpcfrom 1.77.0 to 1.78.0 by @dependabot[bot] in #1095[+]bumpgoogle.golang.org/protobuffrom 1.36.10 to 1.36.11 by @dependabot[bot] in #1077[+]bumplodashfrom 4.17.21 to 4.17.23 in webui by @dependabot[bot] in #1139[+]bumpnode-forgefrom 1.3.1 to 1.3.2 by @dependabot[bot] in #1045[+]bumpshirou/gopsutil/v4from 4.25.10 to 4.25.11 by @dependabot[bot] in #1055[+]bumpshirou/gopsutil/v4from 4.25.11 to 4.25.12 by @dependabot[bot] in #1105[+]bumpshirou/gopsutil/v4from 4.25.12 to 4.26.1 by @dependabot[bot] in #1161[+]bumpsirupsen/logrusfrom 1.9.3 to 1.9.4 by @dependabot[bot] in #1124[+]bump go.etcd.io/etcd/client/v3 from 3.6.6 to 3.6.7 by @dependabot[bot] in #1080[+]bump Grafana image to v12.3 by @pashagolub in #1104[+]improveIndex overviewdashboard by @0xgouda in #1146[+]mentionAptinstallation option in docs. by @0xgouda in #1043[+]minor improvement toMissing Indexespanel by @0xgouda in #1129[+]more improvements toindex overviewdashboard by @0xgouda in #1154[*]allow Postgres sink schemas to exist before init/upgrade by @pashagolub in #1116[*]apply minimum retention interval to 1 hour by @pashagolub in #1052[*]deprecateStats Statements [Top|Visual|Search]dashboards by @0xgouda in #1131[*]don't remove\n \t \rmeta chars from query text by @0xgouda in #1142[*]ignore revive lintervar-namingwarning forapipackage by @pashagolub in #1069[*]improve Prometheus Health-check dashboard by @kmoppel in #1130[*]migrate all helpers totestutilby @0xgouda in #1071[*]monitor specified groups only, fixes #1093 by @0xgouda in #1163[*]move cache to Prometheus sink struct, closes #1176 by @abhijeetsharma200 in #1177[*]refactorreco_add_indexmetric by @0xgouda in #1117[*]refactorreco_drop_indexmetric by @0xgouda in #1121[*]relocate% DB Totalcolumn inQuery Performance Analysisdashboard by @0xgouda in #1066[*]remove redundantSource NamefromTables Overviewdashboard, fixes #1134 by @Mohamed-Elfardy in #1160[*]set lock_timeout via connection RuntimeParams instead of per-query transaction by @NikolayS in #1067[*]sort webui preset selection list and add descriptions, fixes #1050 by @pashagolub in #1172[*]usetestutilpackage in the main integration test by @pashagolub in #1101[-]add missing cybertec panels by @0xgouda in #1062[-]add missing newline inmetric print-sqloutput, fixes #1145 by @Abdelrhmansersawy in #1147[-]fixconfig upgradecircular dependency, closes #1156 by @pashagolub in #1171[-]fixDeleteOldPartitions()scheduling interval, fixes #1087 by @0xgouda in #1088[-]fixpgwatch_instance_upmetric for down sources, closes #1158 by @pashagolub in #1162[-]fix data race in Prometheus sink, fixes #1136 by @abhijeetsharma200 in #1140[-]fix error on using special chars in source names by @0xgouda in #1094[-]fix log parser to not re-read non-truncated files, fixes #1089 by @0xgouda in #1168[-]fix logging of cli options names by @0xgouda in #1178[-]fix panel queries inTable Detailsdashboard by @0xgouda in #1150[-]fix recommendation dashboard panel name by @0xgouda in #1060[-]fix source config update handling by @0xgouda in #1106[-]fix sql ofShared Buffers hit pctpanel by @0xgouda in #1058[-]migrate all panels inHealth Checkdashboard to table format by @0xgouda in #1057[-]only create time partitions if needed by @0xgouda in #1127[-]pinpgwatch-metricsdata source to all panels and vars. by @df7cb in #1053[-]pinpgwatch-metricsdata source to all v11 panels and vars by @0xgouda in #1056[-]remove deprecated db types from webui, fixes #1044 by @0xgouda in #1047[-]remove sqls for pre postgres 14 versions by @0xgouda in #1123
New Contributors
- @NikolayS made their first contribution in #1067
- @Abdelrhmansersawy made their first contribution in #1147
- @abhijeetsharma200 made their first contribution in #1140
- @Mohamed-Elfardy made their first contribution in #1160
Full Changelog: v4.1.0...v5.0.0-beta