qontract-reconcile 0.10.1rc823__py3-none-any.whl → 0.10.1rc824__py3-none-any.whl
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.
- {qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/METADATA +1 -1
- {qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/RECORD +6 -6
- reconcile/statuspage/atlassian.py +27 -6
- {qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/WHEEL +0 -0
- {qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/entry_points.txt +0 -0
- {qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/top_level.txt +0 -0
{qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/METADATA
RENAMED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: qontract-reconcile
|
3
|
-
Version: 0.10.
|
3
|
+
Version: 0.10.1rc824
|
4
4
|
Summary: Collection of tools to reconcile services with their desired state as defined in the app-interface DB.
|
5
5
|
Home-page: https://github.com/app-sre/qontract-reconcile
|
6
6
|
Author: Red Hat App-SRE Team
|
{qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/RECORD
RENAMED
@@ -438,7 +438,7 @@ reconcile/skupper_network/models.py,sha256=DNTI7HZv-rqY42GIIxyRuvroHLvdH6rJerjIq
|
|
438
438
|
reconcile/skupper_network/reconciler.py,sha256=XS-1oKBr_1l3dYUAVqUH6gCHg1G5ZuOfY_7fgGVAiFA,9996
|
439
439
|
reconcile/skupper_network/site_controller.py,sha256=A3K-62BjJ5HiFVydV0ouGoD1NwrO7XhAH15BHAcS9fk,1550
|
440
440
|
reconcile/statuspage/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
441
|
-
reconcile/statuspage/atlassian.py,sha256=
|
441
|
+
reconcile/statuspage/atlassian.py,sha256=5awxH9ovbtgis_N4aabBvrlo2ZyLNLaO6ezIYDgVq0Y,18571
|
442
442
|
reconcile/statuspage/integration.py,sha256=hsazrQMceJbr61nEkJLxJbHhudTGtFuH0mlCo66-2ug,711
|
443
443
|
reconcile/statuspage/page.py,sha256=WHDwV2PXEo4WwI2EgPOkS6j_T7geZEDXTgSaqpDo75U,5101
|
444
444
|
reconcile/statuspage/state.py,sha256=HD9EOoKm_nEqCMLIwW809En3cq5VhyzKJPUbsh-bae8,1617
|
@@ -811,8 +811,8 @@ tools/test/test_app_interface_metrics_exporter.py,sha256=SX7qL3D1SIRKFo95FoQztvf
|
|
811
811
|
tools/test/test_qontract_cli.py,sha256=_D61RFGAN5x44CY1tYbouhlGXXABwYfxKSWSQx3Jrss,4941
|
812
812
|
tools/test/test_sd_app_sre_alert_report.py,sha256=v363r9zM7__0kR5K6mvJoGFcM9BvE33fWAayrqkpojA,2116
|
813
813
|
tools/test/test_sre_checkpoints.py,sha256=SKqPPTl9ua0RFdSSofnoQX-JZE6dFLO3LRhfQzqtfh8,2607
|
814
|
-
qontract_reconcile-0.10.
|
815
|
-
qontract_reconcile-0.10.
|
816
|
-
qontract_reconcile-0.10.
|
817
|
-
qontract_reconcile-0.10.
|
818
|
-
qontract_reconcile-0.10.
|
814
|
+
qontract_reconcile-0.10.1rc824.dist-info/METADATA,sha256=BuGUQL722lQm08tOKAkp1LW3RG0QP8YMMcot9jZ4DIM,2314
|
815
|
+
qontract_reconcile-0.10.1rc824.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
|
816
|
+
qontract_reconcile-0.10.1rc824.dist-info/entry_points.txt,sha256=GKQqCl2j2X1BJQ69een6rHcR26PmnxnONLNOQB-nRjY,491
|
817
|
+
qontract_reconcile-0.10.1rc824.dist-info/top_level.txt,sha256=l5ISPoXzt0SdR4jVdkfa7RPSKNc8zAHYWAnR-Dw8Ey8,24
|
818
|
+
qontract_reconcile-0.10.1rc824.dist-info/RECORD,,
|
@@ -56,9 +56,9 @@ class AtlassianRawMaintenance(BaseModel):
|
|
56
56
|
scheduled_until: str
|
57
57
|
incident_updates: list[AtlassianRawMaintenanceUpdate]
|
58
58
|
components: list[AtlassianRawComponent]
|
59
|
-
auto_transition_deliver_notifications_at_end: bool
|
60
|
-
auto_transition_deliver_notifications_at_start: bool
|
61
|
-
scheduled_remind_prior: bool
|
59
|
+
auto_transition_deliver_notifications_at_end: Optional[bool]
|
60
|
+
auto_transition_deliver_notifications_at_start: Optional[bool]
|
61
|
+
scheduled_remind_prior: Optional[bool]
|
62
62
|
|
63
63
|
|
64
64
|
class AtlassianAPI:
|
@@ -301,8 +301,15 @@ class AtlassianStatusPageProvider:
|
|
301
301
|
|
302
302
|
# component status
|
303
303
|
desired_component_status = desired.desired_component_status()
|
304
|
-
|
305
|
-
|
304
|
+
active_maintenance_affecting_component = [
|
305
|
+
m
|
306
|
+
for m in self.active_maintenances
|
307
|
+
if desired.display_name in [c.name for c in m.components]
|
308
|
+
]
|
309
|
+
status_update_required = (
|
310
|
+
desired_component_status is not None
|
311
|
+
and (not current or desired_component_status != current.status)
|
312
|
+
and not active_maintenance_affecting_component
|
306
313
|
)
|
307
314
|
|
308
315
|
# shortcut execution if there is nothing to do
|
@@ -326,7 +333,7 @@ class AtlassianStatusPageProvider:
|
|
326
333
|
component_id=current_component.id,
|
327
334
|
)
|
328
335
|
|
329
|
-
#
|
336
|
+
# validate the component and check if the current state needs to be updated
|
330
337
|
needs_update = self.should_apply(desired, current_component)
|
331
338
|
if not needs_update:
|
332
339
|
return
|
@@ -456,12 +463,26 @@ class AtlassianStatusPageProvider:
|
|
456
463
|
]
|
457
464
|
|
458
465
|
def create_maintenance(self, maintenance: StatusMaintenance) -> None:
|
466
|
+
component_ids: list[str] = []
|
467
|
+
for sc in maintenance.components:
|
468
|
+
current_component, _ = self.lookup_component(sc)
|
469
|
+
if current_component:
|
470
|
+
component_ids.append(current_component.id)
|
459
471
|
data = {
|
460
472
|
"name": maintenance.name,
|
461
473
|
"status": "scheduled",
|
462
474
|
"scheduled_for": maintenance.schedule_start,
|
463
475
|
"scheduled_until": maintenance.schedule_end,
|
464
476
|
"body": maintenance.message,
|
477
|
+
"scheduled_remind_prior": maintenance.announcements.remind_subscribers,
|
478
|
+
"scheduled_auto_transition": True,
|
479
|
+
"scheduled_auto_in_progress": True,
|
480
|
+
"scheduled_auto_completed": True,
|
481
|
+
"component_ids": component_ids,
|
482
|
+
"auto_transition_to_maintenance_state": True,
|
483
|
+
"auto_transition_to_operational_state": True,
|
484
|
+
"auto_transition_deliver_notifications_at_start": maintenance.announcements.notify_subscribers_on_start,
|
485
|
+
"auto_transition_deliver_notifications_at_end": maintenance.announcements.notify_subscribers_on_completion,
|
465
486
|
}
|
466
487
|
incident_id = self._api.create_incident(data)
|
467
488
|
self._bind_component(
|
File without changes
|
File without changes
|
{qontract_reconcile-0.10.1rc823.dist-info → qontract_reconcile-0.10.1rc824.dist-info}/top_level.txt
RENAMED
File without changes
|