@oneuptime/common 14.0.110 → 14.2.0

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 (527) hide show
  1. package/Models/DatabaseModels/AIRunRecording.d.mts +12 -0
  2. package/Models/DatabaseModels/AIRunRecording.d.ts +12 -0
  3. package/Models/DatabaseModels/AIRunRecording.js +181 -0
  4. package/Models/DatabaseModels/AIRunRecording.mjs +2 -0
  5. package/Models/DatabaseModels/Alert.d.mts +1 -0
  6. package/Models/DatabaseModels/Alert.d.ts +1 -0
  7. package/Models/DatabaseModels/Alert.js +52 -2
  8. package/Models/DatabaseModels/AutoRemediationSuggestion.d.mts +2 -0
  9. package/Models/DatabaseModels/AutoRemediationSuggestion.d.ts +2 -0
  10. package/Models/DatabaseModels/AutoRemediationSuggestion.js +62 -0
  11. package/Models/DatabaseModels/DataStore.js +9 -0
  12. package/Models/DatabaseModels/EmailLog.js +2 -2
  13. package/Models/DatabaseModels/Form.js +3 -3
  14. package/Models/DatabaseModels/FormSubmission.js +4 -4
  15. package/Models/DatabaseModels/GlobalConfig.js +46 -45
  16. package/Models/DatabaseModels/Incident.d.mts +1 -0
  17. package/Models/DatabaseModels/Incident.d.ts +1 -0
  18. package/Models/DatabaseModels/Incident.js +53 -2
  19. package/Models/DatabaseModels/IncidentPostmortemActionItem.d.mts +31 -0
  20. package/Models/DatabaseModels/IncidentPostmortemActionItem.d.ts +31 -0
  21. package/Models/DatabaseModels/IncidentPostmortemActionItem.js +591 -0
  22. package/Models/DatabaseModels/IncidentPostmortemActionItem.mjs +3 -0
  23. package/Models/DatabaseModels/IncidentSlaRule.js +2 -2
  24. package/Models/DatabaseModels/Index.js +6 -0
  25. package/Models/DatabaseModels/InventoryItem.js +11 -0
  26. package/Models/DatabaseModels/Monitor.js +51 -17
  27. package/Models/DatabaseModels/MonitorNetworkDevice.d.mts +11 -0
  28. package/Models/DatabaseModels/MonitorNetworkDevice.d.ts +11 -0
  29. package/Models/DatabaseModels/MonitorNetworkDevice.js +189 -0
  30. package/Models/DatabaseModels/MonitorNetworkDevice.mjs +2 -0
  31. package/Models/DatabaseModels/MonitorProbe.js +22 -5
  32. package/Models/DatabaseModels/NetworkDevice.js +23 -7
  33. package/Models/DatabaseModels/NetworkEndpoint.d.mts +1 -0
  34. package/Models/DatabaseModels/NetworkEndpoint.d.ts +1 -0
  35. package/Models/DatabaseModels/NetworkEndpoint.js +39 -7
  36. package/Models/DatabaseModels/NetworkInterface.js +5 -5
  37. package/Models/DatabaseModels/OnCallDutyPolicyExecutionLog.js +19 -5
  38. package/Models/DatabaseModels/OnCallDutyPolicyFeed.d.mts +1 -0
  39. package/Models/DatabaseModels/OnCallDutyPolicyFeed.d.ts +1 -0
  40. package/Models/DatabaseModels/OnCallDutyPolicyFeed.js +2 -0
  41. package/Models/DatabaseModels/OnCallDutyPolicyUserOverride.js +35 -7
  42. package/Models/DatabaseModels/OpenStackCloudCheck.js +8 -1
  43. package/Models/DatabaseModels/Project.d.mts +1 -0
  44. package/Models/DatabaseModels/Project.d.ts +1 -0
  45. package/Models/DatabaseModels/Project.js +46 -3
  46. package/Models/DatabaseModels/ProjectCallSMSConfig.js +3 -1
  47. package/Models/DatabaseModels/ProjectSmtpConfig.js +2 -0
  48. package/Models/DatabaseModels/PublicNoteApprovalRequest.js +3 -3
  49. package/Models/DatabaseModels/PublicNoteApprovalStep.js +1 -1
  50. package/Models/DatabaseModels/RunbookExecution.js +2 -2
  51. package/Models/DatabaseModels/RunbookRule.js +6 -6
  52. package/Models/DatabaseModels/ScheduledMaintenance.js +3 -3
  53. package/Models/DatabaseModels/ScheduledMaintenanceCalendarFeed.js +1 -1
  54. package/Models/DatabaseModels/ScheduledMaintenanceLabelRule.js +1 -1
  55. package/Models/DatabaseModels/ScheduledMaintenanceMeasurement.js +7 -7
  56. package/Models/DatabaseModels/ScheduledMaintenanceMeasurementValue.js +1 -1
  57. package/Models/DatabaseModels/ScheduledMaintenanceOwnerRule.js +6 -6
  58. package/Models/DatabaseModels/ScheduledMaintenanceOwnerTeam.js +4 -4
  59. package/Models/DatabaseModels/ScheduledMaintenanceOwnerUser.js +4 -4
  60. package/Models/DatabaseModels/ScheduledMaintenancePublicNote.js +3 -3
  61. package/Models/DatabaseModels/ScheduledMaintenanceReminderRule.js +4 -4
  62. package/Models/DatabaseModels/ScheduledMaintenanceStateTimeline.js +3 -3
  63. package/Models/DatabaseModels/ScheduledMaintenanceTemplate.js +5 -5
  64. package/Models/DatabaseModels/TeamMember.js +10 -1
  65. package/Models/DatabaseModels/TelemetryIngestionKey.js +1 -1
  66. package/Models/DatabaseModels/WorkspaceNotificationRule.js +36 -1
  67. package/Models/DatabaseModels/WorkspaceNotificationSummary.js +1 -1
  68. package/Models/DatabaseModels/WorkspacePublicNoteApprovalMessage.js +3 -3
  69. package/Server/Services/DatabaseService.d.mts +4 -1
  70. package/Server/Services/DatabaseService.d.ts +4 -1
  71. package/Server/Types/Database/CountBy.d.mts +1 -0
  72. package/Server/Types/Database/CountBy.d.ts +1 -0
  73. package/Server/Types/Database/UpdateLimit.d.mts +6 -0
  74. package/Server/Types/Database/UpdateLimit.d.ts +6 -0
  75. package/Types/AI/AIActionWords.d.mts +28 -2
  76. package/Types/AI/AIActionWords.d.ts +28 -2
  77. package/Types/AI/AIActionWords.js +235 -3
  78. package/Types/AI/AIActionWords.mjs +8 -0
  79. package/Types/AI/AIChatTypes.d.mts +3 -1
  80. package/Types/AI/AIChatTypes.d.ts +3 -1
  81. package/Types/AI/AIReadTableWords.d.mts +192 -0
  82. package/Types/AI/AIReadTableWords.d.ts +192 -0
  83. package/Types/AI/AIReadTableWords.js +368 -0
  84. package/Types/AI/AIReadTableWords.mjs +18 -0
  85. package/Types/AI/AiOutcomes.d.mts +57 -0
  86. package/Types/AI/AiOutcomes.d.ts +57 -0
  87. package/Types/AI/AiOutcomes.js +67 -0
  88. package/Types/AI/AiOutcomes.mjs +10 -0
  89. package/Types/AI/AiRunRefusal.d.mts +48 -0
  90. package/Types/AI/AiRunRefusal.d.ts +48 -0
  91. package/Types/AI/AiRunRefusal.js +208 -0
  92. package/Types/AI/AiRunRefusal.mjs +12 -0
  93. package/Types/AI/InvestigationRecording.d.mts +46 -0
  94. package/Types/AI/InvestigationRecording.d.ts +46 -0
  95. package/Types/AI/InvestigationRecording.js +42 -0
  96. package/Types/AI/InvestigationRecording.mjs +7 -0
  97. package/Types/AI/ResourceAiAccessPermissions.js +7 -18
  98. package/Types/API/HTTPResponse.d.mts +3 -0
  99. package/Types/API/HTTPResponse.d.ts +3 -0
  100. package/Types/API/HTTPResponse.js +15 -0
  101. package/Types/AuditLog/AuditLogActionLabel.js +19 -9
  102. package/Types/BaseDatabase/AggregateBy.d.mts +16 -0
  103. package/Types/BaseDatabase/AggregateBy.d.ts +16 -0
  104. package/Types/BaseDatabase/AggregationIntervalUtil.d.mts +32 -1
  105. package/Types/BaseDatabase/AggregationIntervalUtil.d.ts +32 -1
  106. package/Types/BaseDatabase/AggregationIntervalUtil.js +199 -2
  107. package/Types/BaseDatabase/ListResult.d.mts +1 -0
  108. package/Types/BaseDatabase/ListResult.d.ts +1 -0
  109. package/Types/CallAndSMS/ServerTwilioEnvironment.d.mts +47 -0
  110. package/Types/CallAndSMS/ServerTwilioEnvironment.d.ts +47 -0
  111. package/Types/CallAndSMS/ServerTwilioEnvironment.js +282 -0
  112. package/Types/CallAndSMS/ServerTwilioEnvironment.mjs +7 -0
  113. package/Types/Cloud/CloudResourceHealth.d.mts +30 -1
  114. package/Types/Cloud/CloudResourceHealth.d.ts +30 -1
  115. package/Types/Cloud/CloudResourceHealth.js +405 -13
  116. package/Types/Cloud/CloudResourceHealth.mjs +28 -0
  117. package/Types/Dashboard/DashboardAutoRefresh.d.mts +1 -0
  118. package/Types/Dashboard/DashboardAutoRefresh.d.ts +1 -0
  119. package/Types/Dashboard/DashboardAutoRefresh.js +21 -0
  120. package/Types/Dashboard/DashboardAutoRefresh.mjs +1 -0
  121. package/Types/DataObservability/DataCheckRefusals.d.mts +32 -0
  122. package/Types/DataObservability/DataCheckRefusals.d.ts +32 -0
  123. package/Types/DataObservability/DataCheckRefusals.js +77 -0
  124. package/Types/DataObservability/DataCheckRefusals.mjs +8 -0
  125. package/Types/Database/AccessControl/PermissionScopeNarrowing.js +4 -0
  126. package/Types/Date.d.mts +8 -1
  127. package/Types/Date.d.ts +8 -1
  128. package/Types/Date.js +61 -7
  129. package/Types/Date.mjs +1 -0
  130. package/Types/DateLanguage.d.mts +2 -0
  131. package/Types/DateLanguage.d.ts +2 -0
  132. package/Types/DateLanguage.js +8 -5
  133. package/Types/Email/EmailTemplateType.d.mts +1 -0
  134. package/Types/Email/EmailTemplateType.d.ts +1 -0
  135. package/Types/Email/EmailTemplateType.js +2 -0
  136. package/Types/Email/ServerEmailEnvironment.d.mts +85 -0
  137. package/Types/Email/ServerEmailEnvironment.d.ts +85 -0
  138. package/Types/Email/ServerEmailEnvironment.js +793 -0
  139. package/Types/Email/ServerEmailEnvironment.mjs +14 -0
  140. package/Types/Exception/AiRunRefusalException.d.mts +6 -0
  141. package/Types/Exception/AiRunRefusalException.d.ts +6 -0
  142. package/Types/Exception/AiRunRefusalException.js +23 -0
  143. package/Types/Exception/AiRunRefusalException.mjs +2 -0
  144. package/Types/Exception/EgressGuardException.js +1 -1
  145. package/Types/Exception/ErrorMessageRule.d.mts +1 -0
  146. package/Types/Exception/ErrorMessageRule.d.ts +1 -0
  147. package/Types/Exception/ErrorMessageRule.js +67 -13
  148. package/Types/Exception/ErrorMessageRule.mjs +1 -0
  149. package/Types/Exception/ExceptionMessages.d.mts +2 -0
  150. package/Types/Exception/ExceptionMessages.d.ts +2 -0
  151. package/Types/Exception/ExceptionMessages.js +2 -0
  152. package/Types/Form/FormTargetCatalog.js +2 -2
  153. package/Types/Form/FormTargetType.js +2 -2
  154. package/Types/Incident/PostmortemActionItemStatus.d.mts +17 -0
  155. package/Types/Incident/PostmortemActionItemStatus.d.ts +17 -0
  156. package/Types/Incident/PostmortemActionItemStatus.js +74 -0
  157. package/Types/Incident/PostmortemActionItemStatus.mjs +5 -0
  158. package/Types/JSONFunctions.js +10 -3
  159. package/Types/Link.d.mts +1 -0
  160. package/Types/Link.d.ts +1 -0
  161. package/Types/ListData.d.mts +2 -0
  162. package/Types/ListData.d.ts +2 -0
  163. package/Types/ListData.js +4 -0
  164. package/Types/MeaningKeys.d.mts +4 -0
  165. package/Types/MeaningKeys.d.ts +4 -0
  166. package/Types/MeaningKeys.js +74 -0
  167. package/Types/MeaningKeys.mjs +5 -0
  168. package/Types/Monitor/MonitorCriteriaInstance.js +9 -0
  169. package/Types/Monitor/MonitorNotCheckedReason.d.mts +7 -0
  170. package/Types/Monitor/MonitorNotCheckedReason.d.ts +7 -0
  171. package/Types/Monitor/MonitorNotCheckedReason.js +36 -0
  172. package/Types/Monitor/MonitorNotCheckedReason.mjs +4 -0
  173. package/Types/Monitor/SnmpMonitor/NetworkTopology.d.mts +6 -0
  174. package/Types/Monitor/SnmpMonitor/NetworkTopology.d.ts +6 -0
  175. package/Types/Monitor/UptimeHistoryLabels.js +2 -2
  176. package/Types/Monitor/WhoIsTold.d.mts +3 -0
  177. package/Types/Monitor/WhoIsTold.d.ts +3 -0
  178. package/Types/Monitor/WhoIsTold.js +63 -13
  179. package/Types/NoBreakSpaces.d.mts +16 -0
  180. package/Types/NoBreakSpaces.d.ts +16 -0
  181. package/Types/NoBreakSpaces.js +419 -0
  182. package/Types/NoBreakSpaces.mjs +9 -0
  183. package/Types/NotificationRule/PagingLadder.d.mts +12 -0
  184. package/Types/NotificationRule/PagingLadder.d.ts +12 -0
  185. package/Types/NotificationRule/PagingLadder.js +159 -11
  186. package/Types/NotificationRule/PagingLadder.mjs +3 -0
  187. package/Types/OnCallDutyPolicy/GlobalUserOverrideAccess.d.mts +1 -0
  188. package/Types/OnCallDutyPolicy/GlobalUserOverrideAccess.d.ts +1 -0
  189. package/Types/OnCallDutyPolicy/GlobalUserOverrideAccess.js +12 -9
  190. package/Types/OnCallDutyPolicy/GlobalUserOverrideAccess.mjs +1 -0
  191. package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.d.mts +3 -1
  192. package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.d.ts +3 -1
  193. package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.js +24 -6
  194. package/Types/OnCallDutyPolicy/OnCallAcknowledgePage.mjs +1 -0
  195. package/Types/OnCallDutyPolicy/OnCallPagePassOn.d.mts +1 -0
  196. package/Types/OnCallDutyPolicy/OnCallPagePassOn.d.ts +1 -0
  197. package/Types/OnCallDutyPolicy/OnCallPageRecordGone.d.mts +3 -0
  198. package/Types/OnCallDutyPolicy/OnCallPageRecordGone.d.ts +3 -0
  199. package/Types/OnCallDutyPolicy/OnCallPageRecordGone.js +42 -0
  200. package/Types/OnCallDutyPolicy/OnCallPageRecordGone.mjs +4 -0
  201. package/Types/OnCallDutyPolicy/OnCallPageWords.d.mts +6 -2
  202. package/Types/OnCallDutyPolicy/OnCallPageWords.d.ts +6 -2
  203. package/Types/OnCallDutyPolicy/OnCallPageWords.js +21 -20
  204. package/Types/OnCallDutyPolicy/OnCallPersonPage.d.mts +4 -0
  205. package/Types/OnCallDutyPolicy/OnCallPersonPage.d.ts +4 -0
  206. package/Types/OnCallDutyPolicy/OnCallPersonPage.js +125 -1
  207. package/Types/OnCallDutyPolicy/OnCallPersonPage.mjs +1 -0
  208. package/Types/OnCallDutyPolicy/OnCallPolicyStartedByHand.d.mts +12 -0
  209. package/Types/OnCallDutyPolicy/OnCallPolicyStartedByHand.d.ts +12 -0
  210. package/Types/OnCallDutyPolicy/OnCallPolicyStartedByHand.js +38 -0
  211. package/Types/OnCallDutyPolicy/OnCallPolicyStartedByHand.mjs +3 -0
  212. package/Types/OnCallDutyPolicy/OnCallTestPage.d.mts +2 -0
  213. package/Types/OnCallDutyPolicy/OnCallTestPage.d.ts +2 -0
  214. package/Types/OnCallDutyPolicy/OnCallTestPage.js +12 -0
  215. package/Types/OnCallDutyPolicy/OnCallTestPage.mjs +1 -0
  216. package/Types/OnCallDutyPolicy/ScheduleLayersSave.d.mts +92 -0
  217. package/Types/OnCallDutyPolicy/ScheduleLayersSave.d.ts +92 -0
  218. package/Types/OnCallDutyPolicy/ScheduleLayersSave.js +512 -0
  219. package/Types/OnCallDutyPolicy/ScheduleLayersSave.mjs +7 -0
  220. package/Types/OnCallDutyPolicy/UserOverrideEdit.d.mts +23 -0
  221. package/Types/OnCallDutyPolicy/UserOverrideEdit.d.ts +23 -0
  222. package/Types/OnCallDutyPolicy/UserOverrideEdit.js +105 -0
  223. package/Types/OnCallDutyPolicy/UserOverrideEdit.mjs +6 -0
  224. package/Types/OnCallDutyPolicy/UserOverrideOverlap.d.mts +64 -0
  225. package/Types/OnCallDutyPolicy/UserOverrideOverlap.d.ts +64 -0
  226. package/Types/OnCallDutyPolicy/UserOverrideOverlap.js +237 -0
  227. package/Types/OnCallDutyPolicy/UserOverrideOverlap.mjs +14 -0
  228. package/Types/OpenStack/OpenStackCapacity.js +12 -5
  229. package/Types/Permission.d.mts +4 -0
  230. package/Types/Permission.d.ts +4 -0
  231. package/Types/Permission.js +66 -10
  232. package/Types/Probe/ProbeCapability.d.mts +2 -1
  233. package/Types/Probe/ProbeCapability.d.ts +2 -1
  234. package/Types/Probe/ProbeCapability.js +10 -0
  235. package/Types/Product/ProductUsage.js +2 -1
  236. package/Types/Product/ProjectProductsAnswer.js +2 -1
  237. package/Types/ReaderLanguage.d.mts +1 -0
  238. package/Types/ReaderLanguage.d.ts +1 -0
  239. package/Types/ReaderLanguage.js +13 -1
  240. package/Types/ReaderLanguage.mjs +1 -0
  241. package/Types/ResourceAiAgent/AiResourceType.d.mts +1 -0
  242. package/Types/ResourceAiAgent/AiResourceType.d.ts +1 -0
  243. package/Types/ResourceAiAgent/AiResourceType.js +12 -0
  244. package/Types/Rules/RuleRun.js +2 -2
  245. package/Types/Rum/ProductAnalyticsEventReads.js +10 -1
  246. package/Types/Rum/ProductAnalyticsEvents.js +13 -1
  247. package/Types/Rum/SessionReplayCustomEvents.d.mts +4 -1
  248. package/Types/Rum/SessionReplayCustomEvents.d.ts +4 -1
  249. package/Types/Rum/SessionReplayCustomEvents.js +12 -0
  250. package/Types/Rum/SessionReplayCustomEvents.mjs +1 -0
  251. package/Types/ScheduledMaintenance/MaintenanceCalendar.js +1 -1
  252. package/Types/ServerSending/ServerSendingStatus.d.mts +7 -0
  253. package/Types/ServerSending/ServerSendingStatus.d.ts +7 -0
  254. package/Types/ServerSending/ServerSendingStatus.js +49 -2
  255. package/Types/ServerSetup/ServerSetupChecklist.js +3 -3
  256. package/Types/SetupHealth/SetupHealth.d.mts +1 -0
  257. package/Types/SetupHealth/SetupHealth.d.ts +1 -0
  258. package/Types/SetupHealth/SetupHealth.js +13 -5
  259. package/Types/StateTimeline/RowsKeptOnDelete.js +1 -1
  260. package/Types/StatusPage/DefaultStatusNames.d.mts +11 -3
  261. package/Types/StatusPage/DefaultStatusNames.d.ts +11 -3
  262. package/Types/StatusPage/DefaultStatusNames.js +74 -28
  263. package/Types/StatusPage/DefaultStatusNames.mjs +9 -2
  264. package/Types/StatusPage/NewIncidentSubscriberNotificationDefault.d.mts +8 -0
  265. package/Types/StatusPage/NewIncidentSubscriberNotificationDefault.d.ts +8 -0
  266. package/Types/StatusPage/NewIncidentSubscriberNotificationDefault.js +50 -0
  267. package/Types/StatusPage/NewIncidentSubscriberNotificationDefault.mjs +3 -0
  268. package/Types/StatusPage/PublicNoteSubscriberNotificationDefault.js +1 -1
  269. package/Types/StatusPage/StateChangeNoteMessage.d.mts +3 -2
  270. package/Types/StatusPage/StateChangeNoteMessage.d.ts +3 -2
  271. package/Types/StatusPage/StateChangeNoteMessage.js +16 -13
  272. package/Types/Telemetry/CompatibleIngest.d.mts +20 -0
  273. package/Types/Telemetry/CompatibleIngest.d.ts +20 -0
  274. package/Types/Telemetry/CompatibleIngest.js +123 -0
  275. package/Types/Telemetry/CompatibleIngest.mjs +21 -0
  276. package/Types/Telemetry/TelemetryIngestSurface.d.mts +5 -0
  277. package/Types/Telemetry/TelemetryIngestSurface.d.ts +5 -0
  278. package/Types/Telemetry/TelemetryIngestSurface.js +48 -7
  279. package/Types/Telemetry/TelemetryIngestionKeyType.js +7 -6
  280. package/Types/TimezoneAlias.d.mts +1 -0
  281. package/Types/TimezoneAlias.d.ts +1 -0
  282. package/Types/TimezoneAlias.js +13 -0
  283. package/Types/Translator.d.mts +1 -0
  284. package/Types/Translator.d.ts +1 -0
  285. package/Types/Translator.js +470 -63
  286. package/Types/Translator.mjs +1 -0
  287. package/Types/UserSession/SessionLength.d.mts +33 -0
  288. package/Types/UserSession/SessionLength.d.ts +33 -0
  289. package/Types/UserSession/SessionLength.js +134 -5
  290. package/Types/UserSession/SessionLength.mjs +5 -0
  291. package/Types/Workflow/RunRecord.js +1 -1
  292. package/Types/Workflow/Templates.js +2 -2
  293. package/Types/Workflow/WorkflowStatus.js +21 -10
  294. package/Types/Workspace/NotificationRules/BaseNotificationRule.d.mts +2 -0
  295. package/Types/Workspace/NotificationRules/BaseNotificationRule.d.ts +2 -0
  296. package/Types/Workspace/NotificationRules/NotificationRuleCondition.d.mts +26 -1
  297. package/Types/Workspace/NotificationRules/NotificationRuleCondition.d.ts +26 -1
  298. package/Types/Workspace/NotificationRules/NotificationRuleUpdates.d.mts +84 -0
  299. package/Types/Workspace/NotificationRules/NotificationRuleUpdates.d.ts +84 -0
  300. package/Types/Workspace/NotificationRules/NotificationRuleUpdates.js +456 -0
  301. package/Types/Workspace/NotificationRules/NotificationRuleUpdates.mjs +5 -0
  302. package/Utils/AI/InvestigationReport.js +2 -2
  303. package/Utils/API.d.mts +0 -11
  304. package/Utils/API.d.ts +0 -11
  305. package/Utils/API.js +0 -432
  306. package/Utils/AiRemediation/Resource/ResourceCommandPolicy.js +2 -2
  307. package/Utils/AiRemediation/VerifiedFixRunbook.d.mts +39 -0
  308. package/Utils/AiRemediation/VerifiedFixRunbook.d.ts +39 -0
  309. package/Utils/AiRemediation/VerifiedFixRunbook.js +231 -0
  310. package/Utils/AiRemediation/VerifiedFixRunbook.mjs +10 -0
  311. package/Utils/Dashboard/DashboardWidgetSorts.js +11 -2
  312. package/Utils/Dashboard/MonitorListWidgetFormat.d.mts +2 -1
  313. package/Utils/Dashboard/MonitorListWidgetFormat.d.ts +2 -1
  314. package/Utils/Dashboard/MonitorListWidgetFormat.js +5 -3
  315. package/Utils/Dashboard/ValueWidgetSeries.d.mts +2 -0
  316. package/Utils/Dashboard/ValueWidgetSeries.d.ts +2 -0
  317. package/Utils/Dashboard/ValueWidgetSeries.js +75 -0
  318. package/Utils/DefaultRecordNames.d.mts +6 -0
  319. package/Utils/DefaultRecordNames.d.ts +6 -0
  320. package/Utils/DefaultRecordNames.js +122 -0
  321. package/Utils/DefaultRecordNames.mjs +6 -0
  322. package/Utils/DeveloperDocs/ExampleBuilder.js +1 -1
  323. package/Utils/DeveloperDocs/ResourceProfiles.js +2 -2
  324. package/Utils/Grok/Grok.js +7 -4
  325. package/Utils/GuidedSetup/StatusPageRecords.d.mts +5 -0
  326. package/Utils/GuidedSetup/StatusPageRecords.d.ts +5 -0
  327. package/Utils/GuidedSetup/StatusPageRecords.js +27 -2
  328. package/Utils/GuidedSetup/StatusPageRecords.mjs +1 -0
  329. package/Utils/GuidedSetup/WebsiteMonitorRecords.js +6 -0
  330. package/Utils/HostAddressUtil.d.mts +1 -0
  331. package/Utils/HostAddressUtil.d.ts +1 -0
  332. package/Utils/HostAddressUtil.js +30 -0
  333. package/Utils/Incident/PostmortemActionItemCodeTask.d.mts +20 -0
  334. package/Utils/Incident/PostmortemActionItemCodeTask.d.ts +20 -0
  335. package/Utils/Incident/PostmortemActionItemCodeTask.js +107 -0
  336. package/Utils/Incident/PostmortemActionItemCodeTask.mjs +10 -0
  337. package/Utils/Incident/PostmortemActionItemMarkdown.d.mts +39 -0
  338. package/Utils/Incident/PostmortemActionItemMarkdown.d.ts +39 -0
  339. package/Utils/Incident/PostmortemActionItemMarkdown.js +118 -0
  340. package/Utils/Incident/PostmortemActionItemMarkdown.mjs +12 -0
  341. package/Utils/Incident/PostmortemNoteActionItems.d.mts +29 -0
  342. package/Utils/Incident/PostmortemNoteActionItems.d.ts +29 -0
  343. package/Utils/Incident/PostmortemNoteActionItems.js +544 -0
  344. package/Utils/Incident/PostmortemNoteActionItems.mjs +7 -0
  345. package/Utils/LinearRegExp/LinearRegExp.js +5 -1
  346. package/Utils/LookupTable.d.mts +3 -0
  347. package/Utils/LookupTable.d.ts +3 -0
  348. package/Utils/LookupTable.js +61 -0
  349. package/Utils/LookupTable.mjs +3 -0
  350. package/Utils/Markdown/LinkReferenceDefinitions.d.mts +2 -0
  351. package/Utils/Markdown/LinkReferenceDefinitions.d.ts +2 -0
  352. package/Utils/Markdown/LinkReferenceDefinitions.js +101 -1
  353. package/Utils/Markdown/LinkReferenceDefinitions.mjs +2 -0
  354. package/Utils/Markdown/OverLongText.js +296 -2
  355. package/Utils/Markdown/SlowMarkdown.d.mts +1 -0
  356. package/Utils/Markdown/SlowMarkdown.d.ts +1 -0
  357. package/Utils/Markdown/SlowMarkdown.js +354 -4
  358. package/Utils/Markdown/SlowMarkdown.mjs +1 -0
  359. package/Utils/Metrics/MetricFormulaEvaluator.js +10 -4
  360. package/Utils/Metrics/MetricSeriesFingerprint.js +13 -4
  361. package/Utils/Metrics/MetricSeriesScope.d.mts +5 -0
  362. package/Utils/Metrics/MetricSeriesScope.d.ts +5 -0
  363. package/Utils/Metrics/MetricSeriesScope.js +5 -1
  364. package/Utils/Milliseconds.d.mts +7 -0
  365. package/Utils/Milliseconds.d.ts +7 -0
  366. package/Utils/Milliseconds.js +60 -0
  367. package/Utils/Milliseconds.mjs +4 -0
  368. package/Utils/Monitor/EndpointAttachmentUtil.d.mts +8 -0
  369. package/Utils/Monitor/EndpointAttachmentUtil.d.ts +8 -0
  370. package/Utils/Monitor/EndpointAttachmentUtil.js +91 -21
  371. package/Utils/Monitor/EndpointAttachmentUtil.mjs +4 -0
  372. package/Utils/Monitor/InterfaceInventoryUtil.d.mts +40 -0
  373. package/Utils/Monitor/InterfaceInventoryUtil.d.ts +40 -0
  374. package/Utils/Monitor/InterfaceInventoryUtil.js +217 -5
  375. package/Utils/Monitor/InterfaceInventoryUtil.mjs +8 -0
  376. package/Utils/Monitor/MonitorOverviewPresentationUtil.js +63 -29
  377. package/Utils/Monitor/MonitorOverviewProbeUtil.js +13 -2
  378. package/Utils/Monitor/MonitorRootCauseWording.d.mts +5 -0
  379. package/Utils/Monitor/MonitorRootCauseWording.d.ts +5 -0
  380. package/Utils/Monitor/MonitorRootCauseWording.js +148 -5
  381. package/Utils/Monitor/MonitoringOff.d.mts +2 -0
  382. package/Utils/Monitor/MonitoringOff.d.ts +2 -0
  383. package/Utils/Monitor/MonitoringOff.js +21 -0
  384. package/Utils/Monitor/NetworkTopologyUtil.d.mts +2 -1
  385. package/Utils/Monitor/NetworkTopologyUtil.d.ts +2 -1
  386. package/Utils/Monitor/NetworkTopologyUtil.js +10 -0
  387. package/Utils/Monitor/NotOperationalMonitorQuery.d.mts +2 -1
  388. package/Utils/Monitor/NotOperationalMonitorQuery.d.ts +2 -1
  389. package/Utils/Monitor/NotOperationalMonitorQuery.js +23 -4
  390. package/Utils/Monitor/ProbeAgreementRule.d.mts +10 -0
  391. package/Utils/Monitor/ProbeAgreementRule.d.ts +10 -0
  392. package/Utils/Monitor/ProbeAgreementRule.js +58 -0
  393. package/Utils/Monitor/ProbeAgreementRule.mjs +3 -0
  394. package/Utils/Monitor/ProbeFailureReading.d.mts +18 -0
  395. package/Utils/Monitor/ProbeFailureReading.d.ts +18 -0
  396. package/Utils/Monitor/ProbeFailureReading.js +166 -0
  397. package/Utils/Monitor/ProbeFailureReading.mjs +8 -0
  398. package/Utils/Monitor/RequestFailureDescriptions.d.mts +61 -0
  399. package/Utils/Monitor/RequestFailureDescriptions.d.ts +61 -0
  400. package/Utils/Monitor/RequestFailureDescriptions.js +252 -0
  401. package/Utils/Monitor/RequestFailureDescriptions.mjs +6 -0
  402. package/Utils/NetworkDevice/BoundMonitorNotChecked.d.mts +9 -0
  403. package/Utils/NetworkDevice/BoundMonitorNotChecked.d.ts +9 -0
  404. package/Utils/NetworkDevice/BoundMonitorNotChecked.js +15 -0
  405. package/Utils/NetworkDevice/BoundMonitorNotChecked.mjs +2 -0
  406. package/Utils/Project/NextNumber.js +1 -1
  407. package/Utils/PromQL/PromQLAst.d.mts +159 -0
  408. package/Utils/PromQL/PromQLAst.d.ts +159 -0
  409. package/Utils/PromQL/PromQLAst.js +118 -0
  410. package/Utils/PromQL/PromQLAst.mjs +12 -0
  411. package/Utils/PromQL/PromQLDuration.d.mts +2 -0
  412. package/Utils/PromQL/PromQLDuration.d.ts +2 -0
  413. package/Utils/PromQL/PromQLDuration.js +78 -0
  414. package/Utils/PromQL/PromQLDuration.mjs +3 -0
  415. package/Utils/PromQL/PromQLEngine.d.mts +15 -0
  416. package/Utils/PromQL/PromQLEngine.d.ts +15 -0
  417. package/Utils/PromQL/PromQLEngine.js +974 -0
  418. package/Utils/PromQL/PromQLEngine.mjs +7 -0
  419. package/Utils/PromQL/PromQLEngineTypes.d.mts +84 -0
  420. package/Utils/PromQL/PromQLEngineTypes.d.ts +84 -0
  421. package/Utils/PromQL/PromQLEngineTypes.js +10 -0
  422. package/Utils/PromQL/PromQLEngineTypes.mjs +2 -0
  423. package/Utils/PromQL/PromQLError.d.mts +11 -0
  424. package/Utils/PromQL/PromQLError.d.ts +11 -0
  425. package/Utils/PromQL/PromQLError.js +27 -0
  426. package/Utils/PromQL/PromQLError.mjs +3 -0
  427. package/Utils/PromQL/PromQLFunctionEvaluators.d.mts +8 -0
  428. package/Utils/PromQL/PromQLFunctionEvaluators.d.ts +8 -0
  429. package/Utils/PromQL/PromQLFunctionEvaluators.js +829 -0
  430. package/Utils/PromQL/PromQLFunctionEvaluators.mjs +3 -0
  431. package/Utils/PromQL/PromQLFunctions.d.mts +10 -0
  432. package/Utils/PromQL/PromQLFunctions.d.ts +10 -0
  433. package/Utils/PromQL/PromQLFunctions.js +127 -0
  434. package/Utils/PromQL/PromQLFunctions.mjs +4 -0
  435. package/Utils/PromQL/PromQLLabelOrder.d.mts +8 -0
  436. package/Utils/PromQL/PromQLLabelOrder.d.ts +8 -0
  437. package/Utils/PromQL/PromQLLabelOrder.js +212 -0
  438. package/Utils/PromQL/PromQLLabelOrder.mjs +6 -0
  439. package/Utils/PromQL/PromQLLabels.d.mts +11 -0
  440. package/Utils/PromQL/PromQLLabels.d.ts +11 -0
  441. package/Utils/PromQL/PromQLLabels.js +219 -0
  442. package/Utils/PromQL/PromQLLabels.mjs +9 -0
  443. package/Utils/PromQL/PromQLLexer.d.mts +39 -0
  444. package/Utils/PromQL/PromQLLexer.d.ts +39 -0
  445. package/Utils/PromQL/PromQLLexer.js +391 -0
  446. package/Utils/PromQL/PromQLLexer.mjs +3 -0
  447. package/Utils/PromQL/PromQLMath.d.mts +19 -0
  448. package/Utils/PromQL/PromQLMath.d.ts +19 -0
  449. package/Utils/PromQL/PromQLMath.js +200 -0
  450. package/Utils/PromQL/PromQLMath.mjs +9 -0
  451. package/Utils/PromQL/PromQLMetricNames.d.mts +21 -0
  452. package/Utils/PromQL/PromQLMetricNames.d.ts +21 -0
  453. package/Utils/PromQL/PromQLMetricNames.js +205 -0
  454. package/Utils/PromQL/PromQLMetricNames.mjs +8 -0
  455. package/Utils/PromQL/PromQLParser.d.mts +4 -0
  456. package/Utils/PromQL/PromQLParser.d.ts +4 -0
  457. package/Utils/PromQL/PromQLParser.js +836 -0
  458. package/Utils/PromQL/PromQLParser.mjs +4 -0
  459. package/Utils/PromQL/PromQLRegex.d.mts +20 -0
  460. package/Utils/PromQL/PromQLRegex.d.ts +20 -0
  461. package/Utils/PromQL/PromQLRegex.js +1014 -0
  462. package/Utils/PromQL/PromQLRegex.mjs +5 -0
  463. package/Utils/PromQL/PrometheusResponse.d.mts +25 -0
  464. package/Utils/PromQL/PrometheusResponse.d.ts +25 -0
  465. package/Utils/PromQL/PrometheusResponse.js +92 -0
  466. package/Utils/PromQL/PrometheusResponse.mjs +3 -0
  467. package/Utils/PromQL/RE2CharacterClass.d.mts +24 -0
  468. package/Utils/PromQL/RE2CharacterClass.d.ts +24 -0
  469. package/Utils/PromQL/RE2CharacterClass.js +532 -0
  470. package/Utils/PromQL/RE2CharacterClass.mjs +16 -0
  471. package/Utils/RequestFailedDetailsUtil.d.mts +15 -0
  472. package/Utils/RequestFailedDetailsUtil.d.ts +15 -0
  473. package/Utils/RequestFailedDetailsUtil.js +452 -0
  474. package/Utils/RequestFailedDetailsUtil.mjs +2 -0
  475. package/Utils/Rum/PathInSentence.d.mts +5 -0
  476. package/Utils/Rum/PathInSentence.d.ts +5 -0
  477. package/Utils/Rum/PathInSentence.js +46 -0
  478. package/Utils/Rum/PathInSentence.mjs +6 -0
  479. package/Utils/Rum/UrlScrubber.d.mts +5 -1
  480. package/Utils/Rum/UrlScrubber.d.ts +5 -1
  481. package/Utils/Rum/UrlScrubber.js +153 -7
  482. package/Utils/Rum/UserFlow.d.mts +1 -1
  483. package/Utils/Rum/UserFlow.d.ts +1 -1
  484. package/Utils/Rum/UserFlow.js +202 -29
  485. package/Utils/Rum/UserFlow.mjs +1 -1
  486. package/Utils/Runbook/RunbookStepsSignature.d.mts +3 -0
  487. package/Utils/Runbook/RunbookStepsSignature.d.ts +3 -0
  488. package/Utils/Runbook/RunbookStepsSignature.js +30 -0
  489. package/Utils/Runbook/RunbookStepsSignature.mjs +3 -0
  490. package/Utils/Schema/TypeSchemas.js +6 -0
  491. package/Utils/SecurityCase/SecurityOverviewMetrics.d.mts +11 -1
  492. package/Utils/SecurityCase/SecurityOverviewMetrics.d.ts +11 -1
  493. package/Utils/SecurityCase/SecurityOverviewMetrics.js +99 -17
  494. package/Utils/SecurityCase/SecurityOverviewMetrics.mjs +3 -0
  495. package/Utils/Slo/SloDuration.d.mts +5 -2
  496. package/Utils/Slo/SloDuration.d.ts +5 -2
  497. package/Utils/Slo/SloDuration.js +11 -6
  498. package/Utils/Slo/SloHealth.js +1 -1
  499. package/Utils/Sms/OnCallPageSms.d.mts +2 -0
  500. package/Utils/Sms/OnCallPageSms.d.ts +2 -0
  501. package/Utils/Sms/OnCallPageSms.js +3 -1
  502. package/Utils/StateListType.d.mts +11 -0
  503. package/Utils/StateListType.d.ts +11 -0
  504. package/Utils/StateListType.js +21 -0
  505. package/Utils/StateListType.mjs +2 -0
  506. package/Utils/StateOrder.d.mts +8 -11
  507. package/Utils/StateOrder.d.ts +8 -11
  508. package/Utils/StateOrder.js +50 -88
  509. package/Utils/StateOrder.mjs +2 -0
  510. package/Utils/StateTimeline/StateTimelineRowDelete.js +1 -1
  511. package/Utils/Suggestions/ActionItemCodeTaskSuggestion.d.mts +9 -0
  512. package/Utils/Suggestions/ActionItemCodeTaskSuggestion.d.ts +9 -0
  513. package/Utils/Suggestions/ActionItemCodeTaskSuggestion.js +25 -0
  514. package/Utils/Suggestions/ActionItemCodeTaskSuggestion.mjs +2 -0
  515. package/Utils/Suggestions/VerifiedFixRunbookSuggestion.d.mts +5 -0
  516. package/Utils/Suggestions/VerifiedFixRunbookSuggestion.d.ts +5 -0
  517. package/Utils/Suggestions/VerifiedFixRunbookSuggestion.js +39 -0
  518. package/Utils/Suggestions/VerifiedFixRunbookSuggestion.mjs +2 -0
  519. package/Utils/Syslog/SyslogMessageParser.js +16 -6
  520. package/Utils/Telemetry/HeartbeatAvailability.d.mts +4 -0
  521. package/Utils/Telemetry/HeartbeatAvailability.d.ts +4 -0
  522. package/Utils/Telemetry/HeartbeatAvailability.js +113 -26
  523. package/Utils/Uptime/DayUptimeGraphUtil.js +2 -2
  524. package/Utils/ValueFormatter.d.mts +1 -0
  525. package/Utils/ValueFormatter.d.ts +1 -0
  526. package/Utils/ValueFormatter.js +258 -18
  527. package/package.json +1 -1
