Commit Graph

117 Commits

Author SHA1 Message Date
steve robb
fd2a0b1e20 Removal of TEXT literal concatenations, which doesn't work in UTF-8 mode.
#rb devin.doucette
#jira UE-132142
#preflight 62a8748fa76c84377748036b

#ROBOMERGE-OWNER: steve.robb
#ROBOMERGE-AUTHOR: steve.robb
#ROBOMERGE-SOURCE: CL 20647443 via CL 20648283 via CL 20648315
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v955-20579017)

[CL 20651786 by steve robb in ue5-main branch]
2022-06-14 12:46:34 -04:00
devin doucette
f6f4dcd722 DDC: Added detail to the error when cache graph creation fails
#preflight skip
#rb Zousar.Shaker
#rnx

#ROBOMERGE-OWNER: devin.doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 20628288 via CL 20628340 via CL 20628354
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v955-20579017)

[CL 20636252 by devin doucette in ue5-main branch]
2022-06-13 18:36:59 -04:00
devin doucette
3e2538a313 DDC: Removed the legacy cache store implementations and limit cache bucket names to 63 characters
The cache bucket name was already limited to 63 characters in practice by Horde Storage. This makes it consistent across every cache store.

#preflight 629e6f0a1c7e8f9a180e192a
#rb Zousar.Shaker

#ROBOMERGE-OWNER: Devin.Doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-COMMAND: _robomerge[bot4] UE5-MAIN
#ROBOMERGE-SOURCE: CL 20536454 via CL 20536805 via CL 20536993
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v954-20466795)

[CL 20538633 by devin doucette in ue5-main branch]
2022-06-07 11:17:10 -04:00
Devin Doucette
1bbb384300 DDC: Removed the legacy cache implementation from the clients for Horde Storage and Zen
#preflight 62967fd60c151996e13038ec
#rb Zousar.Shaker

[CL 20445538 by Devin Doucette in ue5-main branch]
2022-05-31 22:01:53 -04:00
dan engelbrecht
e4e1ba5527 Allow configuration for separate namespace for structured data
#preflight 628e494382597362d1f8050d
#preflight 628e70d72c7cb2d10d71c033

[CL 20369511 by dan engelbrecht in ue5-main branch]
2022-05-25 14:55:57 -04:00
Zousar Shaker
f7a1ba41e6 Fixed bug in handling of -DDC-All-* commandline arguments.
#rb none
#rnx
#fyi devin.doucette
#preflight 626ec64edd1fe026f111ac4a

[CL 20002339 by Zousar Shaker in ue5-main branch]
2022-05-01 13:56:24 -04:00
Devin Doucette
f75b88cce1 DDC: Fixed simulated cache miss salt differing for every node when using -DDC-All-Miss options
#preflight 626c0ecfee358ddf385638bc
#rb Zousar.Shaker
#rnx

[CL 19982661 by Devin Doucette in ue5-main branch]
2022-04-29 14:18:40 -04:00
Devin Doucette
b74b8b9227 DDC: Fixed incorrect cache store flags on dynamically mounted pak files
#preflight 625d771248670f31a61f0def
#rb Zousar.Shaker
#rnx

[CL 19785545 by Devin Doucette in ue5-main branch]
2022-04-18 10:57:14 -04:00
Devin Doucette
455b4ece9e DDC: Extended -DDC-MissTypes to match -DDC-Verify
In the examples below, <Node> is the name of a node in the cache store graph, or All to apply to every node.
-DDC-<Node>-MissTypes=StaticMesh+Texture will simulate a miss on every access to to static mesh and texture keys.
-DDC-<Node>-MissTypes=StaticMesh@12.5+Texture will simulate misses on 12.5% of accesses to static mesh keys and every access to texture keys.
-DDC-<Node>-MissRate=5 -DDC-<Node>-MissTypes=Texture will simulate misses on every access to texture keys and 5% of other keys.
-DDC-<Node>-MissRate=5 will simulate misses on 5% of keys.
-DDC-<Node>-MissSalt=PositiveInt32 will set the salt used to match keys to simulate misses on. A key always has the same simulated miss behavior with the same salt.

#preflight 6244d102b33098a72dc136df
#rb Zousar.Shaker

[CL 19572200 by Devin Doucette in ue5-main branch]
2022-03-31 10:06:47 -04:00
Devin Doucette
cebf4161f9 DDC: Added -DDC-Verify arguments to control determinism verification
-DDC-Verify will verify determinism on every access to the cache.
-DDC-Verify=StaticMesh+Texture will verify determinism on every access static mesh and texture keys.
-DDC-Verify=StaticMesh@12.5+Texture will verify determinism on 12.5% of accesses to static mesh keys and every access to texture keys.
-DDC-VerifyRate=5 -DDC-Verify=Texture will verify detereminism on every access to texture keys and 5% of other keys.
-DDC-VerifyRate=5 -DDC-Verify will verify determinism on 5% of keys.
-DDC-VerifySalt=PositiveInt32 will set the salt used to match keys to verify. A key always has the same verification behavior with the same salt.

#preflight 6244ad99637925b5d3bc7fab
#rb Zousar.Shaker

[CL 19563192 by Devin Doucette in ue5-main branch]
2022-03-30 15:51:28 -04:00
Zousar Shaker
03207d24ea Allow OAuth access scope to be configurable for a Horde Storage DDC store. Supplied by partners.
#rb devin.doucette
#rnx
#preflight 623b9723c73745c600c264e6

[CL 19487258 by Zousar Shaker in ue5-main branch]
2022-03-23 18:05:53 -04:00
Devin Doucette
436b6a6461 DDC: Added IRequestOwner::LaunchTask
- Added IRequestOwner::LaunchTask to launch a task as a request in the request owner.
- Renamed ExecuteInCacheThreadPool to LaunchTaskInCacheThreadPool.
- Made GCacheThreadPool private to one source file.
- Changed task scheduling throughout DDC to use these functions where appropriate.

#preflight 623b846d8900c14eecd4daa4
#rb Zousar.Shaker

[CL 19485686 by Devin Doucette in ue5-main branch]
2022-03-23 16:56:39 -04:00
Devin Doucette
d8c983bbe6 DDC: Optimized legacy cache key validation and shortening overhead
- Validate and shorten legacy keys lazily.
- Change to ValueOnly mode for PakFile and Zen.

#preflight 623235998a6037989395baf2
#rb Zousar.Shaker
#rnx

[CL 19410386 by Devin Doucette in ue5-main branch]
2022-03-16 15:28:29 -04:00
Zousar Shaker
c36aa0e5bf Incorporate http cache store client change for partner use.
#rb devin.doucette
#preflight 62291bd50d5a90e98ecd7436

[CL 19326180 by Zousar Shaker in ue5-main branch]
2022-03-09 16:48:12 -05:00
zousar shaker
25249765d9 Avoid wasted time when pulling data from Jupiter by:
1) Increasing connection pool size
2) Allowing DNS and SSL/TLS data to be shared by connections
3) Switching to ValueOnly mode for Jupiter backends by default
4) Using "inline get" feature when querying Value data

Tested:
- .run editor -- -execCmds="Automation RunTests System.DerivedDataCache.HttpDerivedDataBackend.CacheStore;Quit" -NullRHI -stdout -unattended -ddc=DerivedDataBackendGraph_Jupiter
-Launch CitySample editor with empty local cache and open Small_City_LVL
-Launch CitySample editor with hot local cache and open Small_City_LVL

Can be improved further with a batched existence API for refs (instead of blobs).  The current one does not work due to a Jupiter server bug, so this is an improvement that will have to come afterwards.

Note: There is a known issue involving Jupiter where the server will sometimes return uncompressed blobs.  This manifests as cache misses due to invalid/rejected results returned from Jupiter.  The client handles the miss and builds the data and stores it in its local cache but does not upload it to Jupiter (because Jupiter says it already has the blob).  Subsequent runs will not suffer from the issue as the data will be present in the local cache.  There are discussions in progress for how to address this issue on server or client side.  No immediate mitigation is needed for it.

#rb devin.doucette
#jira UE-143616
#lockdown aurel.cordonnier
#preflight


#ROBOMERGE-OWNER: zousar.shaker
#ROBOMERGE-AUTHOR: zousar.shaker
#ROBOMERGE-SOURCE: CL 19104205 via CL 19104462 via CL 19104579 via CL 19104585 via CL 19110006
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v921-19075845)

[CL 19113840 by zousar shaker in ue5-main branch]
2022-02-24 10:24:10 -05:00
devin doucette
6dd39d0d04 DDC: Fixed -DDC-All-MissRate to work with callers that expect consistent hits on the same key
Fixes the accumulation of stats in the async wrapper as well.

#jira UE-143606
#preflight 6216a933a45a91013f3f4047
#lockdown Aurel.Cordonnier
#rb Zousar.Shaker
#rnx

#ROBOMERGE-OWNER: Devin.Doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-COMMAND: _robomerge UE5-Main
#ROBOMERGE-SOURCE: CL 19102208 in //UE5/Release-5.0/... via CL 19102301
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v921-19075845)

[CL 19102315 by devin doucette in ue5-main branch]
2022-02-23 17:04:41 -05:00
devin doucette
a2fba58903 DDC: Destroy the cache store graph when shutting down the cache
#jira UE-116166
#preflight 620ea11c7509be98435db253
#lockdown Aurel.Cordonnier
#rb Zousar.Shaker

#ROBOMERGE-OWNER: Devin.Doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-COMMAND: _robomerge UE5-Main
#ROBOMERGE-SOURCE: CL 19092848 in //UE5/Release-5.0/... via CL 19096129
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v921-19075845)

[CL 19096234 by devin doucette in ue5-main branch]
2022-02-23 13:47:00 -05:00
devin doucette
0e929ad2f3 DDC: Re-added the in-flight cache for async puts
- Legacy puts are now executing asynchronously.
- Memory cache now merges partial cache records.
- Memory cache is used to store data temporarily while it is being written by an async put.
- Expanded the deprecation of persisted boot/memory caches, which no longer offer the performance benefit that they used to.
- Fixed the pak file cache to skip data with a compressed size of over 2 GiB.

#jira UE-141307
#preflight 620d85f93609e19371510fb1
#lockdown Aurel.Cordonnier
#rb Zousar.Shaker
#rnx

#ROBOMERGE-OWNER: Devin.Doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-COMMAND: _robomerge UE5-Main
#ROBOMERGE-SOURCE: CL 19076205 in //UE5/Release-5.0/... via CL 19094550
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v921-19075845)

[CL 19095974 by devin doucette in ue5-main branch]
2022-02-23 13:40:18 -05:00
devin doucette
792dbb1d33 DDC: Fixed MissTypes configuration broken by the new legacy key format
#jira none
#preflight 620bd6fb475fb819ddc646c2
#lockdown Aurel.Cordonnier
#rb Zousar.Shaker
#rnx

#ROBOMERGE-OWNER: Devin.Doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-COMMAND: _robomerge UE5-Main
#ROBOMERGE-SOURCE: CL 19075175 in //UE5/Release-5.0/... via CL 19094294
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v921-19075845)

[CL 19095954 by devin doucette in ue5-main branch]
2022-02-23 13:39:39 -05:00
devin doucette
2800210897 DDC: Enabled compression of legacy cache data
- FileSystem, Http, Pak, S3 use the ValueWithLegacyFallback mode by default, which cause them to fall back to searching for uncompressed data if compressed data is not found.
- FileSystem has been fixed to store up to 1 MiB of compressed data inline with the value package rather than separately in content-addressable storage.
- Pak has been optimized to have GetChunks only load the required region of the requested value, rather than the whole value.
- Pak has been changed to stop storing data inline in the record package, since it will end up in the same file anyway when stored separately.
- Pak will upgrade the compressor and compression level when a compressed pak file is requested. Default cache compression uses Oodle Mermaid VeryFast and will upgrade to Oodle Kraken Optimal2.
- Zen does not have compression enabled by default, pending deployment of a new version that stores compressed values to Horde Storage.
- Added a missing request barrier when saving uncompressed data as compressed.

Example reduction in file system cache size when cooking for Windows:
- CitySample dropped from 66.5 GiB to 21.8 GiB.
- Lyra dropped from 2.54 GiB to 672 MiB.
- ShooterGame dropped from 1.21 GiB to 380 MiB.

Example reduction in compressed pak file cache size when cooking for Windows:
- CitySample dropped from 22.3 GiB to 18.5 GiB.
- Lyra dropped from 691 MiB to 543 MiB.
- ShooterGame dropped from 387 MiB to 313 MiB.

