Skip to content

Commit

Permalink
wait for non tmp log
Browse files Browse the repository at this point in the history
  • Loading branch information
sonroyaalmerol committed Nov 18, 2024
1 parent 428ad1e commit 5fbf3ad
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/store/tasks.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,8 @@ func (storeInstance *Store) GetMostRecentTask(ctx context.Context, job *Job) (ch
}
} else {
searchString := fmt.Sprintf(":backup:%s%shost-%s", job.Store, encodeToHexEscapes(":"), encodeToHexEscapes(backupId))
log.Printf("Checking %s == %s\n", event.Name, searchString)
if strings.Contains(event.Name, searchString) {
log.Printf("Checking if %s contains %s\n", searchString, event.Name)
if !strings.Contains(event.Name, ".tmp_") && strings.Contains(event.Name, searchString) {
fileName := filepath.Base(event.Name)
colonSplit := strings.Split(fileName, ":")
actualUpid := colonSplit[:9]
Expand Down

0 comments on commit 5fbf3ad

Please sign in to comment.