Problem/Motivation
#2502785: Remove support for $form_state->setCached() for GET requests has removed the support for $form_state->setCached() for GET requests and there are a lot of reasons for doing this and for the most of the use cases it makes perfect sense, however not in our use case where we have a CMS which does not have any open registrations and zero anonymous users and is used only by a specified number of users. The content entity forms which we use might be heavy and expensive to build. Usually in our case in 95 % of the time a user requests an edit form the intention will be to perform some editorial actions and one of the first actions in the most cases will be an ajax request, as our edit forms rely a lot on ajax.
Having said that in our case it will be better to cache the form and the form state on the GET request instead on the first ajax request, as by doing so the form will be built only once on the first ajax request instead of twice as it is currently, as form building is expensive in our system and doing it twice on the first ajax request makes the response time larger.
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Comment | File | Size | Author |
---|---|---|---|
#14 | 2851251-14.patch | 1.88 KB | ranjith_kumar_k_u |
#4 | interdiff-3-4.txt | 678 bytes | hchonov |
#4 | 2851251-4.patch | 1.86 KB | hchonov |
#3 | 2851251-3.patch | 1.86 KB | hchonov |
Comments
Comment #2
hchonovComment #3
hchonovComment #4
hchonovI've forgotten to negate the setting.
Comment #14
ranjith_kumar_k_u CreditAttribution: ranjith_kumar_k_u at Zyxware Technologies commentedRe-rolled #4 for 9.3