Search Issue Tracker
By Design
Votes
0
Found in
2017.4.0f1
2018.4.0f1
2019.2.0a1
2019.2.5f1
2019.3.0a1
2020.1.0a1
Issue ID
1185256
Regression
No
WebGL builds have performance issues when many parallel UnityWebRequests are sent
How to reproduce:
1. Open the attached project ("case_1185256-loadingTest2019.zip")
2. Change targeted platform to WebGL
3. Make a WebGL build
4. Include the "Assets/pngs" folder in the build folder
5. Run the build and press the "Load" button
Expected results: Images are loaded asynchronously without noticeable performance drop
Actual results: Build has a noticeable performance drop while loading the images
Reproducible with: 2017.4.32f1, 2018.4.10f1, 2019.2.7f2, 2019.3.0b5, 2020.1.0a6
-
rendermouse
Sep 02, 2021 21:49
example:
var gameInstance = UnityLoader.instantiate("gameContainer", "Build/web.json", { onProgress: UnityProgress, Module: { CachedXMLHttpRequestDisable: true } });
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Fixing Message Loss in UMPE During Domain Reload
- The Editor freezes when ScheduleReadOnly of IJobParallelForTransform with dependency is used
- Text is truncated in the Inspector when the display scale is set to 150%
- CancellationTokenSource(<timeout>) has incorrect cancellation status when used in WebGL Player
- VFX property value names are cut off when properties with 'Arc' are viewed in the VFX Blackboard
Resolution Note:
Starting from Unity 2019, CachedXMLHttpRequest is automatically used for UnityWebRequests (which allows to cache http responses in the indexedDB), unless specified otherwise. In this particular case, the responses are cached, which causes the performance issues.
This issue can be resolved by setting "Module.CachedXMLHttpRequestDisable" instantiate parameter to "true", which should disable CachedXMLHttpRequest for UnityWebRequests