bugsnag / webpack-bugsnag-plugins

Webpack plugins for common BugSnag actions.
MIT License
32 stars 29 forks source link

Introduce retry logic to upload #17

Closed rlaakkol closed 5 years ago

rlaakkol commented 6 years ago

When we upload sourcemaps in our CI runs, we occasionally get the following error:

ERROR in BugsnagSourceMapPlugin (Bad Gateway (502) - 
<html><head>
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<title>502 Server Error</title>
</head>
<body text=#000000 bgcolor=#ffffff>
<h1>Error: Server Error</h1>
<h2>The server encountered a temporary error and could not complete your request.<p>Please try again in 30 seconds.</h2>
<h2></h2>
</body></html>
)

It happens quite rarely, but it is pretty annoying to get failed CI runs because of it, so could you consider adding some kind of retry logic (with some sane backoff) to the upload phase?

rlaakkol commented 6 years ago

Alternatively some kind of option to ignore upload failures could be a passable solution.

bengourley commented 6 years ago

Thanks for the suggestion, this sounds like a very reasonable thing to do. I've added it to our internal backlog. Cheers @rlaakkol!