Description[Telemetry] Change the way host port for android_browser_backend is created
Based on
https://code.google.com/p/chromium/codesearch#chromium/src/build/android/pylib/ports.py&l=40
AllocateTestServerPort used a lock file for storing tried port &
create a range limit for ports. Telemetry doesn't need this scheme
for finding a local port for these reasons:
1) There is no reason the local port has to be in the range 10201 & 30000 (there is
a TODO to get rid of it here:
https://code.google.com/p/chromium/codesearch#chromium/src/build/android/pyli...)
2) When the tried_port saved in lock file reaches the limit
TEST_SERVER_PORT_LAST, it creates the assertion failure in crbug.com/495715
3) The lock file make it any less flaky. Implementation of
GetUnreservedAvailableLocalPort() is guaranteed to return an
unused port number at the time of request.
Telemetry has been using this way for allocating port
for desktop testing just fine.
BUG=495715
Committed: https://crrev.com/a0e2e45b82acfc5ea63ecc1cee12b0cc1e86e557
Cr-Commit-Position: refs/heads/master@{#341546}
Patch Set 1 #
Messages
Total messages: 9 (2 generated)
|