Uploaded image for project: 'Marathon'
  1. Marathon
  2. MARATHON-8242

Reservation.State not properly used

    Details

    • Type: Task
    • Status: Open
    • Priority: Medium
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: State Handling
    • Labels:

      Description

      When working with resident instances during my refactoring I found out that the way we deal with Reservation.State is probably broken.

      How is this currently used is:

      1. the state holds a timeout (which is applicable only for the new state)
      2. it's serialized into ZK state

      Supported list of states can be found here: https://github.com/mesosphere/marathon/blob/7b06d364fad70165049f41fbc50275bed8b00b29/src/main/scala/mesosphere/marathon/core/instance/Reservation.scala#L57

      Why it does not work right now:

      1. We don't use Garbage, Unknown and Launched state
      2. When we move to Suspended state, we don't change the state when we relaunch on that reservation

      Which brings me into following questions:

      1. Do we need these states? (and if yes, which one - isn't New and Confirmed potentially enough?)
        1. We should consider if we won't need these states to support updating resources for resident tasks
      2. Should we handle the states correctly in the current codebase? (meaning if we launch a resident task, should we move the state to Launched?)

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              alenavarkockova Alena Varkockova
              Team:
              Orchestration Team
              Watchers:
              Alena Varkockova
            • Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: