-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PurlFetcher::Client::ReleaseTags.release call gets 502 Bad Gateway response #1327
Comments
if we realize this is a purl-fetcher bug, we should probably transfer this GH issue to the purl-fetcher repository. but leaving here for now since it's where we discovered the problem. |
Is this close-able? I just noticed it on the prod priorities board and July 12 feels like a long time ago given all the versioning work. I suspect we addressed this. |
i don't know, but it does feel plausible that versioning work since july has fixed this. no objection to closing. hopefully if this error pops up again, honeybadger will collate the new alert to the original one linked from this issue, since this issue is linked from that HB alert. |
failure info
Error:
RuntimeError: unexpected response: 502 {"status"=>"error", "message"=>"Bad Gateway"}
Backtrace:
common-accessioning/lib/robots/dor_repo/release/release_publish.rb
Lines 17 to 25 in 39ca7d5
https://github.com/sul-dlss/purl_fetcher-client/blob/c4b8058ef114b34a3869fac4ead2180fcfffc5d0/lib/purl_fetcher/client/release_tags.rb#L23-L27
View full backtrace and more info at honeybadger.io
troubleshooting so far
I was able to recreate the error manually in common-accessioning robot console on prod, by making the underlying calls in the robot step's
perform_work
method, but without the surrounding workflow stuff in the base lyber_coreperform
method. Example in Slack: https://stanfordlib.slack.com/archives/C09M7P91R/p1720822349423099?thread_ts=1720748791.183479&cid=C09M7P91RHowever, I wasn't able to reproduce this using what I think would be a similar raw curl request from the command-line on the same VM; in that case, I got a 4xx error instead. Which struck me as odd since a 502 would indicate an error from something like a web server that sits in front of purl-fetcher from the perspective of network calls coming to it, right? but a 4xx indicates the request making it through. And I couldn't see why A Faraday request from Ruby land would behave so differently from a CLI
curl
. Examplecurl
:other context
Slack thread where @andrewjbtw happened upon this: https://stanfordlib.slack.com/archives/C09M7P91R/p1720817745891829?thread_ts=1720748791.183479&cid=C09M7P91R
Facet for what's still in error: https://argo.stanford.edu/catalog?f%5Bwf_wps_ssim%5D%5B%5D=releaseWF%3Arelease-publish%3Aerror
druids that've run into the error as of 2024-07-12:
Andrew suspects ongoing user versions work and something something
meta.json
as a possible culprit. See this HB alert: https://app.honeybadger.io/projects/48916/faults/108553257 (Errno::ENOENT: No such file or directory @ rb_sysopen - /purl/document_cache/mw/847/pg/5827/meta.json
)I guess maybe my malformed
curl
request isn't making it to the point of even trying to read themeta.json
, but then once an attempt is made to read that file with a valid request to purl-fetcher, purl-fetcher then tries to get it but runs into a 502 from another service? In a quick grep to see what HTTP statuses purl-fetcher returns, I found this error code related behavior:status
also showed up as taking theResourcesController#build_error
method'serror_code
param, so see what error codes are passed tobuild_error
...The text was updated successfully, but these errors were encountered: