After updating my 2021.1 project to 2021.3 (LTS) my localization addressables are taking 100x+ time longer to load when Addressables Play Mode Script is set to Use Asset Database.
From the profiler I noticed the issue was stemming from LocalizedAssetBehaviour.OnEnable->Loading.ReadObject->Loading.ReadObjectThreaed->ReadObjectFromSerializedFile (took 765992 ms)
When the Addressable Play Mode Script is set to “Use Existing Build” the performance is much the same as it was before updating Unity.
I attempted to debug what was taking so long, but not sure If I got good results or not, my best guess would be some method in ContentBuildInterface like GetPlayerObjectIdentifiersInAsset or GetPlayerDependenciesForObject.
Also, build times around Localization tables have increased significantly, specifically due to “Calculate Asset Dependency Data”.
Notable changes from update
- Updated from Unity 2021.1.15f1 to Unity 2021.3.8f1
- Updated from Localization Package 1.1.1 to 1.3.2
- Updated from Addressables 1.19.15 to 1.19.19
- Updated from Scriptable Build Pipeline 1.19.5 to 1.20.1