Commit Graph

23 Commits

Author SHA1 Message Date
devin doucette
3df0bf7f14 DDC: Gather bucket stats from the new ICacheStats
#jira UE-133395
#rb Matt.Peters
#rnx

[CL 26555188 by devin doucette in ue5-main branch]
2023-07-24 16:52:05 -04:00
nick edwards
723c5d5999 Fix C++20 compiler error. Add new equality operator for FCacheBucketOwner to avoid ambiguity when reversing arguments.
bool FCacheBucketOwner::operator==(const FCacheBucketOwner& Other) is new
bool FCacheBucketOwner::operator==(const FCacheBucket& Other) is what it would find ambiguous

#preflight 6419f58b25389270b78540dd
#jira none
#rb none

[CL 24759829 by nick edwards in ue5-main branch]
2023-03-23 06:59:24 -04:00
devin doucette
c2f32c0b05 DDC: Simplify FCacheBucketOwnerKeyFuncs
#rb Zousar.Shaker
#rnx

#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 20883184 via CL 20885166 via CL 20885259
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v971-20777995)

[CL 20887595 by devin doucette in ue5-main branch]
2022-06-29 21:31:27 -04:00
zousar shaker
cbf5582373 Fix checkSlow failure in Debug caused by missing KeyFuncs when using a TSet.
#jira UE-157861
#rb matt.peters

#ROBOMERGE-OWNER: zousar.shaker
#ROBOMERGE-AUTHOR: zousar.shaker
#ROBOMERGE-COMMAND: _robomerge[bot4] UE5-MAIN
#ROBOMERGE-SOURCE: CL 20861323 via CL 20861342 via CL 20861361
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v971-20777995)

[CL 20861441 by zousar shaker in ue5-main branch]
2022-06-28 13:11:13 -04:00
devin doucette
727e9a9b4a DDC: Optimized cache key construction and shared string serialization
#preflight 62b4be8bbe326a8b04f4ab0c
#rb Zousar.Shaker
#rnx

#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 20833516 via CL 20835073 via CL 20835503
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v971-20777995)

[CL 20837863 by devin doucette in ue5-main branch]
2022-06-27 15:21:57 -04:00
devin doucette
6366a19bda DDC: Added functions to serialize cache types to and from compact binary, and strings where appropriate
#rb Zousar.Shaker

#ROBOMERGE-OWNER: devin.doucette
#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 20741868 via CL 20744192 via CL 20745275
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v970-20704180)

[CL 20751385 by devin doucette in ue5-main branch]
2022-06-20 23:40:01 -04:00
devin doucette
3933b8f407 DDC: Added TryLoadFromCompactBinary for FCacheKey
#rb Zousar.Shaker
#rnx

#ROBOMERGE-AUTHOR: devin.doucette
#ROBOMERGE-SOURCE: CL 20705430 via CL 20705467 via CL 20705498
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v968-20684695)

[CL 20707645 by devin doucette in ue5-main branch]
2022-06-17 14:45:17 -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
8c27714a84 DDC: Added ConvertLegacyCacheKey to construct new cache keys from legacy cache keys
The function is shared with the legacy cache store to allow callers of the legacy API to migrate to the value API using this conversion function without invalidating existing cache keys.

#preflight 624c9ab68d1db441a913137e
#rb Zousar.Shaker

[CL 19630681 by Devin Doucette in ue5-main branch]
2022-04-05 16:27:17 -04:00
matt peters
c19bac1163 FCacheKey: Add operator<< to write to an FCbWriter.
FCacheRecord: Add Save function that allows appending to an existing package.
#preflight 61f174dcf8088a3d298c6e48

#ROBOMERGE-AUTHOR: matt.peters
#ROBOMERGE-SOURCE: CL 18736675 in //UE5/Release-5.0/... via CL 18736693 via CL 18737351
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)

[CL 18737679 by matt peters in ue5-main branch]
2022-01-26 12:31:58 -05: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
7f0835f571 DDC: Fixed non-unity compile errors
#rb trivial
#rnx

