Commit Graph

103 Commits

Author SHA1 Message Date
martin ridgers
bb5ac95928 Restrict trace store client to only resolve IPv4 addresses. Previously the resolve would look up IPv6 addresses for the given host leading to stalls.
#rb jb
#rnx

#ROBOMERGE-AUTHOR: martin.ridgers
#ROBOMERGE-SOURCE: CL 17443422 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v870-17433530)

[CL 17443426 by martin ridgers in ue5-release-engine-test branch]
2021-09-07 08:32:26 -04:00
martin ridgers
9bc39ddbb2 Shifted the store frontend to another port so as to avoid collision with old-school Unreal Insightses.
#rnx

#ROBOMERGE-SOURCE: CL 16603796 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v828-16531559)

[CL 16603804 by martin ridgers in ue5-release-engine-test branch]
2021-06-09 08:51:32 -04:00
martin ridgers
d84ae8e3f2 Tweaked the trace store client/server protocol to be more HTTP-like.
#rb honk
#rnx

#ROBOMERGE-SOURCE: CL 16602541 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v828-16531559)

[CL 16602712 by martin ridgers in ue5-release-engine-test branch]
2021-06-09 07:05:27 -04:00
Martin Ridgers
e75bd655f6 Add accessor for the "store_dir" field of the trace store's /v1/status response.
[CL 16544497 by Martin Ridgers in ue5-main branch]
2021-06-03 03:34:33 -04:00
Martin Ridgers
49726ba2ae Include the trace store's local filesystem location in the /v1/status response.
[CL 16544451 by Martin Ridgers in ue5-main branch]
2021-06-03 03:22:21 -04:00
Martin Ridgers
18f8df19ed Bumped a port number one step too early.
[CL 16509004 by Martin Ridgers in ue5-main branch]
2021-05-31 09:51:47 -04:00
Martin Ridgers
5be4185e2a Versioned the end points that the trace store server and client communicate over. This will be useful as I shift to running the trace store in a separate process who's lifetime I've less control over.
[CL 16508945 by Martin Ridgers in ue5-main branch]
2021-05-31 09:38:07 -04:00
Steve Robb
1f3fe8c9ac Some ANSICHAR/UTF8CHAR cast fixes for upcoming changes to StringConv.h.
#rb none
#jira none

[CL 16469364 by Steve Robb in ue5-main branch]
2021-05-26 10:45:12 -04:00
Martin Ridgers
5cfc74ed00 Specifying the port that the Trace Store client should connect is now optional.
#rb jb
#rnx

[CL 16467361 by Martin Ridgers in ue5-main branch]
2021-05-26 08:25:39 -04:00
Martin Ridgers
4bf9cfa79a Call select() on a socket before making a blocking call to recv(). Calls to recv() that are waiting for data may not return even if the socket is closed. This can result in a technical hang where Insights waits on Trace waiting on a socket that was closed. This way we only call recv() when we know there is data to read, and the select()+timeout combo correctly detects to the close().
#rb Catalin.Dragoiu
#rnx

[CL 16364807 by Martin Ridgers in ue5-main branch]
2021-05-18 04:24:57 -04:00
Martin Ridgers
be972be826 Moved the Trace namespace into the UE namespace.
#rb jb
#rnx

[CL 14762673 by Martin Ridgers in ue5-main branch]
2020-11-17 06:54:28 -04:00
Martin Ridgers
1d420c9d7b Expose active trace sessions' control port via the Trace Store.
#rb jb
#rnx

[CL 14750314 by Martin Ridgers in ue5-main branch]
2020-11-16 04:31:03 -04:00
Martin Ridgers
71cc29d19a Fixed MSVC static analysis warnings from a Windows SDK header.
#rb trivial
#rnx

[CL 14744174 by Martin Ridgers in ue5-main branch]
2020-11-13 10:09:34 -04:00
Martin Ridgers
8a6a773e17 Trace data is a stream and communication is one way. It is implemented this way to share code between sending trace data over the wire and writing it to a file. Because there's no ping/pong we can end up with a half-open TCP connection if the other end doesn't close its socket. So we'll enable keep-alive on the socket and set a short timeout (default is 2hrs).
[CL 14733648 by Martin Ridgers in ue5-main branch]
2020-11-12 10:07:23 -04:00
Marc Audy
11f5b21210 Merging //UE5/Release-Engine-Staging @ 13752110 to Main (//UE5/Main)
#rnx

[CL 13753156 by Marc Audy in ue5-main branch]
2020-06-23 18:40:00 -04:00
martin ridgers
3b724a0c2f Made the sockets that the trace store client creates uninheritable
#rb none
#jira ue-91015

#ushell-cherrypick of 12106008 by Martin.Ridgers

#ROBOMERGE-SOURCE: CL 12386981 in //UE4/Release-4.25/... via CL 12386982
#ROBOMERGE-BOT: RELEASE (Release-4.25Plus -> Main) (v671-12333473)

[CL 12386984 by martin ridgers in Main branch]
2020-03-24 06:20:59 -04:00
Martin Ridgers
bcda0febbe Cancel the timeout tick when accepting a connection to read trace data from a relay. Otherwise the timeout fires causing an extra read, the loss of a page of trace data, and eventually a segfault or assert.
#rb jb
#rnx
#jira ue-88376
#ushell-cherrypick of 11302806 by Martin.Ridgers

[CL 11303311 by Martin Ridgers in Main branch]
2020-02-10 08:55:35 -05:00
Martin Ridgers
cfd65a404f Always attempt to cancel a timer regardless of the owning FAsioTickable's state. Without this it isn't possible to cancel one-shot ticks.
#rb jb
#rnx
#jira ue-88376

#ushell-cherrypick of 11302796 by Martin.Ridgers

[CL 11303303 by Martin Ridgers in Main branch]
2020-02-10 08:53:23 -05:00
Stefan Boberg
55a8b15f1f Copying //UE4/Dev-Core to Main (//UE4/Main)
#rb none

[CL 11258477 by Stefan Boberg in Main branch]
2020-02-05 14:26:36 -05:00
Martin Ridgers
75ebb9e56a Prevent listening sockets from being inherited by child processes. See 11152126 for details.
#rb none
#rnx

[CL 11153119 by Martin Ridgers in Dev-Core branch]
2020-01-29 04:13:59 -05:00
Martin Ridgers
d5184a8ac4 Did pass over socket closing.
#rb trivial
#rnx

[CL 11152757 by Martin Ridgers in Dev-Core branch]
2020-01-29 03:46:28 -05:00
Martin Ridgers
e0d3dcdbd2 Set linger to 0 for all store service module's listening and accepted sockets so Close() sends a RST instead of a FIN/ACK. This will prevent a flood of TIME_WAIT sockets that correctly following the passive/active close handshake.
#rb none
#rnx

[CL 11128700 by Martin Ridgers in Dev-Core branch]
2020-01-28 09:15:36 -05:00
Martin Ridgers
a9ffaf63c3 Close the numerous store service modules on the correct thread.
#rb trivial
#rnx

[CL 11128319 by Martin Ridgers in Dev-Core branch]
2020-01-28 07:41:32 -05:00
Martin Ridgers
29c4f53269 Cleaner store service shutdown which closes everything and waits for the async IO loops to drain.
#rb none
#rnx

[CL 11126050 by Martin Ridgers in Dev-Core branch]
2020-01-28 04:11:19 -05:00
Martin Ridgers
7520f4654b Fixed double delete segfaults
#rb cm
#none

[CL 11125939 by Martin Ridgers in Dev-Core branch]
2020-01-28 02:14:52 -05:00