Uploaded image for project: 'Razor'
  1. Razor
  2. RAZOR-787

Add status to repo

    XMLWordPrintable

Details

    • Story
    • Status: Ready for Engineering
    • Major
    • Resolution: Unresolved
    • None
    • None
    • Client, Server
    • Hide

      Run the `create-repo` command with the `iso-url` argument. `razor repos` shows `downloading` until install completes, `extracting` while it is extracting (to test, try large zip file available locally using `file://` protocol), then `finished` when it is done.
      Run the `create-repo` command with an invalid `iso-url` argument. `razor repos` shows `transient-error` until it fails too many times, at which point the `razor repos` status changes to `errored`.

      Show
      Run the `create-repo` command with the `iso-url` argument. `razor repos` shows `downloading` until install completes, `extracting` while it is extracting (to test, try large zip file available locally using ` file:// ` protocol), then `finished` when it is done. Run the `create-repo` command with an invalid `iso-url` argument. `razor repos` shows `transient-error` until it fails too many times, at which point the `razor repos` status changes to `errored`.
    • 3

    Description

      When a repo is created, it is either fully formed (`--no-content` or `--url`) or requires asynchronous work to be usable. In the latter case, this status is currently tracked in a command, which is an unnecessary layer of indirection.

      Better than linking the repo to its create-repo command in order to determine the download/extract status, the repo itself should hold the status so that installation can act on this state.

      Use Case

      • A user creates a repo using `iso-url`.
      • While the ISO file is downloading, the user views the `razor repos` collection.
      • The `razor repos` collection contains no information on its status, even though it is not ready yet.

      In Scope

      • Add `create_command` field to repo.
      • Link respective `create-repo` command to repo.
      • Update `create-repo` command to say that the repo will be downloaded asynchronously when it will (`iso-url` supplied)
      • Add `repo.create_command.status` to repo view in view.rb.
      • Update command status values to the more descriptive `pending`, `downloading`, `extracting`, `finished`, `error-retry`, and `failed` statuses (currently `pending`, `running`, `finished`, `failed`).
      • Update command status when created, download starts, extract starts, and extract/move finishes.
      • Use status `transient-error` if there is an error which will be retried (e.g. 404).
      • Use status `errored` when the error is fatal/retried for the last time.
      • Client: Show the repo's status in `razor repos` via views.yaml.

      Optional

      • Include the progress of the download (percent complete?)

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              scott.mcclellan Scott McClellan
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:

                Zendesk Support