update_maintenance_window
async
¶
update_maintenance_window(
window_id: MaintenanceWindowId,
*,
config_overrides: Optional[AsyncSSMClientConfig] = None,
name: Optional[MaintenanceWindowName] = None,
description: Optional[MaintenanceWindowDescription] = None,
start_date: Optional[MaintenanceWindowStringDateTime] = None,
end_date: Optional[MaintenanceWindowStringDateTime] = None,
schedule: Optional[MaintenanceWindowSchedule] = None,
schedule_timezone: Optional[MaintenanceWindowTimezone] = None,
schedule_offset: Optional[MaintenanceWindowOffset] = None,
duration: Optional[MaintenanceWindowDurationHours] = None,
cutoff: Optional[MaintenanceWindowCutoff] = None,
allow_unassociated_targets: Optional[
MaintenanceWindowAllowUnassociatedTargets
] = None,
enabled: Optional[MaintenanceWindowEnabled] = None,
replace: Optional[Boolean] = None,
) -> UpdateMaintenanceWindowResult
Updates an existing maintenance window. Only specified parameters are modified.
The value you specify for Duration determines the specific end time for the maintenance window based on the time it begins. No maintenance window tasks are permitted to start after the resulting endtime minus the number of hours you specify for Cutoff. For example, if the maintenance window starts at 3 PM, the duration is three hours, and the value you specify for Cutoff is one hour, no maintenance window tasks can start after 5 PM.
Parameters:
-
window_id(MaintenanceWindowId) –The ID of the maintenance window to update.
-
name(Optional[MaintenanceWindowName], default:None) –The name of the maintenance window.
-
description(Optional[MaintenanceWindowDescription], default:None) –An optional description for the update request.
-
start_date(Optional[MaintenanceWindowStringDateTime], default:None) –The date and time, in ISO-8601 Extended format, for when you want the maintenance window to become active.
StartDateallows you to delay activation of the maintenance window until the specified future date.When using a rate schedule, if you provide a start date that occurs in the past, the current date and time are used as the start date.
-
end_date(Optional[MaintenanceWindowStringDateTime], default:None) –The date and time, in ISO-8601 Extended format, for when you want the maintenance window to become inactive.
EndDateallows you to set a date and time in the future when the maintenance window will no longer run. -
schedule(Optional[MaintenanceWindowSchedule], default:None) –The schedule of the maintenance window in the form of a cron or rate expression.
-
schedule_timezone(Optional[MaintenanceWindowTimezone], default:None) –The time zone that the scheduled maintenance window executions are based on, in Internet Assigned Numbers Authority (IANA) format. For example: "America/Los_Angeles", "UTC", or "Asia/Seoul". For more information, see the Time Zone Database on the IANA website.
-
schedule_offset(Optional[MaintenanceWindowOffset], default:None) –The number of days to wait after the date and time specified by a cron expression before running the maintenance window.
For example, the following cron expression schedules a maintenance window to run the third Tuesday of every month at 11:30 PM.
cron(30 23 ? * TUE#3 *)If the schedule offset is
2, the maintenance window won't run until two days later. -
duration(Optional[MaintenanceWindowDurationHours], default:None) –The duration of the maintenance window in hours.
-
cutoff(Optional[MaintenanceWindowCutoff], default:None) –The number of hours before the end of the maintenance window that Amazon Web Services Systems Manager stops scheduling new tasks for execution.
-
allow_unassociated_targets(Optional[MaintenanceWindowAllowUnassociatedTargets], default:None) –Whether targets must be registered with the maintenance window before tasks can be defined for those targets.
-
enabled(Optional[MaintenanceWindowEnabled], default:None) –Whether the maintenance window is enabled.
-
replace(Optional[Boolean], default:None) –If
True, then all fields that are required by the CreateMaintenanceWindow operation are also required for this API request. Optional fields that aren't specified are set to null.
Raises:
-
DoesNotExistException–Error returned when the ID specified for a resource, such as a maintenance window or patch baseline, doesn't exist.
For information about resource quotas in Amazon Web Services Systems Manager, see Systems Manager service quotas in the Amazon Web Services General Reference.
-
InternalServerError–An error occurred on the server side.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_ssm/_services/async_ssm.py
11779 11780 11781 11782 11783 11784 11785 11786 11787 11788 11789 11790 11791 11792 11793 11794 11795 11796 11797 11798 11799 11800 11801 11802 11803 11804 11805 11806 11807 11808 11809 11810 11811 11812 11813 11814 11815 11816 11817 11818 11819 11820 11821 11822 11823 11824 11825 11826 11827 11828 11829 11830 11831 11832 11833 11834 11835 11836 11837 11838 11839 11840 11841 11842 11843 11844 11845 11846 11847 11848 11849 11850 11851 11852 11853 11854 11855 11856 11857 11858 11859 11860 11861 11862 11863 11864 11865 11866 11867 11868 11869 11870 11871 11872 11873 11874 11875 11876 11877 11878 11879 11880 11881 11882 11883 11884 11885 11886 11887 11888 11889 11890 11891 11892 11893 11894 11895 11896 11897 11898 11899 11900 11901 11902 11903 11904 11905 11906 11907 11908 11909 11910 11911 11912 11913 11914 11915 11916 11917 11918 11919 | |