refactor(collection): frontend collection expects the "run end time" in its UI #1944
Closed
5 tasks done
Labels
refactor
A code change that neither fixes a bug nor adds a feature
Projects
In
logbook
, we are currently using theCommitTime
in thedsref.VersionInfo
in place of aRunTime
when we convert logs into version infos. This has been working fine from the view point of theActivity
feed, because each version info is only there to describe a single run or a single commit, not the dataset as a whole. So based on whether or not a version info has aRunID
(in this context), you can determine whether or not we are talking about a "run" activity or a "commit" activity.However, this is muddied in the
Collection
view. Since theVersionInfo
in theCollection
view models the entire dataset as a whole, we have it structured that a user may have commit information from one run as well as run information about another run in the same version.For example. If we run a workflow that successfully produces a commit, we catch that information in the
Collection
, which updates theRunID
,RunDuration
,RunCount
,RunStatus
,CommitCount
,CommitTitle
,CommitMessage
,Path
, andCommitTime
.Next, we run a workflow which runs successfully, but does not produce a commit (no changes). The collection will update the
RunID
,RunDuration
,RunCount
, andRunStatus
, but leave theCommit
specific fields alone.So that means in two different parts of our codebase, the
CommitTime
field can maybe be theRunTime
or theCommitTime
, or is always theCommitTime
.Frontend, similarly, has been using
CommitTime
to correctly mean theRunTime
in theActivityLog
,CommitTime
in theDatasetHistory
, and incorrectly meanRunTime
in theCollection
I see two ways to solve:
RunTime
that tracks the start of a run. We can use theRunTime
+RunDuration
if we need to track the run end timeCommitTime
field toTime
, and consider it theRunTime
when there is aRunID
, or theCommitTime
when there is noRunID
. I think this is dumb & we should definitely do the former.RunTime
to theVersionInfo
definitionrunItemFromOp
inlogbook
to pass the time into theRunTime
field, rather thanCommitTime
ETLogbookWriteRun
event to pass therunState.StartTime
inWriteTransformRun
Collection
to store theRunTime
from theETLogbookWriteRun
eventRunTime
recorded correctly & is not lost when other events write to theCollection
The text was updated successfully, but these errors were encountered: