core
core copied to clipboard
Multilingual content related slows down edit content screen
Describe the bug
When you create content in diff locales and relate that content to any other content. When trying to open the "parent" content it takes longer to open because of the loading of the flags of the locale.
To Reproduce
Steps to reproduce the behavior:
- Create 33 languages
- Create a child content type (text field only)
- Create a parent content type (text field and relationship field to child)
- Create a child content with versions in each of the languages
- Create parent content and relate to the child.
- Save/Publish the parent.
- Open again the parent to edit, it takes around 1 sec to open the edit screen.
- Create another parent content, just fill the text field.
- Open again the parent to edit, it takes around 200ms to open the edit screen.
Expected behavior
Regardless of the number of locales and content versions, shouldn't take so long to open.
Reproducible in 22.03 LTS and demo (22.08). Customer ticket https://dotcms.zendesk.com/agent/tickets/108328
PRs: #22943 #22956
Looks good to me. Performance wise the dialog shows up with all the related elements timely. Less than 1 sec or so. Found another issue reported here https://github.com/dotCMS/core/issues/22961 The issue is reproducible on master therefore I am passing this
Approved QA - Tested on 22.10_a3659b56_SNAPSHOT // Docker // macOS 12.6 FF v105