@@ -43,12 +43,14 @@ const CriteriaFilter_1 = require("../../Types/Monitor/CriteriaFilter");
43
43
  const MonitorType_1 = __importDefault(require("../../Types/Monitor/MonitorType"));
44
44
  const SloDuration_1 = require("../Slo/SloDuration");
45
45
  const Translator_1 = require("../../Types/Translator");
46
+ const Milliseconds_1 = require("../Milliseconds");
46
47
  const MonitorCheckScheduleUtil_1 = __importStar(require("./MonitorCheckScheduleUtil"));
47
48
  const MonitorOverviewCriteriaUtil_1 = __importDefault(require("./MonitorOverviewCriteriaUtil"));
48
49
  const MonitorOverviewFamily_1 = __importStar(require("./MonitorOverviewFamily"));
49
50
  const MonitorStatusHistoryUtil_1 = __importDefault(require("./MonitorStatusHistoryUtil"));
50
51
  const ProbeStatusMonitorUtil_1 = __importDefault(require("./ProbeStatusMonitorUtil"));
51
52
  const MonitorOverviewTargetUtil_1 = __importDefault(require("./MonitorOverviewTargetUtil"));
53
+ const ProbeFailureReading_1 = require("./ProbeFailureReading");
52
54
  /*
53
55
  * The monitor overview's hero, facts, pulse and section switches, decided in
54
56
  * one pure function so every per-type and per-state rule is unit-tested
@@ -67,6 +69,13 @@ const MonitorOverviewTargetUtil_1 = __importDefault(require("./MonitorOverviewTa
67
69
  * for word as it always has. What a monitor's owner named - a probe, a
68
70
  * host - goes in as written; a status's name is drawn as StatusBadge draws
69
71
  * it, in the reader's words when it is one of OneUptime's own.
72
+ *
73
+ * Its figures are the reader's too: a count goes into its sentence as
74
+ * translator.formatNumber writes it ("۲ از ۳" in Persian, never "2 از 3"),
75
+ * a response time through the shared formatMilliseconds ("182 ms", "۱۸۲
76
+ * میلی‌ثانیه", "182 ملي ث"), and the facts of one line are set apart as the
77
+ * reader's language sets them (formatInline: " · ", or " • " in Persian,
78
+ * whose zero is a dot).
70
79
  */
