Skip to content
This repository has been archived by the owner on Oct 9, 2023. It is now read-only.

Fix PhaseStatus that gets displayed for Presto tasks #74

Merged
merged 1 commit into from
Apr 2, 2020

Conversation

lu4nm3
Copy link
Contributor

@lu4nm3 lu4nm3 commented Apr 2, 2020

TL;DR

When running a Presto task, the status of each of the 5 queries is not displayed properly.
Screen Shot 2020-04-02 at 2 04 27 PM

Type

  • Bug Fix
  • Feature
  • Plugin

Are all requirements met?

  • Code completed
  • Smoke tested
  • Unit tests added
  • Code documentation added
  • Any pending items have an associated Issue

Complete description

Due to how the state machine the Presto plugin uses goes back and forth between various states, I keep track of the of both the current and previous states and use the previous state for the status that gets displayed to users.

Tracking Issue

flyteorg/flyte#237

@lu4nm3 lu4nm3 requested a review from wild-endeavor April 2, 2020 21:10
@wild-endeavor
Copy link
Contributor

So what's the end result of this? The text for each log link still moves through the phases right? Like the first one will appear queued, then running, then succeeded, and then the next one will show up queued. etc.

If we're storing the individual query IDs, and they're always run serially, and you only launch the next one if the current one succeeds, then we can also just always assume that all the previous ones are in a succeeded state right?

@lu4nm3
Copy link
Contributor Author

lu4nm3 commented Apr 2, 2020

@wild-endeavor Yeah that seems like a reasonable assumption to make. The part where it sets the previous status for the last time (ie. succeeded) is here.

@lu4nm3
Copy link
Contributor Author

lu4nm3 commented Apr 2, 2020

The problem that was happening is that after each query, we set the phase to "queued" (so that it can keep advancing through all 5 queries). However, because this is set to "queued" it keeps that phase through to when it gets logged and that's why it shows up that way in the UI

@lu4nm3 lu4nm3 merged commit c147f6e into master Apr 2, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants