feat(versions): pull version number from fxa-auth-db-mysql server #1080
Conversation
|
@jrgm to check this... |
| return new P(function (resolve, reject) { | ||
| if (!dbVersion) { | ||
| var config = require('../../config').root() | ||
| httprequest.get({url: config.httpdb.url, json: true, timeout: 10000}, function (err, response, body) { |
vladikoff
Nov 9, 2015
Contributor
@jrgm there is a 10 sec timeout here, so we can give it a try? (maybe with a shorter timeout) to see how well it works in stage and prod
@jrgm there is a 10 sec timeout here, so we can give it a try? (maybe with a shorter timeout) to see how well it works in stage and prod
|
Just a note regarding timeouts from the previous issue: "I've set timeout to 10000ms in request.get. However, the request docs indicate that in the event of a TCP connection failing, the underlying OS timeout will take precedence. There doesn't appear to be a way to override. Thus, the caveat that the only time the 10s will be useful is if the remote db server is slow to respond, but is listening." |
|
Thanks again for this PR! We are gonna close this for now and get back to it later, currently there are a few concerns about fetching the remove DB version from the auth server. We will try to revisit this in the future. |
Reopening this after #908 went stale a while back, please check that PR for context.
When run against my local fxa-auth-server in docker I get the following: