Best Practices for a shared Derived Data Cache?

Greetings,

I’m wondering if anyone here has developed some best practices for using a shared DDC. We often have multiple projects in the pipe, and I’m wondering if it would be better or not to split them up into multiple caches despite having some shared assets, or to keep everything in one big pool. I’m also wondering how often the DDC should be cleaned out, as ours is getting quite large and I’m not sure if the mechanisms in place are keeping unnecessary items out of it.

The only documentation I could find on this is pretty light and does note even explain what all the variables mean:

For example, what are the following variables even supposed to do and how can we best take advantage of them?
Clean=false, Flush=false, DeleteUnused=true, UnusedFileAge=19, FoldersToClean=-1

Any tips or tricks on this subject would be greatly appreciated!

Thanks,
​​​​​​​Bill

Would also love to have more information on this!

“If you just want to clean/nuke DDC once, you would be better off just running it through the command line” → how do you set that ‘Clean’ variable to ‘true’ through the command line? (Do you mean unreal’s console or the OS command line?)

Digging up an old thread, but I found that BaseEngine.ini does contain a description of all options at the beginning of the [DerivedDataBackendGraph] section. Here’s an excerpt as of UE 5.0.0:

; Configure the local cache. This is a FileSystem cache with the following parameters:
;	ReadOnly: Can data be written to this layer. Default is false.
;	Touch: Update timestamps on every access instead of only after 1/4 of UnusedFileAge. Default is false.
;	PurgeTransient: Delete transient data from the cache. Default is false.
;	Clean: Perform a cleanup of old files on launch. Default is false.
;	Flush: Clear the DDC and start over on launch. Default is false.
;	DeleteUnused: Whether to clean up old files on a background thread. Default is true.
;	UnusedFileAge: Age since last access after which files are removed. Default is 15 days.
;	FoldersToClean: Max number of folders to clean in a session. -1 = Unlimited. Default is -1.
;	PromptIfMissing: If the path does not exist a warning prompt will be shown. This is useful for shared DDCs where the mount may have dropped. Default is false.
;	ConsiderSlowAt: If access times are less than this value in ms then some operations will be disabled to improve performance. Default is 50ms.
;	MaxFileChecksPerSec: Maximum file cleanup checks to do in one second. Default is configured in Engine:[DDCCleanup]:MaxFileChecksPerSec.
;	Path: Path to use for the filesystem DDC.
;	EnvPathOverride: An environment variable that if set will be used instead of Path. E.g., UE-LocalDataCachePath=D:\DDC. ('None' disables the DDC)
;	CommandLineOverride: A command line argument used in preference to the Path / EnvPathOverride settings. E.g., -SharedDataCachePath=\\someshare\folder
;	EditorOverrideSetting: Editor user setting that overrides the Path / EnvPathOverride line values.
;	LegacyMode: Where to look for legacy cache keys in storage. One of ValueOnly, ValueWithLegacyFallback, LegacyOnly.
;		ValueOnly: Look only for compressed data in the 5.0+ directory layout.
;		LegacyOnly: Look only for uncompressed data in the pre-5.0 directory layout.
;		ValueWithLegacyFallback: Look in the 5.0+ location but fall back to the pre-5.0 location on miss.
1 Like