Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 291687

Compress ajax_page_state

$
0
0

Problem/Motivation

ajax_page_state is a list of the 'minimal representative set' of libraries on page, which can still be a long list. We should compress it, this will allow it to be passed into GET requests per #956186: Allow AJAX to use GET requests.

The mechanism for this has already been added in #3303067: Compress aggregate URL query strings.

Steps to reproduce

Some hosting environments limit the length of URLs, see

#3380486: Extremely long Views AJAX query string triggers 403 in AWS
#3384852: Ajax Pager broken after upgrade 10.0.9 to 10.1.2

Proposed resolution

Remaining tasks

User interface changes

API changes

Due to a new middleware that uncompresses ajax_page_state as soon as a request is received, there is no API change for any code that expects it to be an array - it's still n array. Similarly, ajax_page_state is compressed only when it's about to be put into Drupal settings at the very last moment, so there's no API change for manipulating it.

WebTestCase::getDrupalSettings() and WebDriverTestCase::getSettings() both get a new $uncompress_ajax_page_state argument defaulting to TRUE and commented out per the deprecation policy. This means most cases for getting the parameter will also be unchanged, but if some really wants to get the raw compressed string they still scan.

Data model changes

Release notes snippet


Viewing all articles
Browse latest Browse all 291687

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>