Class RecurringMaintenanceWindow

    • Field Detail

      • CHECK_INTERVAL_MINUTES

        @Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
        public static int CHECK_INTERVAL_MINUTES
      • LEAD_TIME_DAYS

        @Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
        public static int LEAD_TIME_DAYS
    • Constructor Detail

      • RecurringMaintenanceWindow

        @DataBoundConstructor
        public RecurringMaintenanceWindow​(String startTimeSpec,
                                          String reason,
                                          boolean takeOnline,
                                          boolean keepUpWhenActive,
                                          String maxWaitMinutes,
                                          String duration,
                                          String userid,
                                          String id,
                                          long nextCheck)
        Creates a new recurring maintenance window.
        Parameters:
        startTimeSpec - Start time
        reason - Reason
        takeOnline - Take online at end of maintenance
        keepUpWhenActive - Keep up while builds are running
        maxWaitMinutes - Max waiting time before canceling running builds.
        duration - Duration of the maintenance
        userid - Userid that created the maintenance window
        id - ID of the maintenance, use null to generate a new id
        nextCheck - timestamp when the next check should be performed
        Throws:
        ANTLRException - When parsing the crontab list fails
    • Method Detail

      • getStartTimeSpec

        public String getStartTimeSpec()
      • getDuration

        public int getDuration()
      • getReason

        public String getReason()
      • isTakeOnline

        public boolean isTakeOnline()
      • isKeepUpWhenActive

        public boolean isKeepUpWhenActive()
      • getMaxWaitMinutes

        public String getMaxWaitMinutes()
      • getUserid

        public String getUserid()
      • getNextCheck

        @Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
        public long getNextCheck()
      • getId

        @Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
        public String getId()
      • getFutureMaintenanceWindows

        @NonNull
        @Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class)
        public Set<MaintenanceWindow> getFutureMaintenanceWindows()
        Returns a list of maintenance windows that should be put into the scheduled maintenance windows of an agent. Updates the nextCheck interval for the recurring window.
        Returns:
        The list of maintenance windows.
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object