#jira UE-134381
#preflight 620a703f583261b0a658e043, 620a6fb2803d9066e6805310, 620a733117632e948459b6af
#lockdown Aurel.Cordonnier
#rb Zousar.Shaker

#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 18983671 in //UE5/Release-5.0/... via CL 18983890 via CL 18984096
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v917-18934589)

[CL 18984126 by devin doucette in ue5-main branch]
2022-02-14 14:43:39 -05:00
devin doucette
778a7d292b DDC: Added compression support to legacy cache values
The cache stores can individually control their "legacy mode" now, which offers a choice of ValueOnly, ValueWithLegacyFallback, LegacyOnly.
- Using ValueOnly will forward every legacy request through the Value API, which compresses values by default and supports values larger than 2 GiB.
- Using ValueWithLegacyFallback behaves like ValueOnly, but misses from GetValue are forwarded to GetCachedData, and stored with PutValue if found.
- Using LegacyOnly will forward every legacy request through the Legacy API.

FLegacyCacheValue uses shared state to ensure that each value is compressed or decompressed at most once.

#jira UE-134381
#preflight 62054b430c64e1822f41231b
#lockdown Mark.Lintott
#rb Zousar.Shaker
#rnx

#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 18940270 in //UE5/Release-5.0/... via CL 18941016 via CL 18941392
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v917-18934589)

[CL 18941401 by devin doucette in ue5-main branch]
2022-02-10 14:57:42 -05:00
Matt Peters
f76045bb7e LowLevelMemTracker - add scopes for some large allocations during cooking.
#rb Devin.Doucette
#rnx
#preflight 62047a600a1c4eb68f555ba5

[CL 18930861 by Matt Peters in ue5-main branch]
2022-02-09 21:53:31 -05:00
devin doucette
e963d14d2a DDC: Fixed the Zen cache being accidentally made read-only
#jira UE-134381
#preflight 61fcb3a2b434724823d9f733
#lockdown Mark.Lintott
#rb Zousar.Shaker
#rnx

#ROBOMERGE-OWNER: Devin.Doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-COMMAND: _robomerge UE5-Main
#ROBOMERGE-SOURCE: CL 18860637 in //UE5/Release-5.0/... via CL 18860644 via CL 18860646
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v910-18824042)

[CL 18860649 by devin doucette in ue5-main branch]
2022-02-04 00:27:54 -05:00
devin doucette
c7954aebce DDC: Switched to the async cache hierarchy and fully implemented the verify wrapper
The async cache hierarchy:
- Is required to add compression to the legacy cache by forwarding LegacyPut/LegacyGet to PutValue/GetValue.
- Is always present in the graph, unlike the previous cache hierarchy, which will allow significant simplification of leaf cache stores.
- Allows for the leaf cache store nodes to operate asynchronously without blocking a worker thread like the previous cache hierarchy.
- Shifts from controlling cache behavior by speed class to controlling cache behavior by local/remote classification, which is a critical distinction for a cache like Zen that can identify as both local and remote.
- Respects the local/remote and query/store flags in the cache policy.
- Does not fully implement the partial record cache policy at this time.
- Does not propagate records or values in GetChunks, which will be added in a future release.

The verify wrapper was previously missing an implementation for the new cache interface. This version is more efficient than the previous because requests through the new cache interface can compare data without loading it from storage, and load it only when a mismatch has been detected, to dump it to disk.

#jira UE-134381
#lockdown Mark.Lintott
#preflight 61fc32ac0a50c2606f266388
#rb Zousar.Shaker
#rnx

#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 18851861 in //UE5/Release-5.0/... via CL 18851943 via CL 18852169
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v910-18824042)

[CL 18852184 by devin doucette in ue5-main branch]
2022-02-03 16:49:32 -05:00
devin doucette
8bc347b0be DDC: Fixed TryToPrefetch when there is not one backend containing every key
#rb Zousar.Shaker
#rnx
#preflight 61f327371f12674afbc5be32

#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 18768073 in //UE5/Release-5.0/... via CL 18768076 via CL 18768140
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18768147 by devin doucette in ue5-main branch]
2022-01-27 23:16:00 -05:00