google-nomulus/javatests/google/registry
jianglai 4a5b317016 Add web WHOIS redirect support
Opened two ports (30010 and 30011 by default) that handles HTTP(S) GET requests. the HTTP request is redirected to the corresponding HTTPS site, whereas the HTTPS request is redirected to a site that supports web WHOIS.

The GCLB currently exposes port 80, but not port 443 on its TCP proxy load balancer (see https://cloud.google.com/load-balancing/docs/choosing-load-balancer). As a result, the HTTP traffic has to be routed by the HTTP load balancer, which requires a separate HTTP health check (as opposed to the TCP health check that the TCP proxy LB uses). This CL also added support for HTTP health check.

There is not a strong case for adding an end-to-end test for WebWhoisProtocolsModule (like those for EppProtocolModule, etc) as it just assembles standard HTTP codecs used for an HTTP server, plus the WebWhoisRedirectHandler, which is tested. The end-to-end test would just be testing if the Netty provided HTTP handlers correctly parse raw HTTP messages.

Sever other small improvement is also included:

[1] Use setInt other than set when setting content length in HTTP headers. I don't think it is necessary, but it is nevertheless a better practice to use a more specialized setter.
[2] Do not write metrics when running locally.
[3] Rename the qualifier @EppCertificates to @ServerSertificate as it now provides the certificate used in HTTPS traffic as well.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=206944843
2018-08-10 13:46:48 -04:00
..
backup Clean up third_party imports in BUILD files 2018-07-14 01:11:51 -04:00
batch Wrap ModulesService in new AppEngineServiceUtils 2018-08-10 13:44:25 -04:00
beam Fix open source build 2018-08-10 13:44:25 -04:00
bigquery Clean up annotation imports in BUILD files 2018-06-27 15:28:53 -04:00
builddefs Format .bzl files with buildifier 2018-07-14 01:37:03 -04:00
config Remove unnecessary "throws" declarations 2018-06-18 18:17:56 -04:00
cron Clean up third_party imports in BUILD files 2018-07-14 01:11:51 -04:00
dns Clean up third_party imports in BUILD files 2018-07-14 01:11:51 -04:00
export Wrap ModulesService in new AppEngineServiceUtils 2018-08-10 13:44:25 -04:00
flows Wrap ModulesService in new AppEngineServiceUtils 2018-08-10 13:44:25 -04:00
groups Clean up internal imports in BUILD files 2018-07-14 01:37:03 -04:00
keyring Delete all Braintree code 2018-07-14 01:37:03 -04:00
mapreduce/inputs Clean up internal imports in BUILD files 2018-07-14 01:37:03 -04:00
model Add an auto update time field to the Cursor entity 2018-08-10 13:44:25 -04:00
module Add ResaveEntityAction to BackendRequestComponent 2018-07-14 01:37:03 -04:00
monitoring/whitebox Wrap ModulesService in new AppEngineServiceUtils 2018-08-10 13:44:25 -04:00
pricing Clean up third_party imports in BUILD files 2018-07-14 01:11:51 -04:00
proxy Add web WHOIS redirect support 2018-08-10 13:46:48 -04:00
rdap Clean up third_party imports in BUILD files 2018-07-14 01:11:51 -04:00
rde Move the RDE PGP file encoding to a dedicated file 2018-08-10 13:44:25 -04:00
reporting Clean up internal imports in BUILD files 2018-07-14 01:37:03 -04:00
request Remove transition code for set of parameter refactoring 2018-07-14 01:37:03 -04:00
security Improve internal build system speed 2018-06-27 15:28:52 -04:00
server Delete all Braintree code 2018-07-14 01:37:03 -04:00
storage/drive Merge JUnitBackport's expectThrows into assertThrows 2018-03-06 18:56:15 -05:00
testing Migrate callers of Truth's Subject.failWithRawMessage to Subject.failWithoutActual 2018-08-10 13:44:25 -04:00
tldconfig/idn Merge JUnitBackport's expectThrows into assertThrows 2018-03-06 18:56:15 -05:00
tmch Clean up third_party imports in BUILD files 2018-07-14 01:11:51 -04:00
tools Add an auto update time field to the Cursor entity 2018-08-10 13:44:25 -04:00
ui Wrap ModulesService in new AppEngineServiceUtils 2018-08-10 13:44:25 -04:00
util Wrap ModulesService in new AppEngineServiceUtils 2018-08-10 13:44:25 -04:00
whois Clean up annotation imports in BUILD files 2018-06-27 15:28:53 -04:00
xjc Clean up internal imports in BUILD files 2018-07-14 01:37:03 -04:00
xml Remove unnecessary "throws" declarations 2018-06-18 18:17:56 -04:00