Skip to content

Commit 1ee922b

Browse files
committed
Handle 400 Bad Request errors in workflows backup
1 parent 636bd54 commit 1ee922b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/datadog_backup/workflows.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,10 @@ def backup
2626
def get_by_id(id)
2727
except(get(id))
2828
rescue Faraday::ResourceNotFound
29-
LOGGER.warn("Workflow #{id} not found")
29+
LOGGER.warn("Workflow #{id} not found (404)")
30+
{}
31+
rescue Faraday::BadRequestError => e
32+
LOGGER.warn("Workflow #{id} returned bad request (400) - #{e.message}")
3033
{}
3134
end
3235

0 commit comments

Comments
 (0)