Skip to content

Commit

Permalink
Log "Latest" instead of revision for fallback snapshots
Browse files Browse the repository at this point in the history
Summary:
This makes it easier to group by `snapshot`, the revision is also
available in the `revision used` column.

Reviewed By: pepeiborra

Differential Revision: D56185668

fbshipit-source-id: 09961253f99dbb901a87dc3e0cd6df2e3c798097
  • Loading branch information
Simon Marlow authored and facebook-github-bot committed Apr 17, 2024
1 parent a5ff658 commit 3c22d42
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion glean/glass/Glean/Glass/Handler.hs
Original file line number Diff line number Diff line change
Expand Up @@ -963,7 +963,7 @@ fetchSymbolsAndAttributes tracer scm repoMapping dbInfo req opts be
Right result ->
return
(( result
, Snapshot.Latest (documentSymbolListXResult_revision result)
, Snapshot.Latest
, QueryEachRepoUnrequested)
, Nothing)
Left _ ->
Expand Down
3 changes: 1 addition & 2 deletions glean/glass/Glean/Glass/Logging.hs
Original file line number Diff line number Diff line change
Expand Up @@ -434,5 +434,4 @@ logSnapshotStatus st = case st of
NotFound -> Logger.setSnapshot "Not found"
ExactMatch -> Logger.setSnapshot "Exact"
Ignored -> Logger.setSnapshot "Ignored"
Latest rev ->
Logger.setSnapshot (unRevision rev)
Latest -> Logger.setSnapshot "Latest"
2 changes: 1 addition & 1 deletion glean/glass/Glean/Glass/SnapshotBackend.hs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ data SnapshotStatus
| NotFound
| ExactMatch
| Ignored
| Latest Revision
| Latest
deriving Show

-- | Always produces the 'NilSnapshotBackend'
Expand Down

0 comments on commit 3c22d42

Please sign in to comment.