@oneuptime/common 11.0.0 → 11.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (357) hide show
  1. package/Models/DatabaseModels/Alert.ts +110 -0
  2. package/Models/DatabaseModels/CephCluster.ts +964 -0
  3. package/Models/DatabaseModels/CephClusterLabelRule.ts +514 -0
  4. package/Models/DatabaseModels/CephClusterOwnerRule.ts +596 -0
  5. package/Models/DatabaseModels/CephClusterOwnerTeam.ts +487 -0
  6. package/Models/DatabaseModels/CephClusterOwnerUser.ts +486 -0
  7. package/Models/DatabaseModels/CephResource.ts +809 -0
  8. package/Models/DatabaseModels/Host.ts +64 -0
  9. package/Models/DatabaseModels/Incident.ts +110 -0
  10. package/Models/DatabaseModels/Index.ts +24 -0
  11. package/Models/DatabaseModels/ProxmoxCluster.ts +943 -0
  12. package/Models/DatabaseModels/ProxmoxClusterLabelRule.ts +514 -0
  13. package/Models/DatabaseModels/ProxmoxClusterOwnerRule.ts +596 -0
  14. package/Models/DatabaseModels/ProxmoxClusterOwnerTeam.ts +487 -0
  15. package/Models/DatabaseModels/ProxmoxClusterOwnerUser.ts +486 -0
  16. package/Models/DatabaseModels/ProxmoxResource.ts +726 -0
  17. package/Models/DatabaseModels/ScheduledMaintenance.ts +110 -0
  18. package/Server/API/BillingInvoiceAPI.ts +47 -7
  19. package/Server/API/CephResourceAPI.ts +134 -0
  20. package/Server/API/DashboardAPI.ts +46 -0
  21. package/Server/API/ProjectAPI.ts +15 -0
  22. package/Server/API/ProxmoxResourceAPI.ts +132 -0
  23. package/Server/API/ResellerPlanAPI.ts +17 -0
  24. package/Server/Infrastructure/GlobalCache.ts +8 -2
  25. package/Server/Infrastructure/Postgres/SchemaMigrations/1781500000000-AddProxmoxAndCephClusterTables.ts +163 -0
  26. package/Server/Infrastructure/Postgres/SchemaMigrations/1781600000000-AddProxmoxCephV2Columns.ts +211 -0
  27. package/Server/Infrastructure/Postgres/SchemaMigrations/1781600000001-AddProxmoxCephActivityAndRules.ts +590 -0
  28. package/Server/Infrastructure/Postgres/SchemaMigrations/1781700000000-AddProxmoxCephV3Columns.ts +64 -0
  29. package/Server/Infrastructure/Postgres/SchemaMigrations/Index.ts +8 -0
  30. package/Server/Infrastructure/Redis.ts +40 -12
  31. package/Server/Services/AnalyticsDatabaseService.ts +1 -1
  32. package/Server/Services/BillingService.ts +109 -21
  33. package/Server/Services/CephClusterLabelRuleEngineService.ts +200 -0
  34. package/Server/Services/CephClusterLabelRuleService.ts +14 -0
  35. package/Server/Services/CephClusterOwnerRuleEngineService.ts +218 -0
  36. package/Server/Services/CephClusterOwnerRuleService.ts +14 -0
  37. package/Server/Services/CephClusterOwnerTeamService.ts +10 -0
  38. package/Server/Services/CephClusterOwnerUserService.ts +10 -0
  39. package/Server/Services/CephClusterService.ts +401 -0
  40. package/Server/Services/CephResourceService.ts +383 -0
  41. package/Server/Services/CloudResourceService.ts +11 -3
  42. package/Server/Services/DockerHostService.ts +11 -3
  43. package/Server/Services/ExceptionAggregationService.ts +2 -0
  44. package/Server/Services/HostService.ts +11 -3
  45. package/Server/Services/Index.ts +24 -0
  46. package/Server/Services/KubernetesClusterService.ts +11 -3
  47. package/Server/Services/LogAggregationService.ts +2 -0
  48. package/Server/Services/MetricAggregationService.ts +2 -0
  49. package/Server/Services/OpenTelemetryIngestService.ts +36 -0
  50. package/Server/Services/ProxmoxClusterLabelRuleEngineService.ts +204 -0
  51. package/Server/Services/ProxmoxClusterLabelRuleService.ts +14 -0
  52. package/Server/Services/ProxmoxClusterOwnerRuleEngineService.ts +222 -0
  53. package/Server/Services/ProxmoxClusterOwnerRuleService.ts +14 -0
  54. package/Server/Services/ProxmoxClusterOwnerTeamService.ts +10 -0
  55. package/Server/Services/ProxmoxClusterOwnerUserService.ts +10 -0
  56. package/Server/Services/ProxmoxClusterService.ts +382 -0
  57. package/Server/Services/ProxmoxResourceService.ts +404 -0
  58. package/Server/Services/RumApplicationService.ts +11 -3
  59. package/Server/Services/ServerlessFunctionService.ts +11 -3
  60. package/Server/Services/TelemetryUsageBillingService.ts +41 -3
  61. package/Server/Services/TraceAggregationService.ts +2 -0
  62. package/Server/Types/AnalyticsDatabase/AggregateBy.ts +8 -23
  63. package/Server/Utils/Monitor/MonitorAlert.ts +45 -0
  64. package/Server/Utils/Monitor/MonitorClusterContext.ts +129 -0
  65. package/Server/Utils/Monitor/MonitorCriteriaEvaluator.ts +344 -4
  66. package/Server/Utils/Monitor/MonitorIncident.ts +130 -7
  67. package/Server/Utils/Monitor/MonitorMaintenanceSuppression.ts +39 -6
  68. package/Server/Utils/Monitor/MonitorTemplateUtil.ts +3 -1
  69. package/Server/Utils/Monitor/SeriesResourceLabels.ts +33 -0
  70. package/Server/Utils/Profiling.ts +37 -2
  71. package/Server/Utils/Telemetry/EntityRegistry.ts +4 -0
  72. package/Server/Utils/Telemetry/ProxmoxCephSnapshotScan.ts +1096 -0
  73. package/Server/Utils/Telemetry/TelemetryEntity.ts +85 -0
  74. package/Server/Utils/Telemetry.ts +8 -19
  75. package/Tests/Server/API/BillingInvoiceAPI.test.ts +194 -0
  76. package/Tests/Server/API/ProjectAPI.test.ts +91 -0
  77. package/Tests/Server/API/ResellerPlanAPI.test.ts +207 -0
  78. package/Tests/Server/Infrastructure/GlobalCache.test.ts +100 -0
  79. package/Tests/Server/Services/BillingService.test.ts +323 -0
  80. package/Tests/Server/Services/CephResourceService.test.ts +264 -0
  81. package/Tests/Server/Services/ProxmoxResourceService.test.ts +326 -0
  82. package/Tests/Server/Utils/Monitor/MonitorCriteriaEvaluator.test.ts +322 -0
  83. package/Tests/Server/Utils/Monitor/MonitorMaintenanceSuppression.test.ts +13 -0
  84. package/Tests/Server/Utils/Telemetry/ProxmoxCephSnapshotScan.test.ts +879 -0
  85. package/Tests/Server/Utils/Telemetry/TelemetryEntity.test.ts +196 -0
  86. package/Tests/Types/Monitor/CephAlertTemplates.test.ts +1231 -0
  87. package/Tests/Types/Monitor/ProxmoxAlertTemplates.test.ts +732 -0
  88. package/Tests/Utils/ModelImportExport.test.ts +366 -0
  89. package/Tests/Utils/Telemetry/EntityRelationship.test.ts +49 -0
  90. package/Tests/Utils/Telemetry/HeartbeatAvailability.test.ts +423 -0
  91. package/Types/BaseDatabase/AggregationIntervalUtil.ts +74 -0
  92. package/Types/Dashboard/DashboardComponentType.ts +4 -0
  93. package/Types/Dashboard/DashboardComponents/ComponentArgument.ts +2 -0
  94. package/Types/Dashboard/DashboardComponents/DashboardCephOsdListComponent.ts +15 -0
  95. package/Types/Dashboard/DashboardComponents/DashboardCephPoolListComponent.ts +14 -0
  96. package/Types/Dashboard/DashboardComponents/DashboardProxmoxGuestListComponent.ts +17 -0
  97. package/Types/Dashboard/DashboardComponents/DashboardProxmoxNodeListComponent.ts +16 -0
  98. package/Types/Dashboard/DashboardTemplates.ts +446 -0
  99. package/Types/Icon/IconProp.ts +2 -0
  100. package/Types/Monitor/CephAlertTemplates.ts +1647 -0
  101. package/Types/Monitor/CephMetricCatalog.ts +409 -0
  102. package/Types/Monitor/MetricMonitor/MetricMonitorResponse.ts +44 -0
  103. package/Types/Monitor/MonitorStep.ts +64 -0
  104. package/Types/Monitor/MonitorStepCephMonitor.ts +57 -0
  105. package/Types/Monitor/MonitorStepProxmoxMonitor.ts +81 -0
  106. package/Types/Monitor/MonitorType.ts +29 -1
  107. package/Types/Monitor/ProxmoxAlertTemplates.ts +899 -0
  108. package/Types/Monitor/ProxmoxMetricCatalog.ts +382 -0
  109. package/Types/Permission.ts +464 -0
  110. package/Types/Telemetry/EntityType.ts +11 -0
  111. package/Types/Telemetry/ServiceType.ts +2 -0
  112. package/UI/Components/Icon/Icon.tsx +84 -0
  113. package/UI/Components/ImportExport/ExportModelCard.tsx +90 -0
  114. package/UI/Components/ImportExport/ImportModelsModal.tsx +239 -0
  115. package/UI/Components/ModelTable/ModelTable.tsx +294 -143
  116. package/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.ts +9 -5
  117. package/UI/Utils/ModelImportExport.ts +207 -0
  118. package/UI/Utils/Telemetry/Telemetry.ts +16 -21
  119. package/UI/Utils/TelemetryService.ts +7 -3
  120. package/Utils/Dashboard/Components/DashboardCephOsdListComponent.ts +63 -0
  121. package/Utils/Dashboard/Components/DashboardCephPoolListComponent.ts +32 -0
  122. package/Utils/Dashboard/Components/DashboardCephResourceListShared.ts +61 -0
  123. package/Utils/Dashboard/Components/DashboardProxmoxGuestListComponent.ts +69 -0
  124. package/Utils/Dashboard/Components/DashboardProxmoxNodeListComponent.ts +55 -0
  125. package/Utils/Dashboard/Components/DashboardProxmoxResourceListShared.ts +61 -0
  126. package/Utils/Dashboard/Components/Index.ts +28 -0
  127. package/Utils/ModelImportExport.ts +369 -0
  128. package/Utils/Telemetry/EntityKey.ts +35 -0
  129. package/Utils/Telemetry/EntityRelationship.ts +6 -0
  130. package/Utils/Telemetry/HeartbeatAvailability.ts +262 -0
  131. package/build/dist/Models/DatabaseModels/Alert.js +108 -0
  132. package/build/dist/Models/DatabaseModels/Alert.js.map +1 -1
  133. package/build/dist/Models/DatabaseModels/CephCluster.js +992 -0
  134. package/build/dist/Models/DatabaseModels/CephCluster.js.map +1 -0
  135. package/build/dist/Models/DatabaseModels/CephClusterLabelRule.js +522 -0
  136. package/build/dist/Models/DatabaseModels/CephClusterLabelRule.js.map +1 -0
  137. package/build/dist/Models/DatabaseModels/CephClusterOwnerRule.js +603 -0
  138. package/build/dist/Models/DatabaseModels/CephClusterOwnerRule.js.map +1 -0
  139. package/build/dist/Models/DatabaseModels/CephClusterOwnerTeam.js +503 -0
  140. package/build/dist/Models/DatabaseModels/CephClusterOwnerTeam.js.map +1 -0
  141. package/build/dist/Models/DatabaseModels/CephClusterOwnerUser.js +502 -0
  142. package/build/dist/Models/DatabaseModels/CephClusterOwnerUser.js.map +1 -0
  143. package/build/dist/Models/DatabaseModels/CephResource.js +846 -0
  144. package/build/dist/Models/DatabaseModels/CephResource.js.map +1 -0
  145. package/build/dist/Models/DatabaseModels/Host.js +63 -0
  146. package/build/dist/Models/DatabaseModels/Host.js.map +1 -1
  147. package/build/dist/Models/DatabaseModels/Incident.js +108 -0
  148. package/build/dist/Models/DatabaseModels/Incident.js.map +1 -1
  149. package/build/dist/Models/DatabaseModels/Index.js +24 -0
  150. package/build/dist/Models/DatabaseModels/Index.js.map +1 -1
  151. package/build/dist/Models/DatabaseModels/ProxmoxCluster.js +967 -0
  152. package/build/dist/Models/DatabaseModels/ProxmoxCluster.js.map +1 -0
  153. package/build/dist/Models/DatabaseModels/ProxmoxClusterLabelRule.js +522 -0
  154. package/build/dist/Models/DatabaseModels/ProxmoxClusterLabelRule.js.map +1 -0
  155. package/build/dist/Models/DatabaseModels/ProxmoxClusterOwnerRule.js +603 -0
  156. package/build/dist/Models/DatabaseModels/ProxmoxClusterOwnerRule.js.map +1 -0
  157. package/build/dist/Models/DatabaseModels/ProxmoxClusterOwnerTeam.js +503 -0
  158. package/build/dist/Models/DatabaseModels/ProxmoxClusterOwnerTeam.js.map +1 -0
  159. package/build/dist/Models/DatabaseModels/ProxmoxClusterOwnerUser.js +502 -0
  160. package/build/dist/Models/DatabaseModels/ProxmoxClusterOwnerUser.js.map +1 -0
  161. package/build/dist/Models/DatabaseModels/ProxmoxResource.js +761 -0
  162. package/build/dist/Models/DatabaseModels/ProxmoxResource.js.map +1 -0
  163. package/build/dist/Models/DatabaseModels/ScheduledMaintenance.js +108 -0
  164. package/build/dist/Models/DatabaseModels/ScheduledMaintenance.js.map +1 -1
  165. package/build/dist/Server/API/BillingInvoiceAPI.js +35 -5
  166. package/build/dist/Server/API/BillingInvoiceAPI.js.map +1 -1
  167. package/build/dist/Server/API/CephResourceAPI.js +98 -0
  168. package/build/dist/Server/API/CephResourceAPI.js.map +1 -0
  169. package/build/dist/Server/API/DashboardAPI.js +46 -0
  170. package/build/dist/Server/API/DashboardAPI.js.map +1 -1
  171. package/build/dist/Server/API/ProjectAPI.js +11 -0
  172. package/build/dist/Server/API/ProjectAPI.js.map +1 -1
  173. package/build/dist/Server/API/ProxmoxResourceAPI.js +95 -0
  174. package/build/dist/Server/API/ProxmoxResourceAPI.js.map +1 -0
  175. package/build/dist/Server/API/ResellerPlanAPI.js +17 -3
  176. package/build/dist/Server/API/ResellerPlanAPI.js.map +1 -1
  177. package/build/dist/Server/Infrastructure/GlobalCache.js +7 -2
  178. package/build/dist/Server/Infrastructure/GlobalCache.js.map +1 -1
  179. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781500000000-AddProxmoxAndCephClusterTables.js +76 -0
  180. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781500000000-AddProxmoxAndCephClusterTables.js.map +1 -0
  181. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781600000000-AddProxmoxCephV2Columns.js +108 -0
  182. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781600000000-AddProxmoxCephV2Columns.js.map +1 -0
  183. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781600000001-AddProxmoxCephActivityAndRules.js +253 -0
  184. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781600000001-AddProxmoxCephActivityAndRules.js.map +1 -0
  185. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781700000000-AddProxmoxCephV3Columns.js +43 -0
  186. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1781700000000-AddProxmoxCephV3Columns.js.map +1 -0
  187. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js +8 -0
  188. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js.map +1 -1
  189. package/build/dist/Server/Infrastructure/Redis.js +31 -8
  190. package/build/dist/Server/Infrastructure/Redis.js.map +1 -1
  191. package/build/dist/Server/Services/AnalyticsDatabaseService.js +1 -1
  192. package/build/dist/Server/Services/AnalyticsDatabaseService.js.map +1 -1
  193. package/build/dist/Server/Services/BillingService.js +85 -23
  194. package/build/dist/Server/Services/BillingService.js.map +1 -1
  195. package/build/dist/Server/Services/CephClusterLabelRuleEngineService.js +166 -0
  196. package/build/dist/Server/Services/CephClusterLabelRuleEngineService.js.map +1 -0
  197. package/build/dist/Server/Services/CephClusterLabelRuleService.js +13 -0
  198. package/build/dist/Server/Services/CephClusterLabelRuleService.js.map +1 -0
  199. package/build/dist/Server/Services/CephClusterOwnerRuleEngineService.js +186 -0
  200. package/build/dist/Server/Services/CephClusterOwnerRuleEngineService.js.map +1 -0
  201. package/build/dist/Server/Services/CephClusterOwnerRuleService.js +13 -0
  202. package/build/dist/Server/Services/CephClusterOwnerRuleService.js.map +1 -0
  203. package/build/dist/Server/Services/CephClusterOwnerTeamService.js +9 -0
  204. package/build/dist/Server/Services/CephClusterOwnerTeamService.js.map +1 -0
  205. package/build/dist/Server/Services/CephClusterOwnerUserService.js +9 -0
  206. package/build/dist/Server/Services/CephClusterOwnerUserService.js.map +1 -0
  207. package/build/dist/Server/Services/CephClusterService.js +353 -0
  208. package/build/dist/Server/Services/CephClusterService.js.map +1 -0
  209. package/build/dist/Server/Services/CephResourceService.js +257 -0
  210. package/build/dist/Server/Services/CephResourceService.js.map +1 -0
  211. package/build/dist/Server/Services/CloudResourceService.js +10 -2
  212. package/build/dist/Server/Services/CloudResourceService.js.map +1 -1
  213. package/build/dist/Server/Services/DockerHostService.js +10 -2
  214. package/build/dist/Server/Services/DockerHostService.js.map +1 -1
  215. package/build/dist/Server/Services/ExceptionAggregationService.js +2 -0
  216. package/build/dist/Server/Services/ExceptionAggregationService.js.map +1 -1
  217. package/build/dist/Server/Services/HostService.js +10 -2
  218. package/build/dist/Server/Services/HostService.js.map +1 -1
  219. package/build/dist/Server/Services/Index.js +24 -0
  220. package/build/dist/Server/Services/Index.js.map +1 -1
  221. package/build/dist/Server/Services/KubernetesClusterService.js +10 -2
  222. package/build/dist/Server/Services/KubernetesClusterService.js.map +1 -1
  223. package/build/dist/Server/Services/LogAggregationService.js +2 -0
  224. package/build/dist/Server/Services/LogAggregationService.js.map +1 -1
  225. package/build/dist/Server/Services/MetricAggregationService.js +2 -0
  226. package/build/dist/Server/Services/MetricAggregationService.js.map +1 -1
  227. package/build/dist/Server/Services/OpenTelemetryIngestService.js +37 -7
  228. package/build/dist/Server/Services/OpenTelemetryIngestService.js.map +1 -1
  229. package/build/dist/Server/Services/ProxmoxClusterLabelRuleEngineService.js +166 -0
  230. package/build/dist/Server/Services/ProxmoxClusterLabelRuleEngineService.js.map +1 -0
  231. package/build/dist/Server/Services/ProxmoxClusterLabelRuleService.js +13 -0
  232. package/build/dist/Server/Services/ProxmoxClusterLabelRuleService.js.map +1 -0
  233. package/build/dist/Server/Services/ProxmoxClusterOwnerRuleEngineService.js +186 -0
  234. package/build/dist/Server/Services/ProxmoxClusterOwnerRuleEngineService.js.map +1 -0
  235. package/build/dist/Server/Services/ProxmoxClusterOwnerRuleService.js +13 -0
  236. package/build/dist/Server/Services/ProxmoxClusterOwnerRuleService.js.map +1 -0
  237. package/build/dist/Server/Services/ProxmoxClusterOwnerTeamService.js +9 -0
  238. package/build/dist/Server/Services/ProxmoxClusterOwnerTeamService.js.map +1 -0
  239. package/build/dist/Server/Services/ProxmoxClusterOwnerUserService.js +9 -0
  240. package/build/dist/Server/Services/ProxmoxClusterOwnerUserService.js.map +1 -0
  241. package/build/dist/Server/Services/ProxmoxClusterService.js +337 -0
  242. package/build/dist/Server/Services/ProxmoxClusterService.js.map +1 -0
  243. package/build/dist/Server/Services/ProxmoxResourceService.js +285 -0
  244. package/build/dist/Server/Services/ProxmoxResourceService.js.map +1 -0
  245. package/build/dist/Server/Services/RumApplicationService.js +10 -2
  246. package/build/dist/Server/Services/RumApplicationService.js.map +1 -1
  247. package/build/dist/Server/Services/ServerlessFunctionService.js +10 -2
  248. package/build/dist/Server/Services/ServerlessFunctionService.js.map +1 -1
  249. package/build/dist/Server/Services/TelemetryUsageBillingService.js +30 -3
  250. package/build/dist/Server/Services/TelemetryUsageBillingService.js.map +1 -1
  251. package/build/dist/Server/Services/TraceAggregationService.js +2 -0
  252. package/build/dist/Server/Services/TraceAggregationService.js.map +1 -1
  253. package/build/dist/Server/Types/AnalyticsDatabase/AggregateBy.js +8 -25
  254. package/build/dist/Server/Types/AnalyticsDatabase/AggregateBy.js.map +1 -1
  255. package/build/dist/Server/Utils/Monitor/MonitorAlert.js +36 -0
  256. package/build/dist/Server/Utils/Monitor/MonitorAlert.js.map +1 -1
  257. package/build/dist/Server/Utils/Monitor/MonitorClusterContext.js +90 -0
  258. package/build/dist/Server/Utils/Monitor/MonitorClusterContext.js.map +1 -0
  259. package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js +228 -4
  260. package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js.map +1 -1
  261. package/build/dist/Server/Utils/Monitor/MonitorIncident.js +103 -8
  262. package/build/dist/Server/Utils/Monitor/MonitorIncident.js.map +1 -1
  263. package/build/dist/Server/Utils/Monitor/MonitorMaintenanceSuppression.js +23 -6
  264. package/build/dist/Server/Utils/Monitor/MonitorMaintenanceSuppression.js.map +1 -1
  265. package/build/dist/Server/Utils/Monitor/MonitorTemplateUtil.js +3 -1
  266. package/build/dist/Server/Utils/Monitor/MonitorTemplateUtil.js.map +1 -1
  267. package/build/dist/Server/Utils/Monitor/SeriesResourceLabels.js +23 -0
  268. package/build/dist/Server/Utils/Monitor/SeriesResourceLabels.js.map +1 -1
  269. package/build/dist/Server/Utils/Profiling.js +24 -3
  270. package/build/dist/Server/Utils/Profiling.js.map +1 -1
  271. package/build/dist/Server/Utils/Telemetry/EntityRegistry.js +4 -0
  272. package/build/dist/Server/Utils/Telemetry/EntityRegistry.js.map +1 -1
  273. package/build/dist/Server/Utils/Telemetry/ProxmoxCephSnapshotScan.js +854 -0
  274. package/build/dist/Server/Utils/Telemetry/ProxmoxCephSnapshotScan.js.map +1 -0
  275. package/build/dist/Server/Utils/Telemetry/TelemetryEntity.js +62 -0
  276. package/build/dist/Server/Utils/Telemetry/TelemetryEntity.js.map +1 -1
  277. package/build/dist/Server/Utils/Telemetry.js +8 -10
  278. package/build/dist/Server/Utils/Telemetry.js.map +1 -1
  279. package/build/dist/Types/BaseDatabase/AggregationIntervalUtil.js +69 -0
  280. package/build/dist/Types/BaseDatabase/AggregationIntervalUtil.js.map +1 -0
  281. package/build/dist/Types/Dashboard/DashboardComponentType.js +4 -0
  282. package/build/dist/Types/Dashboard/DashboardComponentType.js.map +1 -1
  283. package/build/dist/Types/Dashboard/DashboardComponents/ComponentArgument.js +2 -0
  284. package/build/dist/Types/Dashboard/DashboardComponents/ComponentArgument.js.map +1 -1
  285. package/build/dist/Types/Dashboard/DashboardComponents/DashboardCephOsdListComponent.js +2 -0
  286. package/build/dist/Types/Dashboard/DashboardComponents/DashboardCephOsdListComponent.js.map +1 -0
  287. package/build/dist/Types/Dashboard/DashboardComponents/DashboardCephPoolListComponent.js +2 -0
  288. package/build/dist/Types/Dashboard/DashboardComponents/DashboardCephPoolListComponent.js.map +1 -0
  289. package/build/dist/Types/Dashboard/DashboardComponents/DashboardProxmoxGuestListComponent.js +2 -0
  290. package/build/dist/Types/Dashboard/DashboardComponents/DashboardProxmoxGuestListComponent.js.map +1 -0
  291. package/build/dist/Types/Dashboard/DashboardComponents/DashboardProxmoxNodeListComponent.js +2 -0
  292. package/build/dist/Types/Dashboard/DashboardComponents/DashboardProxmoxNodeListComponent.js.map +1 -0
  293. package/build/dist/Types/Dashboard/DashboardTemplates.js +394 -0
  294. package/build/dist/Types/Dashboard/DashboardTemplates.js.map +1 -1
  295. package/build/dist/Types/Icon/IconProp.js +2 -0
  296. package/build/dist/Types/Icon/IconProp.js.map +1 -1
  297. package/build/dist/Types/Monitor/CephAlertTemplates.js +1379 -0
  298. package/build/dist/Types/Monitor/CephAlertTemplates.js.map +1 -0
  299. package/build/dist/Types/Monitor/CephMetricCatalog.js +353 -0
  300. package/build/dist/Types/Monitor/CephMetricCatalog.js.map +1 -0
  301. package/build/dist/Types/Monitor/MonitorStep.js +46 -0
  302. package/build/dist/Types/Monitor/MonitorStep.js.map +1 -1
  303. package/build/dist/Types/Monitor/MonitorStepCephMonitor.js +34 -0
  304. package/build/dist/Types/Monitor/MonitorStepCephMonitor.js.map +1 -0
  305. package/build/dist/Types/Monitor/MonitorStepProxmoxMonitor.js +36 -0
  306. package/build/dist/Types/Monitor/MonitorStepProxmoxMonitor.js.map +1 -0
  307. package/build/dist/Types/Monitor/MonitorType.js +27 -1
  308. package/build/dist/Types/Monitor/MonitorType.js.map +1 -1
  309. package/build/dist/Types/Monitor/ProxmoxAlertTemplates.js +743 -0
  310. package/build/dist/Types/Monitor/ProxmoxAlertTemplates.js.map +1 -0
  311. package/build/dist/Types/Monitor/ProxmoxMetricCatalog.js +320 -0
  312. package/build/dist/Types/Monitor/ProxmoxMetricCatalog.js.map +1 -0
  313. package/build/dist/Types/Permission.js +408 -0
  314. package/build/dist/Types/Permission.js.map +1 -1
  315. package/build/dist/Types/Telemetry/EntityType.js +11 -0
  316. package/build/dist/Types/Telemetry/EntityType.js.map +1 -1
  317. package/build/dist/Types/Telemetry/ServiceType.js +2 -0
  318. package/build/dist/Types/Telemetry/ServiceType.js.map +1 -1
  319. package/build/dist/UI/Components/Icon/Icon.js +33 -0
  320. package/build/dist/UI/Components/Icon/Icon.js.map +1 -1
  321. package/build/dist/UI/Components/ImportExport/ExportModelCard.js +50 -0
  322. package/build/dist/UI/Components/ImportExport/ExportModelCard.js.map +1 -0
  323. package/build/dist/UI/Components/ImportExport/ImportModelsModal.js +115 -0
  324. package/build/dist/UI/Components/ImportExport/ImportModelsModal.js.map +1 -0
  325. package/build/dist/UI/Components/ModelTable/ModelTable.js +166 -74
  326. package/build/dist/UI/Components/ModelTable/ModelTable.js.map +1 -1
  327. package/build/dist/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.js +5 -1
  328. package/build/dist/UI/Components/MonitorTemplateVariables/TemplateVariablesCatalog.js.map +1 -1
  329. package/build/dist/UI/Utils/ModelImportExport.js +142 -0
  330. package/build/dist/UI/Utils/ModelImportExport.js.map +1 -0
  331. package/build/dist/UI/Utils/Telemetry/Telemetry.js +11 -10
  332. package/build/dist/UI/Utils/Telemetry/Telemetry.js.map +1 -1
  333. package/build/dist/UI/Utils/TelemetryService.js +5 -2
  334. package/build/dist/UI/Utils/TelemetryService.js.map +1 -1
  335. package/build/dist/Utils/Dashboard/Components/DashboardCephOsdListComponent.js +50 -0
  336. package/build/dist/Utils/Dashboard/Components/DashboardCephOsdListComponent.js.map +1 -0
  337. package/build/dist/Utils/Dashboard/Components/DashboardCephPoolListComponent.js +27 -0
  338. package/build/dist/Utils/Dashboard/Components/DashboardCephPoolListComponent.js.map +1 -0
  339. package/build/dist/Utils/Dashboard/Components/DashboardCephResourceListShared.js +46 -0
  340. package/build/dist/Utils/Dashboard/Components/DashboardCephResourceListShared.js.map +1 -0
  341. package/build/dist/Utils/Dashboard/Components/DashboardProxmoxGuestListComponent.js +55 -0
  342. package/build/dist/Utils/Dashboard/Components/DashboardProxmoxGuestListComponent.js.map +1 -0
  343. package/build/dist/Utils/Dashboard/Components/DashboardProxmoxNodeListComponent.js +42 -0
  344. package/build/dist/Utils/Dashboard/Components/DashboardProxmoxNodeListComponent.js.map +1 -0
  345. package/build/dist/Utils/Dashboard/Components/DashboardProxmoxResourceListShared.js +46 -0
  346. package/build/dist/Utils/Dashboard/Components/DashboardProxmoxResourceListShared.js.map +1 -0
  347. package/build/dist/Utils/Dashboard/Components/Index.js +16 -0
  348. package/build/dist/Utils/Dashboard/Components/Index.js.map +1 -1
  349. package/build/dist/Utils/ModelImportExport.js +257 -0
  350. package/build/dist/Utils/ModelImportExport.js.map +1 -0
  351. package/build/dist/Utils/Telemetry/EntityKey.js +27 -0
  352. package/build/dist/Utils/Telemetry/EntityKey.js.map +1 -1
  353. package/build/dist/Utils/Telemetry/EntityRelationship.js +3 -0
  354. package/build/dist/Utils/Telemetry/EntityRelationship.js.map +1 -1
  355. package/build/dist/Utils/Telemetry/HeartbeatAvailability.js +174 -0
  356. package/build/dist/Utils/Telemetry/HeartbeatAvailability.js.map +1 -0
  357. package/package.json +29 -21
@@ -0,0 +1,382 @@
1
+ import { ProxmoxResourceScope } from "./MonitorStepProxmoxMonitor";
2
+ import MetricsAggregationType from "../Metrics/MetricsAggregationType";
3
+
4
+ export type ProxmoxMetricCategory =
5
+ | "Availability"
6
+ | "Node"
7
+ | "Guest"
8
+ | "Storage"
9
+ | "HA"
10
+ | "Backup"
11
+ | "Replication";
12
+
13
+ export interface ProxmoxMetricDefinition {
14
+ id: string;
15
+ friendlyName: string;
16
+ description: string;
17
+ metricName: string;
18
+ category: ProxmoxMetricCategory;
19
+ defaultAggregation: MetricsAggregationType;
20
+ defaultResourceScope: ProxmoxResourceScope;
21
+ unit?: string;
22
+ }
23
+
24
+ /*
25
+ * Metric names follow the prometheus-pve-exporter naming scheme. Each series
26
+ * carries an `id` datapoint label identifying the Proxmox resource it belongs
27
+ * to: `node/<name>` for nodes, `qemu/<vmid>` for VMs, `lxc/<vmid>` for
28
+ * containers, and `storage/<storage>` for storage volumes. The agent's OTTL
29
+ * transform additionally stamps `pve.scope` (node | guest | storage |
30
+ * cluster), `pve.type` (node | qemu | lxc | storage) and `pve.id` (the part
31
+ * after the slash) as datapoint attributes — `defaultResourceScope` is the
32
+ * `pve.scope` value the metric is usually filtered to (Cluster = spans
33
+ * multiple scopes; don't pre-filter).
34
+ */
35
+ const proxmoxMetricCatalog: Array<ProxmoxMetricDefinition> = [
36
+ // Availability Metrics
37
+ {
38
+ id: "pve-up",
39
+ friendlyName: "Resource Up",
40
+ description:
41
+ "Whether a Proxmox resource is up (1) or down/stopped (0). Reported for nodes and guests — filter on pve.scope (node/guest) or the id label to scope.",
42
+ metricName: "pve_up",
43
+ category: "Availability",
44
+ defaultAggregation: MetricsAggregationType.Min,
45
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
46
+ },
47
+ {
48
+ id: "pve-uptime-seconds",
49
+ friendlyName: "Uptime",
50
+ description:
51
+ "How long a node or guest has been running. Drops to zero when the resource is stopped or rebooted.",
52
+ metricName: "pve_uptime_seconds",
53
+ category: "Availability",
54
+ defaultAggregation: MetricsAggregationType.Max,
55
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
56
+ unit: "seconds",
57
+ },
58
+ {
59
+ id: "pve-version-info",
60
+ friendlyName: "PVE Version Info",
61
+ description:
62
+ "Metadata series carrying the Proxmox VE release in its version/release labels (value is always 1).",
63
+ metricName: "pve_version_info",
64
+ category: "Availability",
65
+ defaultAggregation: MetricsAggregationType.Max,
66
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
67
+ unit: "count",
68
+ },
69
+
70
+ // Node Metrics
71
+ {
72
+ id: "pve-cpu-usage-ratio",
73
+ friendlyName: "CPU Usage Ratio",
74
+ description:
75
+ "CPU usage as a ratio of available CPU (0 to 1, where 1 = all cores fully used). Reported for nodes and guests — filter on pve.scope to pick one.",
76
+ metricName: "pve_cpu_usage_ratio",
77
+ category: "Node",
78
+ defaultAggregation: MetricsAggregationType.Avg,
79
+ defaultResourceScope: ProxmoxResourceScope.Node,
80
+ unit: "ratio",
81
+ },
82
+ {
83
+ id: "pve-cpu-usage-limit",
84
+ friendlyName: "CPU Limit (Cores)",
85
+ description:
86
+ "Maximum CPU available to a node or guest, in cores. For guests this is the number of allocated vCPUs.",
87
+ metricName: "pve_cpu_usage_limit",
88
+ category: "Node",
89
+ defaultAggregation: MetricsAggregationType.Max,
90
+ defaultResourceScope: ProxmoxResourceScope.Node,
91
+ unit: "cores",
92
+ },
93
+ {
94
+ id: "pve-memory-usage-bytes",
95
+ friendlyName: "Memory Usage",
96
+ description:
97
+ "Memory currently in use by a node or guest. Compare against Memory Size to gauge memory pressure.",
98
+ metricName: "pve_memory_usage_bytes",
99
+ category: "Node",
100
+ defaultAggregation: MetricsAggregationType.Avg,
101
+ defaultResourceScope: ProxmoxResourceScope.Node,
102
+ unit: "bytes",
103
+ },
104
+ {
105
+ id: "pve-memory-size-bytes",
106
+ friendlyName: "Memory Size",
107
+ description:
108
+ "Total memory available to a node or guest. For guests this is the configured memory allocation.",
109
+ metricName: "pve_memory_size_bytes",
110
+ category: "Node",
111
+ defaultAggregation: MetricsAggregationType.Max,
112
+ defaultResourceScope: ProxmoxResourceScope.Node,
113
+ unit: "bytes",
114
+ },
115
+ {
116
+ id: "pve-node-info",
117
+ friendlyName: "Node Info",
118
+ description:
119
+ "Metadata series for each Proxmox node (value is always 1) carrying the node's name label. Sum it to count the nodes reporting in the cluster.",
120
+ metricName: "pve_node_info",
121
+ category: "Node",
122
+ defaultAggregation: MetricsAggregationType.Sum,
123
+ defaultResourceScope: ProxmoxResourceScope.Node,
124
+ unit: "count",
125
+ },
126
+
127
+ // Guest Metrics
128
+ {
129
+ id: "pve-network-receive-bytes",
130
+ friendlyName: "Network Received",
131
+ description:
132
+ "Cumulative bytes received over the network by a guest (VM or container). Chart as a rate to see throughput.",
133
+ metricName: "pve_network_receive_bytes",
134
+ category: "Guest",
135
+ defaultAggregation: MetricsAggregationType.Sum,
136
+ defaultResourceScope: ProxmoxResourceScope.Guest,
137
+ unit: "bytes",
138
+ },
139
+ {
140
+ id: "pve-network-transmit-bytes",
141
+ friendlyName: "Network Transmitted",
142
+ description:
143
+ "Cumulative bytes transmitted over the network by a guest (VM or container). Chart as a rate to see throughput.",
144
+ metricName: "pve_network_transmit_bytes",
145
+ category: "Guest",
146
+ defaultAggregation: MetricsAggregationType.Sum,
147
+ defaultResourceScope: ProxmoxResourceScope.Guest,
148
+ unit: "bytes",
149
+ },
150
+ {
151
+ id: "pve-disk-read-bytes",
152
+ friendlyName: "Disk Read",
153
+ description:
154
+ "Cumulative bytes read from disk by a guest (VM or container). Chart as a rate to see read throughput.",
155
+ metricName: "pve_disk_read_bytes",
156
+ category: "Guest",
157
+ defaultAggregation: MetricsAggregationType.Sum,
158
+ defaultResourceScope: ProxmoxResourceScope.Guest,
159
+ unit: "bytes",
160
+ },
161
+ {
162
+ id: "pve-disk-write-bytes",
163
+ friendlyName: "Disk Write",
164
+ description:
165
+ "Cumulative bytes written to disk by a guest (VM or container). Chart as a rate to see write throughput.",
166
+ metricName: "pve_disk_write_bytes",
167
+ category: "Guest",
168
+ defaultAggregation: MetricsAggregationType.Sum,
169
+ defaultResourceScope: ProxmoxResourceScope.Guest,
170
+ unit: "bytes",
171
+ },
172
+ {
173
+ id: "pve-guest-info",
174
+ friendlyName: "Guest Info",
175
+ description:
176
+ "Metadata series for each guest (value is always 1) carrying name, node, and type labels. Sum it to count guests in the cluster.",
177
+ metricName: "pve_guest_info",
178
+ category: "Guest",
179
+ defaultAggregation: MetricsAggregationType.Sum,
180
+ defaultResourceScope: ProxmoxResourceScope.Guest,
181
+ unit: "count",
182
+ },
183
+ {
184
+ id: "pve-onboot-status",
185
+ friendlyName: "Start-on-Boot Status",
186
+ description:
187
+ "Whether a guest is configured to start on node boot (1) or not (0). A stopped guest with onboot=1 is usually unintended downtime.",
188
+ metricName: "pve_onboot_status",
189
+ category: "Guest",
190
+ defaultAggregation: MetricsAggregationType.Min,
191
+ defaultResourceScope: ProxmoxResourceScope.Guest,
192
+ unit: "count",
193
+ },
194
+
195
+ // Storage Metrics
196
+ {
197
+ id: "pve-disk-usage-bytes",
198
+ friendlyName: "Disk Usage",
199
+ description:
200
+ "Disk space currently used. Reported for storage volumes, node root filesystems, and guest root disks — filter on pve.scope to pick one. For QEMU guests this reads 0 unless the QEMU guest agent is installed.",
201
+ metricName: "pve_disk_usage_bytes",
202
+ category: "Storage",
203
+ defaultAggregation: MetricsAggregationType.Avg,
204
+ defaultResourceScope: ProxmoxResourceScope.Storage,
205
+ unit: "bytes",
206
+ },
207
+ {
208
+ id: "pve-disk-size-bytes",
209
+ friendlyName: "Disk Size",
210
+ description:
211
+ "Total disk space available on a storage volume, node root filesystem, or guest root disk.",
212
+ metricName: "pve_disk_size_bytes",
213
+ category: "Storage",
214
+ defaultAggregation: MetricsAggregationType.Max,
215
+ defaultResourceScope: ProxmoxResourceScope.Storage,
216
+ unit: "bytes",
217
+ },
218
+ {
219
+ id: "pve-storage-info",
220
+ friendlyName: "Storage Info",
221
+ description:
222
+ "Metadata series for each storage volume (value is always 1) carrying node and storage labels. Sum it to count storage volumes in the cluster.",
223
+ metricName: "pve_storage_info",
224
+ category: "Storage",
225
+ defaultAggregation: MetricsAggregationType.Sum,
226
+ defaultResourceScope: ProxmoxResourceScope.Storage,
227
+ unit: "count",
228
+ },
229
+
230
+ // HA Metrics
231
+ {
232
+ id: "pve-ha-state",
233
+ friendlyName: "HA State",
234
+ description:
235
+ "High-availability state of a node or guest as an enum-style series: one series per possible state (e.g. started, stopped, error) with value 1 for the current state. Filter on the state label to alert on specific states.",
236
+ metricName: "pve_ha_state",
237
+ category: "HA",
238
+ defaultAggregation: MetricsAggregationType.Max,
239
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
240
+ },
241
+
242
+ /*
243
+ * Backup Metrics — cluster-level backup-info collector (default-on).
244
+ * These report backup-JOB coverage only: whether backups ran
245
+ * recently or succeeded is not exposed by pve-exporter.
246
+ */
247
+ {
248
+ id: "pve-not-backed-up-total",
249
+ friendlyName: "Guests Without Backup",
250
+ description:
251
+ "Count of guests (VMs and containers) not covered by ANY backup job. A single cluster-level series with no id label. Covers backup-job membership only — not whether backups ran recently or succeeded.",
252
+ metricName: "pve_not_backed_up_total",
253
+ category: "Backup",
254
+ defaultAggregation: MetricsAggregationType.Max,
255
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
256
+ unit: "count",
257
+ },
258
+ {
259
+ id: "pve-not-backed-up-info",
260
+ friendlyName: "Guest Without Backup Info",
261
+ description:
262
+ "Metadata series present for each guest NOT covered by any backup job (value is always 1), labeled only with the guest's id. Group by id to list the uncovered guests; the series disappears once the guest joins a backup job.",
263
+ metricName: "pve_not_backed_up_info",
264
+ category: "Backup",
265
+ defaultAggregation: MetricsAggregationType.Max,
266
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
267
+ unit: "count",
268
+ },
269
+
270
+ /*
271
+ * Replication Metrics — node-level replication collector
272
+ * (default-on). Series carry the replication JOB id in the `id`
273
+ * label (e.g. 100-0), not a node/qemu/lxc-prefixed resource id;
274
+ * pve_replication_info additionally carries type, source, target
275
+ * and guest labels.
276
+ */
277
+ {
278
+ id: "pve-replication-failed-syncs",
279
+ friendlyName: "Replication Failed Syncs",
280
+ description:
281
+ "Number of consecutive failed sync attempts for a storage replication job. Anything above 0 means the job's replica is going stale — group by id to alert per job.",
282
+ metricName: "pve_replication_failed_syncs",
283
+ category: "Replication",
284
+ defaultAggregation: MetricsAggregationType.Max,
285
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
286
+ unit: "count",
287
+ },
288
+ {
289
+ id: "pve-replication-duration-seconds",
290
+ friendlyName: "Replication Duration",
291
+ description:
292
+ "How long a replication job's last sync took. A rising duration usually means growing deltas or a slow/congested target.",
293
+ metricName: "pve_replication_duration_seconds",
294
+ category: "Replication",
295
+ defaultAggregation: MetricsAggregationType.Max,
296
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
297
+ unit: "seconds",
298
+ },
299
+ {
300
+ id: "pve-replication-last-sync-timestamp-seconds",
301
+ friendlyName: "Replication Last Sync",
302
+ description:
303
+ "Unix timestamp of a replication job's last SUCCESSFUL sync. Compare against the current time to gauge replica staleness (the criteria engine has no wall-clock math, so staleness is a chart/UI concern, not an alert).",
304
+ metricName: "pve_replication_last_sync_timestamp_seconds",
305
+ category: "Replication",
306
+ defaultAggregation: MetricsAggregationType.Max,
307
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
308
+ unit: "seconds",
309
+ },
310
+ {
311
+ id: "pve-replication-last-try-timestamp-seconds",
312
+ friendlyName: "Replication Last Try",
313
+ description:
314
+ "Unix timestamp of a replication job's last sync ATTEMPT. A last-try newer than last-sync means the most recent attempt failed.",
315
+ metricName: "pve_replication_last_try_timestamp_seconds",
316
+ category: "Replication",
317
+ defaultAggregation: MetricsAggregationType.Max,
318
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
319
+ unit: "seconds",
320
+ },
321
+ {
322
+ id: "pve-replication-next-sync-timestamp-seconds",
323
+ friendlyName: "Replication Next Sync",
324
+ description: "Unix timestamp of a replication job's next scheduled sync.",
325
+ metricName: "pve_replication_next_sync_timestamp_seconds",
326
+ category: "Replication",
327
+ defaultAggregation: MetricsAggregationType.Max,
328
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
329
+ unit: "seconds",
330
+ },
331
+ {
332
+ id: "pve-replication-info",
333
+ friendlyName: "Replication Info",
334
+ description:
335
+ "Metadata series for each storage replication job (value is always 1) carrying type, source, target and guest labels. Sum it to count replication jobs; join its labels to map a job id to the guest and node pair it replicates.",
336
+ metricName: "pve_replication_info",
337
+ category: "Replication",
338
+ defaultAggregation: MetricsAggregationType.Sum,
339
+ defaultResourceScope: ProxmoxResourceScope.Cluster,
340
+ unit: "count",
341
+ },
342
+ ];
343
+
344
+ export function getAllProxmoxMetrics(): Array<ProxmoxMetricDefinition> {
345
+ return proxmoxMetricCatalog;
346
+ }
347
+
348
+ export function getProxmoxMetricsByCategory(
349
+ category: ProxmoxMetricCategory,
350
+ ): Array<ProxmoxMetricDefinition> {
351
+ return proxmoxMetricCatalog.filter((m: ProxmoxMetricDefinition) => {
352
+ return m.category === category;
353
+ });
354
+ }
355
+
356
+ export function getProxmoxMetricById(
357
+ id: string,
358
+ ): ProxmoxMetricDefinition | undefined {
359
+ return proxmoxMetricCatalog.find((m: ProxmoxMetricDefinition) => {
360
+ return m.id === id;
361
+ });
362
+ }
363
+
364
+ export function getProxmoxMetricByMetricName(
365
+ metricName: string,
366
+ ): ProxmoxMetricDefinition | undefined {
367
+ return proxmoxMetricCatalog.find((m: ProxmoxMetricDefinition) => {
368
+ return m.metricName === metricName;
369
+ });
370
+ }
371
+
372
+ export function getAllProxmoxMetricCategories(): Array<ProxmoxMetricCategory> {
373
+ return [
374
+ "Availability",
375
+ "Node",
376
+ "Guest",
377
+ "Storage",
378
+ "HA",
379
+ "Backup",
380
+ "Replication",
381
+ ];
382
+ }