Commit Graph

43 Commits

Author SHA1 Message Date
Devin Doucette
4537929a0d Added missing includes of DerivedDataPayload.h found by the non-unity build
#rb none
#rnx

[CL 17426590 by Devin Doucette in ue5-main branch]
2021-09-03 17:11:27 -04:00
Andriy Tylychko
2a295eb685 deprecated FTicker and family and replaced by thread-safe FTSTicker
#jira UE-120090
#rb francis.hurteau

[CL 17176325 by Andriy Tylychko in ue5-main branch]
2021-08-16 11:05:18 -04:00
Devin Doucette
48d8d5f7eb DDC: Removed ICacheFactory in favor of exported functions
FCacheBucket is now always exposed as FAnsiStringView.

#rb Zousar.Shaker
#rnx

[CL 17084521 by Devin Doucette in ue5-main branch]
2021-08-06 12:51:28 -04:00
Devin Doucette
3513768988 DDC: Replaced FRequest with FRequestGroup to handle nested and chained requests more robustly
Any function that may create a request now has a IRequestOwner& parameter, and uses the Begin and End functions on the owner to manage the lifetime of any requests that it creates, as well as using End to invoke the completion callback for any request which has one.

The new FRequestBarrier may be used to block a group from being considered complete in a scope where more requests may be added to it.

#rb Matt.Peters
#rnx
#preflight 6109b5c403d303000144cce5
#preflight 610acf7103d30300016fda94

[CL 17060470 by Devin Doucette in ue5-main branch]
2021-08-04 17:52:40 -04:00
dmytro vovk
e0e8407cc0 Fixed static events initialization crash
#jira none
#rb Andriy.Tylychko

[CL 16995074 by dmytro vovk in ue5-main branch]
2021-07-29 09:55:50 -04:00
Francis Hurteau
79415aabf8 Refix crash in http request batch when the batch contains both a head and get request for the same cache keys
Added a test that could reliably reproduce the problem to validate it is properly fixed

#rb Danny.Couture, Zousar.Shaker
#preflight 610010b247c93a0001335319


#ROBOMERGE-OWNER: Francis.Hurteau
#ROBOMERGE-AUTHOR: francis.hurteau
#ROBOMERGE-SOURCE: CL 16968978
#ROBOMERGE-BOT: (v838-16927207)
#ROBOMERGE-CONFLICT from-shelf

[CL 16972104 by Francis Hurteau in ue5-main branch]
2021-07-27 15:24:32 -04:00
danny couture
f283881ae0 Fix thread starvation for request in http backend by using a FIFO for thread waiting for a connection to be freed
Replace the sleep by a wait on an event triggered by the thread freeing the connection
Improve the test to output stats seen below and use the proper amount of threads on low core systems

Automation RunTests System.DerivedDataCache.HttpDerivedDataBackend.ConcurrentCachedDataProbablyExistsBatch

Before
   RPS: 238, AvgLatency: 90.09 ms, MaxLatency: 7.77 s
   RPS: 231, AvgLatency: 87.66 ms, MaxLatency: 7.77 s
   RPS: 245, AvgLatency: 139.07 ms, MaxLatency: 10.08 s

After
   RPS: 634, AvgLatency: 102.97 ms, MaxLatency: 0.26 s
   RPS: 653, AvgLatency: 102.51 ms, MaxLatency: 0.26 s
   RPS: 630, AvgLatency: 102.29 ms, MaxLatency: 0.26 s

#rnx
#rb Zousar.Shaker, Francis.Hurteau
#preflight 60ffe8317f21c90001f6116a

[CL 16968010 by danny couture in ue5-main branch]
2021-07-27 09:25:29 -04:00
francis hurteau
ed059fdb34 Undo changelist 16938823 until investigation of cook failures are done
[FYI] Zousar.Shaker
#rb trivial
#preflight skip
discussed with Zoursar.Shaker, undo to fix cook failure


#ROBOMERGE-SOURCE: CL 16941401
#ROBOMERGE-BOT: (v838-16927207)

[CL 16941404 by francis hurteau in ue5-main branch]
2021-07-23 16:16:08 -04:00
francis hurteau
c7436d7678 Fix crash in http request batch when the batch contains both a head and get request for the same cache keys
Added a test that could reliably reproduce the problem to validate it is properly fixed
#preflight 60faeafc1f926d000113425b


#ROBOMERGE-SOURCE: CL 16938823
#ROBOMERGE-BOT: (v838-16927207)

[CL 16938832 by francis hurteau in ue5-main branch]
2021-07-23 13:14:33 -04:00
sebastien lussier
e16a51bf54 DDC backends - removed speed class tests in implementations of TryToPrefetch()
#rb danny.couture, devin.doucette


#ROBOMERGE-SOURCE: CL 16900182
#ROBOMERGE-BOT: (v836-16769935)

[CL 16917763 by sebastien lussier in ue5-main branch]
2021-07-21 19:08:29 -04:00
Zousar Shaker
bd3886b31f Fix bug where queued batch request failure in HttpDerivedDataBackend would cause incorrect DDC output (erroneous cache misses).
Adding basic unit test for HttpDerivedDataBackend.

#rb devin.doucette

[CL 16885295 by Zousar Shaker in ue5-main branch]
2021-07-19 13:09:40 -04:00
zousar shaker
51fda0ed0b Avoid indexing into a requests output datas array before we have established if we have output, as this can contribute to an out-of-bounds array lookup.
#rb devin.doucette
[FYI] francis.hurteau


