add logging indicating full backups (#3721)
#### Does this PR need a docs update or release note? - [x] ⛔ No #### Type of change - [x] 🤖 Supportability/Tests #### Issue(s) * #3720
This commit is contained in:
parent
b74f65e301
commit
5949a3bcd7
@ -208,6 +208,8 @@ func ProduceBackupCollections(
|
|||||||
return nil, nil, false, err
|
return nil, nil, false, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ctx = clues.Add(ctx, "can_use_previous_backup", canUsePreviousBackup)
|
||||||
|
|
||||||
for _, scope := range eb.Scopes() {
|
for _, scope := range eb.Scopes() {
|
||||||
if el.Failure() != nil {
|
if el.Failure() != nil {
|
||||||
break
|
break
|
||||||
|
|||||||
@ -234,6 +234,8 @@ func (c *Collections) Get(
|
|||||||
return nil, false, err
|
return nil, false, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ctx = clues.Add(ctx, "can_use_previous_backup", canUsePreviousBackup)
|
||||||
|
|
||||||
driveTombstones := map[string]struct{}{}
|
driveTombstones := map[string]struct{}{}
|
||||||
|
|
||||||
for driveID := range oldPathsByDriveID {
|
for driveID := range oldPathsByDriveID {
|
||||||
|
|||||||
@ -297,7 +297,7 @@ func (op *BackupOperation) do(
|
|||||||
return nil, clues.Stack(err)
|
return nil, clues.Stack(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
mans, mdColls, canUseMetaData, err := produceManifestsAndMetadata(
|
mans, mdColls, canUseMetadata, err := produceManifestsAndMetadata(
|
||||||
ctx,
|
ctx,
|
||||||
kbf,
|
kbf,
|
||||||
op.kopia,
|
op.kopia,
|
||||||
@ -308,7 +308,9 @@ func (op *BackupOperation) do(
|
|||||||
return nil, clues.Wrap(err, "producing manifests and metadata")
|
return nil, clues.Wrap(err, "producing manifests and metadata")
|
||||||
}
|
}
|
||||||
|
|
||||||
if canUseMetaData {
|
ctx = clues.Add(ctx, "can_use_metadata", canUseMetadata)
|
||||||
|
|
||||||
|
if canUseMetadata {
|
||||||
lastBackupVersion = mans.MinBackupVersion()
|
lastBackupVersion = mans.MinBackupVersion()
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -325,7 +327,10 @@ func (op *BackupOperation) do(
|
|||||||
return nil, clues.Wrap(err, "producing backup data collections")
|
return nil, clues.Wrap(err, "producing backup data collections")
|
||||||
}
|
}
|
||||||
|
|
||||||
ctx = clues.Add(ctx, "coll_count", len(cs))
|
ctx = clues.Add(
|
||||||
|
ctx,
|
||||||
|
"can_use_previous_backup", canUsePreviousBackup,
|
||||||
|
"collection_count", len(cs))
|
||||||
|
|
||||||
writeStats, deets, toMerge, err := consumeBackupCollections(
|
writeStats, deets, toMerge, err := consumeBackupCollections(
|
||||||
ctx,
|
ctx,
|
||||||
@ -336,7 +341,7 @@ func (op *BackupOperation) do(
|
|||||||
cs,
|
cs,
|
||||||
ssmb,
|
ssmb,
|
||||||
backupID,
|
backupID,
|
||||||
op.incremental && canUseMetaData && canUsePreviousBackup,
|
op.incremental && canUseMetadata && canUsePreviousBackup,
|
||||||
op.Errors)
|
op.Errors)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, clues.Wrap(err, "persisting collection backups")
|
return nil, clues.Wrap(err, "persisting collection backups")
|
||||||
@ -476,6 +481,8 @@ func consumeBackupCollections(
|
|||||||
isIncremental bool,
|
isIncremental bool,
|
||||||
errs *fault.Bus,
|
errs *fault.Bus,
|
||||||
) (*kopia.BackupStats, *details.Builder, kopia.DetailsMergeInfoer, error) {
|
) (*kopia.BackupStats, *details.Builder, kopia.DetailsMergeInfoer, error) {
|
||||||
|
ctx = clues.Add(ctx, "collection_source", "operations")
|
||||||
|
|
||||||
complete := observe.MessageWithCompletion(ctx, "Backing up data")
|
complete := observe.MessageWithCompletion(ctx, "Backing up data")
|
||||||
defer func() {
|
defer func() {
|
||||||
complete <- struct{}{}
|
complete <- struct{}{}
|
||||||
|
|||||||
@ -229,6 +229,8 @@ func write(
|
|||||||
dbcs []data.BackupCollection,
|
dbcs []data.BackupCollection,
|
||||||
errs *fault.Bus,
|
errs *fault.Bus,
|
||||||
) (string, error) {
|
) (string, error) {
|
||||||
|
ctx = clues.Add(ctx, "collection_source", "streamstore")
|
||||||
|
|
||||||
backupStats, _, _, err := bup.ConsumeBackupCollections(
|
backupStats, _, _, err := bup.ConsumeBackupCollections(
|
||||||
ctx,
|
ctx,
|
||||||
nil,
|
nil,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user