Started: Oct. 13, 2015, 10:08 p.m.
Last activity: Oct. 13, 2015, 10:08 p.m.
Topics: Web Service Developers
Oct. 13, 2015, 10:08 p.m.
At the DMC we use HTTP redirection, specifically an HTTP 307 response, to direct requests to alternate endpoints during maintenance.
Most HTTP tools and libraries follow redirects for GET requests automatically, meaning that the caller does not need to perform any additional action and the response is as if the eventual endpoint was called directly. It is less common that tools and libraries follow redirects for POST requests automatically.
An example of this inconsistency: the common 'wget' tool follows redirects by default, both GET and POST. But the common 'curl' tool does not follow redirects, either GET or POST unless the '-L' option is specified.
We strongly recommend that any HTTP clients used to access DMC web services be configured to follow redirects for both GET and POST requests.
To facilitate testing, we have set up some HTTP 307 redirects for the DMC's core FDSN services.
Each endpoint responds with an HTTP 307 (Temporary Redirect) to the DMC's implementation of the service. For example, a request to http://ds.iris.edu/files/redirect/307/station/1 will be redirected to http://service.iris.edu/fdsnws/station/1.
Questions and comments welcome.