Skip to content

Commit

Permalink
chore: improve error logging (#4288)
Browse files Browse the repository at this point in the history
  • Loading branch information
achettyiitr authored Jan 8, 2024
1 parent 3ecc0a6 commit 9cb9caf
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions services/rsources/handler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -918,7 +918,7 @@ var _ = Describe("Using sources handler", func() {
return false
}
return true
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", mustMarshal(failedKeysA), mustMarshal(failedKeysB), mustMarshal(expected), err)
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", string(mustMarshal(failedKeysA)), string(mustMarshal(failedKeysB)), string(mustMarshal(expected)), err)
})

It("should be able to create the same services again and not affect publications and subscriptions", func() {
Expand Down Expand Up @@ -1203,7 +1203,7 @@ var _ = Describe("Using sources handler", func() {
return false
}
return true
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", mustMarshal(failedKeysA), mustMarshal(failedKeysB), mustMarshal(expected), err)
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", string(mustMarshal(failedKeysA)), string(mustMarshal(failedKeysB)), string(mustMarshal(expected)), err)

jobRunId := newJobRunId()
addFailedRecords(pgA.db, jobRunId, defaultJobTargetKey, serviceA, []FailedRecord{
Expand Down Expand Up @@ -1270,7 +1270,7 @@ var _ = Describe("Using sources handler", func() {
return false
}
return true
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", mustMarshal(failedKeysA), mustMarshal(failedKeysB), mustMarshal(expected), err)
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", string(mustMarshal(failedKeysA)), string(mustMarshal(failedKeysB)), string(mustMarshal(expected)), err)
})

It("should be able to add a code column to rsources_failed_keys_v2_records table seamlessly, without affecting logical replication", func() {
Expand Down Expand Up @@ -1417,7 +1417,7 @@ var _ = Describe("Using sources handler", func() {
return false
}
return true
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", mustMarshal(failedKeysA), mustMarshal(failedKeysB), mustMarshal(expected), err)
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", string(mustMarshal(failedKeysA)), string(mustMarshal(failedKeysB)), string(mustMarshal(expected)), err)

jobRunId := newJobRunId()
addFailedRecords(pgA.db, jobRunId, defaultJobTargetKey, serviceA, []FailedRecord{
Expand Down Expand Up @@ -1484,7 +1484,7 @@ var _ = Describe("Using sources handler", func() {
return false
}
return true
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", mustMarshal(failedKeysA), mustMarshal(failedKeysB), mustMarshal(expected), err)
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", string(mustMarshal(failedKeysA)), string(mustMarshal(failedKeysB)), string(mustMarshal(expected)), err)
})
})
})
Expand Down
2 changes: 1 addition & 1 deletion services/rsources/handler_v1_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,7 @@ var _ = Describe("Using sources handler v1", func() {
return false
}
return true
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", mustMarshal(failedKeysA), mustMarshal(failedKeysB), mustMarshal(expected), err)
}, "30s", "100ms").Should(BeTrue(), "Failed Records from both services should be the same", string(mustMarshal(failedKeysA)), string(mustMarshal(failedKeysB)), string(mustMarshal(expected)), err)
})
})
})

0 comments on commit 9cb9caf

Please sign in to comment.