diff options
author | Thomas Wolf <twolf@apache.org> | 2022-07-19 12:12:26 +0200 |
---|---|---|
committer | Thomas Wolf <twolf@apache.org> | 2022-07-31 14:08:46 +0200 |
commit | 559be665296e7587e3ff0425152b631c93b4b56d (patch) | |
tree | 5b27cb63f3d2f84d9033c4a787b506279c648cf7 /org.eclipse.jgit.test/tst/org/eclipse | |
parent | 911b4e0d8257f1e9f02e35fcf8dba3d24e8fe56f (diff) | |
download | jgit-559be665296e7587e3ff0425152b631c93b4b56d.tar.gz jgit-559be665296e7587e3ff0425152b631c93b4b56d.zip |
[tests] Stabilize the HTTP server's request log
The TestRequestLog added log entries only after a request had been
handled. But the response is already sent at that point, so the
following sequence was possible:
client sends request A
server thread T1 handles request A and sends back response
client receives response
client sends request B
server thread T2 handles request B (and sends back response)
server thread T2 logs B
server thread T1 logs A
Fix this by logging events before handling a request, and then filling
in the response data after the request has been handled. This should
avoid such inversions, at least for tests using a single single-threaded
client. With multiple concurrent or multi-threaded clients, all bets
about the log order would be off anyway.
Bug: 528187
Change-Id: I99a46df17231fa7c4f75a8c37e2c14dc098c4e22
Signed-off-by: Thomas Wolf <twolf@apache.org>
Diffstat (limited to 'org.eclipse.jgit.test/tst/org/eclipse')
0 files changed, 0 insertions, 0 deletions