Project

General

Profile

Actions

Bug #10671

closed

[API Server] Fill in finish time when pipeline instance is marked with final state

Added by Tom Morris about 8 years ago. Updated almost 8 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Category:
-
Target version:
Story points:
0.5

Subtasks 1 (0 open1 closed)

Task #10736: Review 10671-pipeline-instance-finish-timeResolvedLucas Di Pentima12/06/2016Actions

Related issues 1 (0 open1 closed)

Related to Arvados - Bug #10516: [CWL][Workbench] Update stats calculations for CWL running on Crunch v1ResolvedRadhika Chippada01/04/2017Actions
Actions #1

Updated by Tom Morris about 8 years ago

  • Target version set to Arvados Future Sprints
  • Story points set to 0.5

If the client provides no end time or it's null then the API server fills in the current time.

Actions #2

Updated by Tom Morris about 8 years ago

  • Target version changed from Arvados Future Sprints to 2017-01-04 sprint
Actions #3

Updated by Lucas Di Pentima about 8 years ago

  • Assigned To set to Lucas Di Pentima
Actions #4

Updated by Lucas Di Pentima about 8 years ago

  • Status changed from New to In Progress
Actions #5

Updated by Lucas Di Pentima about 8 years ago

Test run: https://ci.curoverse.com/job/developer-run-tests/111/ (test run 110 failed on sdk/python but didn't on my local run, so re-running to see if it was just a temporary issue)
Updated: 4115524460e89f36b99f2fb5de1adebd86daaf4a

Added a before_save filter to PipelineInstance model to update started_at and finished_at dates when changing states.

Actions #6

Updated by Tom Clegg about 8 years ago

I think it would be good to ensure started_at isn't nil when changing state to Failed or Complete too, in case a client creates a new object with state=Complete.

I don't think it would affect anything in practice as things stand, but I think conceptually (and for the sake of our future selves) this should be before_validation rather than before_save -- e.g., if we were validating started_at and finished_at, we would want to validate after applying these defaults, not after.

other than those points, LGTM

Actions #7

Updated by Lucas Di Pentima about 8 years ago

Updates: 4f03b29b3efb42a48c3f397942d5b618b89390eb
Test running at https://ci.curoverse.com/job/developer-run-tests/114/

When the pipeline instances is finished (either completed or failed) and started_at is nil, it will have the exact same time as finished_at.

Actions #8

Updated by Lucas Di Pentima about 8 years ago

  • Status changed from In Progress to Resolved

Applied in changeset arvados|commit:96d90c859cede094d83cbaf5409418e9ab0c2c19.

Actions

Also available in: Atom PDF