Class Downtime

java.lang.Object
com.datadog.api.client.v1.model.Downtime

@Generated("https://github.com/DataDog/datadog-api-client-java/blob/master/.generator") public class Downtime extends Object
Downtiming gives you greater control over monitor notifications by allowing you to globally exclude scopes from alerting. Downtime settings, which can be scheduled with start and end times, prevent all alerting related to specified Datadog tags.
  • Field Details

  • Constructor Details

    • Downtime

      public Downtime()
  • Method Details

    • getActive

      @Nullable public Boolean getActive()
      If a scheduled downtime currently exists.
      Returns:
      active
    • getActiveChild

      @Nullable public DowntimeChild getActiveChild()
      The downtime object definition of the active child for the original parent recurring downtime. This field will only exist on recurring downtimes.
      Returns:
      activeChild
    • getActiveChild_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<DowntimeChild> getActiveChild_JsonNullable()
    • getCanceled

      @Nullable public Long getCanceled()
      If a scheduled downtime is canceled.
      Returns:
      canceled
    • getCanceled_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<Long> getCanceled_JsonNullable()
    • getCreatorId

      @Nullable public Integer getCreatorId()
      User ID of the downtime creator. maximum: 2147483647
      Returns:
      creatorId
    • disabled

      public Downtime disabled(Boolean disabled)
    • getDisabled

      @Nullable public Boolean getDisabled()
      If a downtime has been disabled.
      Returns:
      disabled
    • setDisabled

      public void setDisabled(Boolean disabled)
    • getDowntimeType

      @Nullable public Integer getDowntimeType()
      0 for a downtime applied on * or all, 1 when the downtime is only scoped to hosts, or 2 when the downtime is scoped to anything but hosts. maximum: 2147483647
      Returns:
      downtimeType
    • end

      public Downtime end(Long end)
    • getEnd

      @Nullable public Long getEnd()
      POSIX timestamp to end the downtime. If not provided, the downtime is in effect indefinitely until you cancel it.
      Returns:
      end
    • getEnd_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<Long> getEnd_JsonNullable()
    • setEnd_JsonNullable

      public void setEnd_JsonNullable(org.openapitools.jackson.nullable.JsonNullable<Long> end)
    • setEnd

      public void setEnd(Long end)
    • getId

      @Nullable public Long getId()
      The downtime ID.
      Returns:
      id
    • message

      public Downtime message(String message)
    • getMessage

      @Nullable public String getMessage()
      A message to include with notifications for this downtime. Email notifications can be sent to specific users by using the same @username notation as events.
      Returns:
      message
    • getMessage_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<String> getMessage_JsonNullable()
    • setMessage_JsonNullable

      public void setMessage_JsonNullable(org.openapitools.jackson.nullable.JsonNullable<String> message)
    • setMessage

      public void setMessage(String message)
    • monitorId

      public Downtime monitorId(Long monitorId)
    • getMonitorId

      @Nullable public Long getMonitorId()
      A single monitor to which the downtime applies. If not provided, the downtime applies to all monitors.
      Returns:
      monitorId
    • getMonitorId_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<Long> getMonitorId_JsonNullable()
    • setMonitorId_JsonNullable

      public void setMonitorId_JsonNullable(org.openapitools.jackson.nullable.JsonNullable<Long> monitorId)
    • setMonitorId

      public void setMonitorId(Long monitorId)
    • monitorTags

      public Downtime monitorTags(List<String> monitorTags)
    • addMonitorTagsItem

      public Downtime addMonitorTagsItem(String monitorTagsItem)
    • getMonitorTags

      @Nullable public List<String> getMonitorTags()
      A comma-separated list of monitor tags. For example, tags that are applied directly to monitors, not tags that are used in monitor queries (which are filtered by the scope parameter), to which the downtime applies. The resulting downtime applies to monitors that match ALL provided monitor tags. For example, service:postgres AND team:frontend.
      Returns:
      monitorTags
    • setMonitorTags

      public void setMonitorTags(List<String> monitorTags)
    • muteFirstRecoveryNotification

      public Downtime muteFirstRecoveryNotification(Boolean muteFirstRecoveryNotification)
    • getMuteFirstRecoveryNotification

      @Nullable public Boolean getMuteFirstRecoveryNotification()
      If the first recovery notification during a downtime should be muted.
      Returns:
      muteFirstRecoveryNotification
    • setMuteFirstRecoveryNotification

      public void setMuteFirstRecoveryNotification(Boolean muteFirstRecoveryNotification)
    • notifyEndStates

      public Downtime notifyEndStates(List<NotifyEndState> notifyEndStates)
    • addNotifyEndStatesItem

      public Downtime addNotifyEndStatesItem(NotifyEndState notifyEndStatesItem)
    • getNotifyEndStates

      @Nullable public List<NotifyEndState> getNotifyEndStates()
      States for which notify_end_types sends out notifications for.
      Returns:
      notifyEndStates
    • setNotifyEndStates

      public void setNotifyEndStates(List<NotifyEndState> notifyEndStates)
    • notifyEndTypes

      public Downtime notifyEndTypes(List<NotifyEndType> notifyEndTypes)
    • addNotifyEndTypesItem

      public Downtime addNotifyEndTypesItem(NotifyEndType notifyEndTypesItem)
    • getNotifyEndTypes

      @Nullable public List<NotifyEndType> getNotifyEndTypes()
      If set, notifies if a monitor is in an alert-worthy state (ALERT, WARNING , or NO DATA) when this downtime expires or is canceled. Applied to monitors that change states during the downtime (such as from OK to ALERT , WARNING, or NO DATA), and to monitors that already have an alert-worthy state when downtime begins.
      Returns:
      notifyEndTypes
    • setNotifyEndTypes

      public void setNotifyEndTypes(List<NotifyEndType> notifyEndTypes)
    • parentId

      public Downtime parentId(Long parentId)
    • getParentId

      @Nullable public Long getParentId()
      ID of the parent Downtime.
      Returns:
      parentId
    • getParentId_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<Long> getParentId_JsonNullable()
    • setParentId_JsonNullable

      public void setParentId_JsonNullable(org.openapitools.jackson.nullable.JsonNullable<Long> parentId)
    • setParentId

      public void setParentId(Long parentId)
    • recurrence

      public Downtime recurrence(DowntimeRecurrence recurrence)
    • getRecurrence

      @Nullable public DowntimeRecurrence getRecurrence()
      An object defining the recurrence of the downtime.
      Returns:
      recurrence
    • getRecurrence_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<DowntimeRecurrence> getRecurrence_JsonNullable()
    • setRecurrence_JsonNullable

      public void setRecurrence_JsonNullable(org.openapitools.jackson.nullable.JsonNullable<DowntimeRecurrence> recurrence)
    • setRecurrence

      public void setRecurrence(DowntimeRecurrence recurrence)
    • scope

      public Downtime scope(List<String> scope)
    • addScopeItem

      public Downtime addScopeItem(String scopeItem)
    • getScope

      @Nullable public List<String> getScope()
      The scope(s) to which the downtime applies and must be in key:value format. For example, host:app2. Provide multiple scopes as a comma-separated list like env:dev,env:prod. The resulting downtime applies to sources that matches ALL provided scopes (env:dev AND env:prod).
      Returns:
      scope
    • setScope

      public void setScope(List<String> scope)
    • start

      public Downtime start(Long start)
    • getStart

      @Nullable public Long getStart()
      POSIX timestamp to start the downtime. If not provided, the downtime starts the moment it is created.
      Returns:
      start
    • setStart

      public void setStart(Long start)
    • timezone

      public Downtime timezone(String timezone)
    • getTimezone

      @Nullable public String getTimezone()
      The timezone in which to display the downtime's start and end times in Datadog applications.
      Returns:
      timezone
    • setTimezone

      public void setTimezone(String timezone)
    • getUpdaterId

      @Nullable public Integer getUpdaterId()
      ID of the last user that updated the downtime. maximum: 2147483647
      Returns:
      updaterId
    • getUpdaterId_JsonNullable

      public org.openapitools.jackson.nullable.JsonNullable<Integer> getUpdaterId_JsonNullable()
    • putAdditionalProperty

      public Downtime putAdditionalProperty(String key, Object value)
      Set the additional (undeclared) property with the specified name and value. If the property does not already exist, create it otherwise replace it.
      Parameters:
      key - The arbitrary key to set
      value - The associated value
      Returns:
      Downtime
    • getAdditionalProperties

      public Map<String,Object> getAdditionalProperties()
      Return the additional (undeclared) property.
      Returns:
      The additional properties
    • getAdditionalProperty

      public Object getAdditionalProperty(String key)
      Return the additional (undeclared) property with the specified name.
      Parameters:
      key - The arbitrary key to get
      Returns:
      The specific additional property for the given key
    • equals

      public boolean equals(Object o)
      Return true if this Downtime object is equal to o.
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object