#ROBOMERGE-SOURCE: CL 16867872
#ROBOMERGE-BOT: (v836-16769935)

[CL 16867881 by zousar shaker in ue5-main branch]
2021-07-15 17:30:45 -04:00
Devin Doucette
8e3e3cc389 DDC: Fixed TryToPrefetch to work when there is only one backend
#rb Zousar.Shaker
#rnx

[CL 16549112 by Devin Doucette in ue5-main branch]
2021-06-03 12:57:44 -04:00
Zousar Shaker
e56633ec8e Avoid crashing in DDC if the Jupiter server sends a malformed response with a payload size that sends us off the end of the response buffer. Emit an error message instead.
#rb devin.doucette
#preflight 60ad3fdd04188d0001f4987b

[CL 16454717 by Zousar Shaker in ue5-main branch]
2021-05-25 15:28:50 -04:00
Devin Doucette
3f40f504cf DDC: Changed Put to take a const array of cache records now that records are copyable
#rb Zousar.Shaker
#rnx

[CL 16184736 by Devin Doucette in ue5-main branch]
2021-05-03 12:05:18 -04:00
Andriy Tylychko
9f1cf3eabf re-deprecated FPlatformProcess::CreateSynchEvent(), now on all platforms. Replaced FEvent* by FEventRef where it made sense. Deprecated FEvent::Create() as another method to bypass the event pool
#rb steve.robb

[CL 16163267 by Andriy Tylychko in ue5-main branch]
2021-04-29 18:52:48 -04:00
Devin Doucette
e42bbbedab DDC: Implement ICacheStore on FDerivedDataBackendInterface
This allows the new cache to be implemented more efficiently using the old cache backends because functionality like the corruption wrapper and key length limiter can be bypassed and the individual backends can store cache records in whatever way is most efficient for them.

The hierarchical backend may request payloads when they are not required due to incomplete tracking of backend state, and GetPayload will never fill other backends due to the inefficiency of the existing backend framework.

The filesystem backend does not cache any state in memory, which makes requests for individual payloads less efficient than if it cached a mapping of cache payload key to raw hash after the first request for a cache key.

The HTTP, S3, and pak file backends are not implemented for the new interface.

The backends do not implement ICacheStore::CancelAll() because the existing backend framework provides WaitForQuiescence to wait for completion of async requests, and the implementation of ICacheStore by those backends works with that mechanism.

The non-leaf backends (hierarchical, async put, etc.) do not update stats from the ICacheStore functions.

#rb Zousar.Shaker
#rnx
#preflight 60899f35d324590001b47517

[CL 16148296 by Devin Doucette in ue5-main branch]
2021-04-28 16:22:18 -04:00
Zousar Shaker
94bcce4d3e Put a minimum "transfer speed over duration" limit on curl operations done by the HTTP DDC backend.
#rb devin.doucette
#preflight 60808a0ca698b3000172743c

[CL 16081589 by Zousar Shaker in ue5-main branch]
2021-04-21 17:14:57 -04:00
Zousar Shaker
8b5a796e2a Add support for ReadOnly={true|false} and EnvHostOverride={string} as configurable parameters on an HTTP DDC backend.
#rb devin.doucette

[CL 16076564 by Zousar Shaker in ue5-main branch]
2021-04-21 13:19:11 -04:00
Zousar Shaker
3b9ff68e09 Fix bug in the HttpDerivedDataBackend where an FRequest may not be returned to the FRequestPool if we're aborting queued PUTs due to a shutdown request.
#jira UE-113612
#rb devin.doucette
#preflight 607e38a842dbff0001a4dc20

[CL 16058184 by Zousar Shaker in ue5-main branch]
2021-04-19 22:53:53 -04:00
Johan Berg
ce27da1f98 Remove UE4 strings
#jira UE-111642
#rb none

[CL 16002173 by Johan Berg in ue5-main branch]
2021-04-14 04:25:18 -04:00
Zousar Shaker
d014867e9f Ensure that the non-DataRequest-Helper codepath for putting DDC data into the cache also tears-down promptly during process shutdown if not running on a build machine.
#jira UE-112179
#rb devin.doucette

[CL 15930076 by Zousar Shaker in ue5-main branch]
2021-04-06 10:20:06 -04:00
Zousar Shaker
dc68fab37b Ensure HTTP DDC backend doesn't delay process shutdown due to a queue of pending PUTs for normal users.
Still allows build machine runs to be thorough about completing PUTs.
Doesn't interrupt any in-flight PUTs, just prevents processing of any remaining queued PUTs.

#jira UE-112179
#rb devin.doucette

[CL 15920539 by Zousar Shaker in ue5-main branch]
2021-04-05 14:36:58 -04:00
Devin Doucette
d87eb29d07 DDC: Switched to WriteToString in the Jupiter backend
#rb Zousar.Shaker
#rnx

[CL 15829627 by Devin Doucette in ue5-main branch]
2021-03-25 15:34:31 -04:00
Zousar Shaker
0ee734bf61 Fix HTTP/Jupiter DDC backend to account for the fact that Jupiter will return batched results in arbitrary order, not the same order that the requests/keys were listed.
#rb devin.doucette

[CL 15771001 by Zousar Shaker in ue5-main branch]
2021-03-22 18:23:46 -04:00