71
80
  var MonitorOverviewRunState;
72
81
  (function (MonitorOverviewRunState) {
@@ -95,7 +104,7 @@ const PAUSED_EXPLANATION = {
95
104
  incident: (0, Translator_1.translationKey)("Checks resume when the incident that paused this monitor is resolved."),
96
105
  maintenance: (0, Translator_1.translationKey)("Checks resume automatically when the maintenance event ends."),
97
106
  };
98
- const MANUAL_EXPLANATION = (0, Translator_1.translationKey)("Manual monitor: OneUptime runs no checks. The status changes when someone sets it, or when an incident or scheduled maintenance event changes it.");
107
+ const MANUAL_EXPLANATION = (0, Translator_1.translationKey)("Manual monitor: OneUptime runs no checks. The status changes when someone sets it, or when an incident or maintenance event changes it.");
99
108
  /*
100
109
  * What an empty evaluation log says once the monitor is older than the
101
110
  * log keeps rows (MONITOR_LOG_MINIMUM_RETENTION_SECONDS): not "never".
@@ -1479,15 +1488,15 @@ class MonitorOverviewPresentationUtil {
1479
1488
  return Object.assign(Object.assign({}, base), { value: total === 1
1480
1489
  ? t.translateTemplate("Disconnected")
1481
1490
  : t.translateTemplate("{{disconnected}} of {{total}} disconnected", {
1482
- disconnected: disconnected,
1483
- total: total,
1491
+ disconnected: t.formatNumber(disconnected),
1492
+ total: t.formatNumber(total),
1484
1493
  }), secondary: ProbeStatusMonitorUtil_1.default.joinProbeNames(ProbeStatusMonitorUtil_1.default.getDisconnectedProbes({ probes: probes })), tone: "danger" });
1485
1494
  }
1486
1495
  return Object.assign(Object.assign({}, base), { value: total === 1
1487
1496
  ? t.translateTemplate("Connected")
1488
1497
  : t.translateTemplate("{{connected}} of {{total}} connected", {
1489
- connected: total,
1490
- total: total,
1498
+ connected: t.formatNumber(total),
1499
+ total: t.formatNumber(total),
1491
1500
  }),
1492
1501
  // One probe is named; several connected need no list.
1493
1502
  secondary: total === 1 ? ProbeStatusMonitorUtil_1.default.joinProbeNames(probes) : undefined, tone: "good" });
@@ -1517,44 +1526,62 @@ class MonitorOverviewPresentationUtil {
1517
1526
  if (upCount > 0 && downCount > 0) {
1518
1527
  return Object.assign(Object.assign({}, base), { value: isScripted
1519
1528
  ? t.translateTemplate("Mixed · {{up}} passed, {{down}} failed", {
1520
- up: upCount,
1521
- down: downCount,
1529
+ up: t.formatNumber(upCount),
1530
+ down: t.formatNumber(downCount),
1522
1531
  })
1523
1532
  : t.translateTemplate("Mixed · {{up}} up, {{down}} down", {
1524
- up: upCount,
1525
- down: downCount,
1533
+ up: t.formatNumber(upCount),
1534
+ down: t.formatNumber(downCount),
1526
1535
  }), tone: "warning" });
1527
1536
  }
1528
1537
  /*
1529
- * The verdict in the reader's words, then the figures every language
1530
- * writes alike: "Up · 120 ms · HTTP 200".
1538
+ * The verdict in the reader's words, then the response time in the
1539
+ * reader's digits and unit, then the status code every language writes
1540
+ * alike: "Up · 120 ms · HTTP 200", "Up · 120 ms · HTTP 200" in German,
1541
+ * "فعال • ۱۲۰ میلی‌ثانیه • HTTP 200" in Persian.
1531
1542
  */
1532
- let value = t.translateTemplate("Reported");
1543
+ let verdict = t.translateTemplate("Reported");
1533
1544
  let tone = "neutral";
1534
1545
  if (result.isOnline === true) {
1535
- value = isScripted
1546
+ verdict = isScripted
1536
1547
  ? t.translateTemplate("Passed")
1537
1548
  : t.translateTemplate("Up");
1538
1549
  tone = "good";
1539
1550
  }
1540
1551
  else if (result.isOnline === false) {
1541
- value = isScripted
1552
+ verdict = isScripted
1542
1553
  ? t.translateTemplate("Failed")
1543
1554
  : t.translateTemplate("Down");
1544
1555
  tone = "danger";
1545
1556
  }
1557
+ const parts = [verdict];
1546
1558
  if (result.responseTimeInMs !== undefined) {
1547
- value += ` · ${Math.round(result.responseTimeInMs)} ms`;
1559
+ parts.push((0, Milliseconds_1.formatMilliseconds)(t, result.responseTimeInMs, {
1560
+ maximumFractionDigits: 0,
1561
+ }));
1548
1562
  }
1549
1563
  if (result.responseCode !== undefined &&
1550
1564
  (input.monitorType === MonitorType_1.default.API ||
1551
1565
  input.monitorType === MonitorType_1.default.Website)) {
1552
- value += ` · HTTP ${result.responseCode}`;
1566
+ // A protocol's status code, as the server answered it.
1567
+ parts.push(`HTTP ${result.responseCode}`);
1553
1568
  }
1554
- // A failure cause is the probe's own message, as it wrote it.
1555
- return Object.assign(Object.assign({}, base), { value: value, secondary: result.isOnline === false && result.failureCause
1556
- ? result.failureCause
1557
- : t.translateTemplate("from {{probe}}", { probe: result.probeName }), tone: tone });
1569
+ /*
1570
+ * A failure cause as every monitor summary draws it: the probe's own
1571
+ * timeout sentence in the reader's words and digits, and any other
1572
+ * message - the network's, a server's - as the probe wrote it
1573
+ * (getProbeFailureCauseText). The hero draws a message that reads the
1574
+ * other way from the page in its own direction (readAsWritten). A
1575
+ * cause that is only space names the probe instead.
1576
+ */
1577
+ const failureCause = result.isOnline === false
1578
+ ? (0, ProbeFailureReading_1.getProbeFailureCauseText)({
1579
+ translator: t,
1580
+ failureCause: result.failureCause,
1581
+ })
1582
+ : "";
1583
+ return Object.assign(Object.assign({}, base), { value: (0, Translator_1.formatInline)(parts, t), secondary: failureCause ||
1584
+ t.translateTemplate("from {{probe}}", { probe: result.probeName }), tone: tone });
1558
1585
  }
1559
1586
  static getProbesFact(input, context) {
1560
1587
  const t = context.t;
@@ -1568,20 +1595,23 @@ class MonitorOverviewPresentationUtil {
1568
1595
  }
1569
1596
  const probes = input.probes;
1570
1597
  const downCount = probes.downCount || 0;
1571
- // Each part is a phrase of its own, so the " · " between them is no word.
1598
+ /*
1599
+ * Each part is a phrase of its own, so what stands between them is no
1600
+ * word: " · ", or " • " in a language whose zero is a dot (formatInline).
1601
+ */
1572
1602
  const connectionParts = [];
1573
1603
  if (probes.disabledCount > 0) {
1574
1604
  connectionParts.push(t.translateTemplate("{{count}} disabled", {
1575
- count: probes.disabledCount,
1605
+ count: t.formatNumber(probes.disabledCount),
1576
1606
  }));
1577
1607
  }
1578
1608
  if (probes.disconnectedCount > 0) {
1579
1609
  connectionParts.push(t.translateTemplate("{{count}} disconnected", {
1580
- count: probes.disconnectedCount,
1610
+ count: t.formatNumber(probes.disconnectedCount),
1581
1611
  }));
1582
1612
  }
1583
1613
  const joinParts = (parts) => {
1584
- return parts.length > 0 ? parts.join(" · ") : undefined;
1614
+ return parts.length > 0 ? (0, Translator_1.formatInline)(parts, t) : undefined;
1585
1615
  };
1586
1616
  if (probes.enabledCount === 0) {
1587
1617
  return Object.assign(Object.assign({}, base), { value: t.translateTemplate("None enabled"), secondary: joinParts(connectionParts), tone: "danger" });
@@ -1592,7 +1622,7 @@ class MonitorOverviewPresentationUtil {
1592
1622
  */
1593
1623
  if (context.isPaused) {
1594
1624
  return Object.assign(Object.assign({}, base), { value: t.translateTemplate("{{count}} enabled", {
1595
- count: probes.enabledCount,
1625
+ count: t.formatNumber(probes.enabledCount),
1596
1626
  }), secondary: joinParts([
1597
1627
  t.translateTemplate("Checks paused"),
1598
1628
  ...connectionParts,
@@ -1610,11 +1640,15 @@ class MonitorOverviewPresentationUtil {
1610
1640
  input.monitorType === MonitorType_1.default.CustomJavaScriptCode;
1611
1641
  // A probe that reports Down is reporting, but it is not fine.
1612
1642
  const downPart = isScripted
1613
- ? t.translateTemplate("{{count}} failing", { count: downCount })
1614
- : t.translateTemplate("{{count}} down", { count: downCount });
1643
+ ? t.translateTemplate("{{count}} failing", {
1644
+ count: t.formatNumber(downCount),
1645
+ })
1646
+ : t.translateTemplate("{{count}} down", {
1647
+ count: t.formatNumber(downCount),
1648
+ });
1615
1649
  return Object.assign(Object.assign({}, base), { value: t.translateTemplate("{{reporting}} of {{enabled}} reporting", {
1616
- reporting: probes.reportingCount,
1617
- enabled: probes.enabledCount,
1650
+ reporting: t.formatNumber(probes.reportingCount),
1651
+ enabled: t.formatNumber(probes.enabledCount),
1618
1652
  }), secondary: joinParts(downCount > 0 ? [downPart, ...connectionParts] : connectionParts), tone: tone });
1619
1653
  }
1620
1654
  static getPercentFact(data) {
@@ -335,7 +335,9 @@ class MonitorOverviewProbeUtil {
335
335
  * after its result is further back than the grace, so a schedule with
336
336
  * gaps does not mark every probe late through the gap. `isScheduled`
337
337
  * false (monitoring is paused) means no probe is expected to check, so
338
- * none is late: each keeps the verdict of its last result.
338
+ * none is late: each keeps the verdict of its last result, and none has
339
+ * a next check (nextPingAt, nextCheckAt and latestNextCheckAt are left
340
+ * out).
339
341
  */
340
342
  static summarizeProbes(data) {
341
343
  var _a, _b, _c, _d, _e, _f;
@@ -392,7 +394,16 @@ class MonitorOverviewProbeUtil {
392
394
  ? connectionStatus !== Probe_1.ProbeConnectionStatus.Disconnected
393
395
  : null,
394
396
  lastPingAt: MonitorCheckScheduleUtil_1.default.parseDate(monitorProbe.lastPingAt),
395
- nextPingAt: MonitorCheckScheduleUtil_1.default.parseDate(monitorProbe.nextPingAt),
397
+ /*
398
+ * A paused monitor has no next check to promise, whatever the row
399
+ * says: the probes' claim sets the rows of a monitor nothing may
400
+ * probe aside, a quarter of an hour at a time
401
+ * (Server/Utils/Probe/ClaimSetAside), so their nextPingAt is when
402
+ * the claim looks at them again, not a check that will happen.
403
+ */
404
+ nextPingAt: isScheduled
405
+ ? MonitorCheckScheduleUtil_1.default.parseDate(monitorProbe.nextPingAt)
406
+ : undefined,
396
407
  latestResult: latestResult,
397
408
  health: health,
398
409
  });
@@ -10,8 +10,13 @@ export default class MonitorRootCauseWording {
10
10
  translator: Translator;
11
11
  findings?: ReadonlyArray<RootCauseFinding> | undefined;
12
12
  options?: WordEvaluationSentenceOptions | undefined;
13
+ setsValuesApart?: boolean | undefined;
13
14
  }): string;
14
15
  private static boldLabel;
15
16
  private static word;
17
+ private static wordProbeTimeout;
18
+ private static wordFailedPhase;
19
+ private static wordErrorDescription;
20
+ private static setApart;
16
21
  private static getWordedFindings;
17
22
  }
@@ -10,8 +10,13 @@ export default class MonitorRootCauseWording {
10
10
  translator: Translator;
11
11
  findings?: ReadonlyArray<RootCauseFinding> | undefined;
12
12
  options?: WordEvaluationSentenceOptions | undefined;
13
+ setsValuesApart?: boolean | undefined;
13
14
  }): string;
14
15
  private static boldLabel;
15
16
  private static word;
17
+ private static wordProbeTimeout;
18
+ private static wordFailedPhase;
19
+ private static wordErrorDescription;
20
+ private static setApart;
16
21
  private static getWordedFindings;
17
22
  }
@@ -35,7 +35,10 @@ var __importStar = (this && this.__importStar) || (function () {
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  const FeedMarkdown_1 = __importStar(require("../Markdown/FeedMarkdown"));
37
37
  const EvaluationSentence_1 = require("../../Types/Monitor/EvaluationSentence");
38
+ const ReadingDirection_1 = require("../../Types/ReadingDirection");
38
39
  const Translator_1 = require("../../Types/Translator");
40
+ const ProbeFailureReading_1 = require("./ProbeFailureReading");
41
+ const RequestFailureDescriptions_1 = require("./RequestFailureDescriptions");
39
42
  /*
40
43
  * THE ROOT CAUSE A MONITOR WROTE, IN THE READER'S LANGUAGE (issue #6542).
41
44
  *
@@ -61,6 +64,28 @@ const Translator_1 = require("../../Types/Translator");
61
64
  * written. A root cause somebody edited reads as they wrote it, but for a
62
65
  * line that is still OneUptime's own.
63
66
  *
67
+ * Three of the check's values are OneUptime's own words too, and read in
68
+ * the reader's language when the whole value is exactly them: the probe's
69
+ * timeout sentence after **Cause** ("Request was tried 3 times and it
70
+ * timed out.", ProbeFailureReading), the phase after "- Failed Phase:"
71
+ * (DNS Resolution, TLS Handshake), and what the failed request means after
72
+ * "- Error Description:" ("DNS resolution failed. ...",
73
+ * RequestFailureDescriptions).
74
+ *
75
+ * On a page read from the right, a line OneUptime words is its words with
76
+ * a stored value after them - "**نام معیار**: Website is down", "- کد
77
+ * خطا: ETIMEDOUT" - and the value usually has more letters than the
78
+ * label. The viewer lays each block out the way most of its letters read
79
+ * (MarkdownReadingDirection), so the line was laid out from the left, its
80
+ * label's colon and its bullet on the wrong side, and the card turned
81
+ * from side to side line by line. Drawn on the page (setsValuesApart),
82
+ * each value kept as stored is set apart from the label in an isolate
83
+ * (FSI ... PDI) where it could move the words round it, as a sentence's
84
+ * values are (SentenceOptions.setsValuesApart): the line reads the way its
85
+ * label does, the value as written inside it, its full stop at its own
86
+ * end. A root cause somebody typed has no line of OneUptime's, and reads
87
+ * the way its own words do.
88
+ *
64
89
  * Line by line, and only a whole line, or a label at a line's start, is
65
90
  * ever replaced: nothing else in the text is read as one of OneUptime's.
66
91
  * A line that is replaced is written with mdText, as the engine wrote it:
@@ -129,6 +154,18 @@ const FACT_LABEL_SET = new Set(FACT_LABELS);
129
154
  // What an All criteria's root cause says before its findings.
130
155
  const ALL_FILTERS_MET = (0, Translator_1.translationKey)("All filters met.");
131
156
  const FILTER_CONDITIONS_MET = "Filter Conditions Met";
157
+ // "**Cause**: <why the check failed>" - the probe's failure cause.
158
+ const CAUSE = "Cause";
159
+ // "- Failed Phase: <the phase a request broke in>".
160
+ const FAILED_PHASE = "Failed Phase";
161
+ // "- Error Description: <what the failed request means>".
162
+ const ERROR_DESCRIPTION = "Error Description";
163
+ /*
164
+ * A backslash before ASCII punctuation: how mdText escapes a value's
165
+ * Markdown (FeedMarkdown). Read back to the value's text, which is only
166
+ * trusted when mdText writes it back to the very line.
167
+ */
168
+ const MARKDOWN_ESCAPE = /\\([!-/:-@[-`{-~])/g;
132
169
  /*
133
170
  * "**Label**" or "**Label**: rest" - a label of at most 80 characters with
134
171
  * no asterisk or line break in it, so the match is linear in the line.
@@ -150,6 +187,19 @@ class MonitorRootCauseWording {
150
187
  if (!data.rootCause || translator.language === "en") {
151
188
  return data.rootCause;
152
189
  }
190
+ const setsValuesApart = Boolean(data.setsValuesApart);
191
+ const readerDirection = (0, ReadingDirection_1.getReadingDirection)(translator.language);
192
+ /*
193
+ * A stored value after `label`, set apart (when asked) by the way the
194
+ * line reads: the reader's, once their language words the label;
195
+ * English's while it does not.
196
+ */
197
+ const storedValue = (label, stored) => {
198
+ if (!setsValuesApart) {
199
+ return FeedMarkdown_1.default.asMarkdown(stored);
200
+ }
201
+ return FeedMarkdown_1.default.asMarkdown(MonitorRootCauseWording.setApart(stored, translator.hasTranslation(label) ? readerDirection : ReadingDirection_1.LEFT_TO_RIGHT));
202
+ };
153
203
  const findings = MonitorRootCauseWording.getWordedFindings({
154
204
  findings: data.findings || [],
155
205
  translator: translator,
@@ -171,12 +221,20 @@ class MonitorRootCauseWording {
171
221
  return data.rootCause
172
222
  .split("\n")
173
223
  .map((line) => {
224
+ var _a;
174
225
  const boldLabel = BOLD_LABEL_LINE.exec(line);
175
226
  if (boldLabel && BOLD_LABEL_SET.has(boldLabel[1])) {
176
227
  const label = boldLabel[1];
177
228
  const stored = boldLabel[3] || "";
178
229
  // What follows the label: as stored, unless this language words it.
179
- let rest = FeedMarkdown_1.default.asMarkdown(stored);
230
+ let rest = storedValue(label, stored);
231
+ // "**Cause**: <the probe's timeout sentence>", worded with its count.
232
+ if (label === CAUSE && stored.startsWith(" ")) {
233
+ const worded = MonitorRootCauseWording.wordProbeTimeout(stored.slice(1), translator);
234
+ if (worded !== null) {
235
+ rest = (0, FeedMarkdown_1.mdText) ` ${worded}`;
236
+ }
237
+ }
180
238
  // "**Filter Conditions Met**: <the finding, or All filters met.>"
181
239
  if (label === FILTER_CONDITIONS_MET && stored.startsWith(" ")) {
182
240
  const said = stored.slice(1);
@@ -199,10 +257,29 @@ class MonitorRootCauseWording {
199
257
  if (fact && FACT_LABEL_SET.has(fact[1])) {
200
258
  const label = fact[1];
201
259
  const stored = fact[2] || "";
202
- // OneUptime's own yes or no is worded; any other value is as stored.
203
- const value = YES_NO_FACTS.has(label) && (stored === "Yes" || stored === "No")
204
- ? MonitorRootCauseWording.word(stored, translator)
205
- : FeedMarkdown_1.default.asMarkdown(stored);
260
+ /*
261
+ * OneUptime's own yes or no, the phase a request broke in and what
262
+ * the failed request means are worded; any other value is as
263
+ * stored.
264
+ */
265
+ let value = storedValue(label, stored);
266
+ if (YES_NO_FACTS.has(label) &&
267
+ (stored === "Yes" || stored === "No")) {
268
+ value = MonitorRootCauseWording.word(stored, translator);
269
+ }
270
+ else if (label === FAILED_PHASE) {
271
+ value =
272
+ (_a = MonitorRootCauseWording.wordFailedPhase(stored, translator)) !== null && _a !== void 0 ? _a : value;
273
+ }
274
+ else if (label === ERROR_DESCRIPTION) {
275
+ value =
276
+ MonitorRootCauseWording.wordErrorDescription({
277
+ line: line,
278
+ stored: stored,
279
+ translator: translator,
280
+ setsValuesApart: setsValuesApart,
281
+ }) || value;
282
+ }
206
283
  return (0, FeedMarkdown_1.mdText) `- ${MonitorRootCauseWording.word(label, translator)}: ${value}`.toString();
207
284
  }
208
285
  // "- <a finding>", under All filters met.
@@ -223,6 +300,72 @@ class MonitorRootCauseWording {
223
300
  static word(text, translator) {
224
301
  return translator.translateText(text) || text;
225
302
  }
303
+ /*
304
+ * The probe's timeout sentence, as the engine placed it after **Cause**
305
+ * (written with mdText, so compared written the same way), in the
306
+ * reader's language with its count in the reader's digits. Null for any
307
+ * other cause, and when the reader's language does not word it.
308
+ */
309
+ static wordProbeTimeout(stored, translator) {
310
+ const triedCount = (0, ProbeFailureReading_1.readProbeTimeoutFailureCause)(stored);
311
+ if (triedCount === null ||
312
+ asMarkdownText((0, ProbeFailureReading_1.writeProbeTimeoutFailureCause)(triedCount)).toString() !==
313
+ stored ||
314
+ !translator.hasTranslation(ProbeFailureReading_1.PROBE_TIMEOUT_FAILURE_CAUSE.other)) {
315
+ return null;
316
+ }
317
+ return translator.translatePlural(ProbeFailureReading_1.PROBE_TIMEOUT_FAILURE_CAUSE, triedCount);
318
+ }
319
+ /*
320
+ * The phase a request broke in: a phase the probe names, in the reader's
321
+ * word; null for any other value, which stays as stored.
322
+ */
323
+ static wordFailedPhase(stored, translator) {
324
+ const phase = stored.trim();
325
+ const worded = (0, ProbeFailureReading_1.getRequestFailedPhaseText)({
326
+ translator: translator,
327
+ failedPhase: phase,
328
+ });
329
+ return phase && worded !== phase ? worded : null;
330
+ }
331
+ /*
332
+ * What the failed request means, as the engine placed it after "- Error
333
+ * Description:" (written with mdText): one of OneUptime's explanations
334
+ * (RequestFailureDescriptions) in the reader's language, the message
335
+ * that came with it kept as written - set apart from the reader's words
336
+ * when asked. Null for any other value, and when the reader's language
337
+ * does not word the explanation.
338
+ *
339
+ * The stored value is Markdown: it is read back to its text, which is
340
+ * only taken for the explanation when mdText writes it back to the very
341
+ * line the engine stored.
342
+ */
343
+ static wordErrorDescription(data) {
344
+ const text = data.stored.replace(MARKDOWN_ESCAPE, "$1");
345
+ if (!(0, RequestFailureDescriptions_1.readRequestFailureDescription)(text) ||
346
+ (0, FeedMarkdown_1.mdText) `- ${ERROR_DESCRIPTION}: ${text}`.toString() !== data.line) {
347
+ return null;
348
+ }
349
+ const worded = (0, RequestFailureDescriptions_1.getRequestFailureDescriptionText)({
350
+ translator: data.translator,
351
+ description: text,
352
+ options: { setsValuesApart: data.setsValuesApart },
353
+ });
354
+ return worded === text.trim() ? null : worded;
355
+ }
356
+ /*
357
+ * A stored value set apart from the line it is in (setApartInSentence),
358
+ * the space round it left outside the isolate: a value of the line's own
359
+ * script, or with no letter or digit, is left as it is.
360
+ */
361
+ static setApart(stored, lineDirection) {
362
+ const value = stored.trim();
363
+ if (!value) {
364
+ return stored;
365
+ }
366
+ const start = stored.length - stored.trimStart().length;
367
+ return `${stored.slice(0, start)}${(0, ReadingDirection_1.setApartInSentence)(value, lineDirection)}${stored.slice(start + value.length)}`;
368
+ }
226
369
  // Each finding with a sentence its reader's language words.
227
370
  static getWordedFindings(data) {
228
371
  const worded = [];
@@ -1,5 +1,6 @@
1
1
  import Monitor from "../../Models/DatabaseModels/Monitor.mjs";
2
2
  import Query from "../../Types/BaseDatabase/Query.mjs";
3
+ import MonitorNotCheckedReason from "../../Types/Monitor/MonitorNotCheckedReason.mjs";
3
4
  export declare const MONITORING_OFF_SELECT: {
4
5
  disableActiveMonitoring: true;
5
6
  };
@@ -17,4 +18,5 @@ export default class MonitoringOff {
17
18
  static isOff(monitor: MonitoringOffFlags | null | undefined): boolean;
18
19
  static getMonitoredQuery(): Query<Monitor>;
19
20
  static isMonitored(monitor: MonitoredFlags | null | undefined): boolean;
21
+ static getNotCheckedReason(monitor: MonitoredFlags | null | undefined): MonitorNotCheckedReason | null;
20
22
  }
@@ -1,5 +1,6 @@
1
1
  import Monitor from "../../Models/DatabaseModels/Monitor";
2
2
  import Query from "../../Types/BaseDatabase/Query";
3
+ import MonitorNotCheckedReason from "../../Types/Monitor/MonitorNotCheckedReason";
3
4
  export declare const MONITORING_OFF_SELECT: {
4
5
  disableActiveMonitoring: true;
5
6
  };
@@ -17,4 +18,5 @@ export default class MonitoringOff {
17
18
  static isOff(monitor: MonitoringOffFlags | null | undefined): boolean;
18
19
  static getMonitoredQuery(): Query<Monitor>;
19
20
  static isMonitored(monitor: MonitoredFlags | null | undefined): boolean;
21
+ static getNotCheckedReason(monitor: MonitoredFlags | null | undefined): MonitorNotCheckedReason | null;
20
22
  }
@@ -1,6 +1,10 @@
1
1
  "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
2
5
  Object.defineProperty(exports, "__esModule", { value: true });
3
6
  exports.MONITORED_SELECT = exports.MONITORING_OFF_SELECT = void 0;
7
+ const MonitorNotCheckedReason_1 = __importDefault(require("../../Types/Monitor/MonitorNotCheckedReason"));
4
8
  /*
5
9
  * A MONITOR WHOSE MONITORING IS TURNED OFF.
6
10
  *
@@ -77,5 +81,22 @@ class MonitoringOff {
77
81
  static isMonitored(monitor) {
78
82
  return (monitor === null || monitor === void 0 ? void 0 : monitor.isArchived) !== true && !MonitoringOff.isOff(monitor);
79
83
  }
84
+ /*
85
+ * Why nothing checks the monitor (read with MONITORED_SELECT), or null
86
+ * when it is checked - exactly when isMonitored is false, so the two never
87
+ * disagree. Archived wins when both are set: unarchiving is what puts the
88
+ * monitor back, and its switch only matters after that. The device pages'
89
+ * "Monitor archived" and "Monitoring off" qualifiers and the Network Map's
90
+ * device nodes say this reason (issue #7346).
91
+ */
92
+ static getNotCheckedReason(monitor) {
93
+ if ((monitor === null || monitor === void 0 ? void 0 : monitor.isArchived) === true) {
94
+ return MonitorNotCheckedReason_1.default.MonitorArchived;
95
+ }
96
+ if (MonitoringOff.isOff(monitor)) {
97
+ return MonitorNotCheckedReason_1.default.MonitoringOff;
98
+ }
99
+ return null;
100
+ }
80
101
  }
81
102
  exports.default = MonitoringOff;
@@ -1,4 +1,4 @@
1
- import NetworkTopology, { NetworkTopologyNodeStatus } from "../../Types/Monitor/SnmpMonitor/NetworkTopology.mjs";
1
+ import NetworkTopology, { NetworkTopologyMonitorNotChecked, NetworkTopologyNodeStatus } from "../../Types/Monitor/SnmpMonitor/NetworkTopology.mjs";
2
2
  import LldpNeighbor from "../../Types/Monitor/SnmpMonitor/LldpNeighbor.mjs";
3
3
  import CdpNeighbor from "../../Types/Monitor/SnmpMonitor/CdpNeighbor.mjs";
4
4
  import { TopologyDeviceRoleInput } from "./NetworkDeviceRoleCatalog.mjs";
@@ -32,6 +32,7 @@ export interface TopologyDeviceInput {
32
32
  controllerProvider?: string | undefined;
33
33
  isEndpointCollectionEnabled?: boolean | undefined;
34
34
  isDescribedByController?: boolean | undefined;
35
+ monitorNotChecked?: NetworkTopologyMonitorNotChecked | undefined;
35
36
  }
36
37
  export interface TopologyInterfaceInput {
37
38
  networkDeviceId: string;
@@ -1,4 +1,4 @@
1
- import NetworkTopology, { NetworkTopologyNodeStatus } from "../../Types/Monitor/SnmpMonitor/NetworkTopology";
1
+ import NetworkTopology, { NetworkTopologyMonitorNotChecked, NetworkTopologyNodeStatus } from "../../Types/Monitor/SnmpMonitor/NetworkTopology";
2
2
  import LldpNeighbor from "../../Types/Monitor/SnmpMonitor/LldpNeighbor";
3
3
  import CdpNeighbor from "../../Types/Monitor/SnmpMonitor/CdpNeighbor";
4
4
  import { TopologyDeviceRoleInput } from "./NetworkDeviceRoleCatalog";
@@ -32,6 +32,7 @@ export interface TopologyDeviceInput {
32
32
  controllerProvider?: string | undefined;
33
33
  isEndpointCollectionEnabled?: boolean | undefined;
34
34
  isDescribedByController?: boolean | undefined;
35
+ monitorNotChecked?: NetworkTopologyMonitorNotChecked | undefined;
35
36
  }
36
37
  export interface TopologyInterfaceInput {
37
38
  networkDeviceId: string;
@@ -253,6 +253,16 @@ class NetworkTopologyUtil {
253
253
  */
254
254
  macAddress: (0, EndpointAttachmentUtil_1.normalizeMac)(device.macAddress),
255
255
  };
256
+ /*
257
+ * Only when there is one, so a node whose monitor is checked - and
258
+ * every node of an older caller - carries no such field at all.
259
+ */
260
+ if (device.monitorNotChecked) {
261
+ deviceNode.monitorNotChecked = {
262
+ monitorId: device.monitorNotChecked.monitorId,
263
+ reason: device.monitorNotChecked.reason,
264
+ };
265
+ }
256
266
  /*
257
267
  * The address it is polled at, when that is an IP: drawn under its
258
268
  * name and searched by (issue #5775). A device registered by a DNS
@@ -1,5 +1,6 @@
1
1
  import Monitor from "../../Models/DatabaseModels/Monitor.mjs";
2
2
  import Query from "../../Types/BaseDatabase/Query.mjs";
3
+ import ObjectID from "../../Types/ObjectID.mjs";
3
4
  export default class NotOperationalMonitorQuery {
4
- static getQuery(): Query<Monitor>;
5
+ static getQuery(projectId?: ObjectID | string | null | undefined): Query<Monitor>;
5
6
  }
@@ -1,5 +1,6 @@
1
1
  import Monitor from "../../Models/DatabaseModels/Monitor";
2
2
  import Query from "../../Types/BaseDatabase/Query";
3
+ import ObjectID from "../../Types/ObjectID";
3
4
  export default class NotOperationalMonitorQuery {
4
- static getQuery(): Query<Monitor>;
5
+ static getQuery(projectId?: ObjectID | string | null | undefined): Query<Monitor>;
5
6
  }
@@ -3,6 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
+ const ObjectID_1 = __importDefault(require("../../Types/ObjectID"));
6
7
  const MonitoringOff_1 = __importDefault(require("./MonitoringOff"));
7
8
  /*
8
9
  * WHICH MONITORS ARE NOT OPERATIONAL.
@@ -30,10 +31,28 @@ const MonitoringOff_1 = __importDefault(require("./MonitoringOff"));
30
31
  * problemsOnly. The checked monitors are MonitoringOff's.
31
32
  */
32
33
  class NotOperationalMonitorQuery {
33
- static getQuery() {
34
- return Object.assign(Object.assign({}, MonitoringOff_1.default.getMonitoredQuery()), { currentMonitorStatus: {
35
- isOperationalState: false,
36
- } });
34
+ /*
35
+ * Given the project the monitors are read in, the status is asked of that
36
+ * project too (issue #8096). A monitor's statuses are its project's own,
37
+ * so the answer is the same, but Postgres can then start from the
38
+ * project's few statuses that are not operational and read only the
39
+ * monitors that hold one (the index on currentMonitorStatusId), where it
40
+ * otherwise reads every monitor of the project and joins each to its
41
+ * status: 1,915 buffers instead of 8,585 for a count in a project of
42
+ * 20,000 monitors. Every Not Operational count and list that knows its
43
+ * project passes it; a list also counts what it lists.
44
+ */
45
+ static getQuery(projectId) {
46
+ return Object.assign(Object.assign({}, MonitoringOff_1.default.getMonitoredQuery()), { currentMonitorStatus: projectId
47
+ ? {
48
+ isOperationalState: false,
49
+ projectId: projectId instanceof ObjectID_1.default
50
+ ? projectId
51
+ : new ObjectID_1.default(projectId),
52
+ }
53
+ : {
54
+ isOperationalState: false,
55
+ } });
37
56
  }
38
57
  }
39
58
  exports.default = NotOperationalMonitorQuery;
@@ -0,0 +1,10 @@
1
+ import { Translator } from "../../Types/Translator.mjs";
2
+ export declare const getProbeAgreementRequiredCount: (data: {
3
+ minimumProbeAgreement: number | null | undefined;
4
+ activeProbeCount: number;
5
+ }) => number;
6
+ export declare const getProbeAgreementSentence: (data: {
7
+ minimumProbeAgreement: number | null | undefined;
8
+ activeProbeCount: number;
9
+ translator: Translator;
10
+ }) => string | null;