Class TimeBasedFailure

  • All Implemented Interfaces:
    ObservableIfc, GetNameIfc, IdentityIfc

    public class TimeBasedFailure
    extends FailureProcess
    A TimeBasedFailure uses time to determine the next failure. By default the failure process does not start automatically at time zero. The user can turn on automatic starting of the failure process at time zero or use the start() method. Once the failure process has been started it cannot be started again. Once the failure process has been stopped, it cannot be started again.
    • Method Detail

      • setTimeBetweenFailureEvents

        public final void setTimeBetweenFailureEvents​(RandomIfc tbf)
        Sets the time between failures source of randomness
        Parameters:
        tbf - the time between failure
      • failureNoticeActivated

        protected void failureNoticeActivated​(FailureNotice fn)
        Description copied from class: FailureProcess
        When a FailureNotice is made active, this method is called. Called from FailureNotice.CreatedState or FailureNotice.DelayedState when activate() is called. A FailureNotice is activated from ResourceUnit when scheduling the end of failure for the generated FailureNotice using ResourceUnit's scheduleEndOfFailure(FailureNotice failureNotice). If the FailureNotice is not delayed then it is activated immediately upon the ResourceUnit receiving the failure notice. If the FailureNotice is delayed, then after the delay it is activated This can be used to react to the notices becoming active. A FailureNotice becoming active means that the failure has started (taking down the resource unit).
        Specified by:
        failureNoticeActivated in class FailureProcess
        Parameters:
        fn - the failure notice
      • failureNoticeDelayed

        protected void failureNoticeDelayed​(FailureNotice fn)
        Description copied from class: FailureProcess
        When a FailureNotice is delayed, this method is called. This can be used to react to the notice becoming delayed.
        Specified by:
        failureNoticeDelayed in class FailureProcess
        Parameters:
        fn - the failure notice
      • failureNoticeIgnored

        protected void failureNoticeIgnored​(FailureNotice fn)
        Description copied from class: FailureProcess
        When a FailureNotice is ignored, this method is called. This can be used to react to the notice becoming ignored.
        Specified by:
        failureNoticeIgnored in class FailureProcess
        Parameters:
        fn - the failure notice
      • failureNoticeCompleted

        protected void failureNoticeCompleted​(FailureNotice fn)
        Description copied from class: FailureProcess
        When a FailureNotice is completed, this method is called. This can be used to react to the notice becoming completed.
        Specified by:
        failureNoticeCompleted in class FailureProcess
        Parameters:
        fn - the failure notice