[CL 17079642 by Devin Doucette in ue5-main branch]
2021-08-05 22:29:19 -04:00
Devin Doucette
d0e04a4a76 DDC: Factored out cache bucket name validation and aligned it more closely with build function name validation
[CL 16509861 by Devin Doucette in ue5-main branch]
2021-05-31 12:43:42 -04:00
Devin Doucette
155d29af66 DDC: Fixed checkSlow by adding otherwise-unused GetTypeHash for FCacheBucketOwner
#rb Zousar.Shaker
#rnx

[CL 16449009 by Devin Doucette in ue5-main branch]
2021-05-25 11:02:36 -04:00
Devin Doucette
95aa03cd0d DDC: Simplify FCacheBucket
#rb Zousar.Shaker
#rnx
#preflight 607d0e59099fea0001460d34

[CL 16053217 by Devin Doucette in ue5-main branch]
2021-04-19 14:28:07 -04:00
Devin Doucette
9a7c5e5a52 DDC: Fixed a static analysis warning in the cache bucket constructor
#rb trivial
#rnx

[CL 15697979 by Devin Doucette in ue5-main branch]
2021-03-15 13:05:50 -04:00
Devin Doucette
490d684d40 DDC: Clean up a few details in the new Cache API
#rb Zousar.Shaker
#rnx

[CL 15681766 by Devin Doucette in ue5-main branch]
2021-03-11 18:12:08 -04:00
Devin Doucette
7d5d9f3798 DDC: Clean up a few details in the new Cache API and remove the last exported type from DDC
#rb Zousar.Shaker
#rnx

[CL 15670275 by Devin Doucette in ue5-main branch]
2021-03-10 17:33:38 -04:00
Devin Doucette
017b41eb57 DDC: Refactored the new Cache API to support its use through only an interface dependency
#rb Zousar.Shaker
#rnx

[CL 15666872 by Devin Doucette in ue5-main branch]
2021-03-10 12:23:29 -04:00
Devin Doucette
f255d91cdd DDC: Simplified comparison of FCacheBucket and the keys that depend on it
#rb Zousar.Shaker
#rnx

[CL 15514773 by Devin Doucette in ue5-main branch]
2021-02-24 11:46:41 -04:00
Devin Doucette
7e2e44ebf4 DDC: Refactored the Cache API to prepare for the Build API
- Removed the "Cache" prefix from ECachePriority, FCacheRequest, ICacheRequest, FCachePayload, FCachePayloadId to allow reuse in the Build API.
- Added FCompressedBuffer as the starting point for the API for creating and accessing compressed buffers.

#rb Zousar.Shaker
#rnx

[CL 15511723 by Devin Doucette in ue5-main branch]
2021-02-24 01:37:45 -04:00
Devin Doucette
c13b0dbecf DDC: Updated the new cache interface to expose compression of cache records
- FCacheRecord must now be created by FCacheRecordBuilder.
- FCacheRecord values are always an opaque buffer now, and ECacheRecordType has been removed.
- FCachePayload has been added as a common type for the cache record value and attachments.
- FCachePayloadId has been added as a 12-byte identifier for cache payloads.
- ICache::GetAttachments is now GetPayloads and can fetch both values and attachments.
- ECachePriority::Blocking has been added for requests that the caller will block on.

#rb Zousar.Shaker
#rnx

[CL 15471951 by Devin Doucette in ue5-main branch]
2021-02-19 11:26:34 -04:00
Devin Doucette
7bd5b197e8 DDC: Added the new cache interface UE::DerivedData::ICache
ICache will eventually replace the existing cache access functions on FDerivedDataCacheInterface. The notable differences relative to the existing interface are:

- It is asynchronous with completion callbacks by default, and allows waiting when necessary.
- It allows batch requests containing multiple cache records by default.
- It uses a structured cache key made up of a bucket name and a hash.
- It supports prioritization and cancellation of requests.
- It supports structured cache records with metadata.
- It supports attachments to allow multi-part cache records.
- It uses a typed request object instead of an opaque integer handle.
- It provides cache policy flags to control how to query and store cache records, and which parts of a cache record to fetch.

This initial implementation of ICache is totally synchronous and uses the existing cache backends for storage.

#rb Zousar.Shaker

[CL 15152247 by Devin Doucette in ue5-main branch]
2021-01-21 01:57:01 -04:00