Questions tagged [performance]

Use it for questions about Drupal's performance, how to measure, and improve it.

Filter by
Sorted by
Tagged with
0
votes
1answer
30 views

Debug slow drush within Docker Drupal Container

I just moved from Lando (https://docs.lando.dev/) to the native Drupal Docker Image (https://hub.docker.com/_/drupal/), anything is working quite well beside the fact that Drush is running about 10 ...
-2
votes
0answers
63 views

Standalone entity edit and create forms

We have a site that uses a lot of nested entities (through the Paragraphs module). As there are nested entities and lots of content, we experience that the node edit forms take between 30-60 seconds ...
2
votes
2answers
134 views

Is it helpful to improve performance by mysql table indexing?

Yes I am talking about manually indexing drupal cache table. Is it helpful to improve site performance by indexing cache table? For ex:: SELECT cid, data, created, expire, serialized, tags, checksum ...
0
votes
0answers
24 views

Possible to get a render array from a loaded entity without calling ->getViewBuilder()->view()?

I'm working on the performance of a code block that contains 3 lines that are the main contributors to latency: A paragraph library item is loaded from the DB A paragraph is loaded from the DB using ...
0
votes
0answers
34 views

How do I profile a REST API request from the Simple oauth module?

I am trying to profile a REST API endpoint (/oauth/token) for performance issue. I want to see what database queries are executed during that API request. Can I get it using webprofiler with the Devel ...
1
vote
2answers
56 views

How can webform performance be improved on low internet connection?

I built a site with Drupal 9 and webform. The form consists of three pages and contains a few computed fields. On the first page are mandatory fields. The form is used by logged-in users only. When on ...
0
votes
0answers
45 views

Adding a dependent field with the Business Rules module makes the loading time and queries increase abnormally

I have an entity form with a dependent field. The dependent field is created following this guide and using Business Rules module. Everything works fine, but now the form takes an insane amount of ...
3
votes
0answers
35 views

Speed up login after changing user name datastore type to VARBINARY from VARCHAR

We have a project underway that requires the import of ~6 million users into Drupal (Core 7x) that have many (150K+) case-insensitive duplicate usernames. Importing these users with existing case and ...
0
votes
1answer
278 views

How do I set the height and width for images that use a responsive images style?

When using the core Image module, the height and width of images are automatically set. But when I use the Responsive Images module and a Responsive Image style, then no height or width is set. Users ...
0
votes
1answer
41 views

ExtensionDiscovery::scanDirectory() takes too long

I have been debugging a bit an issue on our platform and I notice that our scanDirectory takes, from time to time, way to long, more than 100seconds. I have been looking at the default.settings.php ...
0
votes
0answers
39 views

Implementing hook_entity_type_build causes 500 error on cache clear

I recently attempted to display custom form modes based on the currently logged in user. My searching led me to implement hook_entity_type_build. However, I am finding that even just having this ...
0
votes
0answers
34 views

For performance, one multi-value field or four individual fields?

I have a node content type that needs to store four different int values: Score A Score B Score C Score D Each node of the content type always has all four int values. I could store this one of two ...
0
votes
1answer
103 views

The “Modules” page doesn't load

I am running a setup on Ubuntu and WSL (Windows Subsystem for Linux) with Nginx and PHP7.4. Drupal 8 and Drupal 9 fresh installations load every page with no problem, except the page on /admin/...
0
votes
0answers
20 views

Select which assets and scripts should load on certain pages

This is to avoid loading other assets and scripts that are not needed for certain content types, pages, etc. I have seen this in wordpress, there are performance plugins that allow you to selectively ...
0
votes
1answer
105 views

Advanced CSS/JS Aggregation Module Breaks My Site Layout

When I enable my module Advanced CSS/JS Aggregation it breaks my site layout. Is there something I need to do before or after when enabling this module. To fix the site layout I need to disable the ...
3
votes
1answer
91 views

How do I free the memory used from node_load()?

I am using code similar to the following one. for ($i = 0; $i < 1000000; $i++) { $nid = get_node_id($i); $node = node_load($nid); $data = [ $node->field_1, $node->field_3, ...
1
vote
1answer
32 views

How does routing order / matches effect performance?

I have all the following GET routes defined in my_module.routing.yml: my_module.members_uid: path: 'users/{user}' my_module.members_uid_gid: path: 'users/{user}/group/{group}' my_module.user....
5
votes
1answer
992 views

Why does loadMultiple load 1000 nodes 9.2 times faster than loading each node one by one?

I have always known that loading multiple nodes at the same time is faster than loading them one by one. What I wasn't aware of, is the huge performance difference between the two ways of loading ...
1
vote
2answers
182 views

How to achieve clean HTML markup?

If you visit official website of Dries Buytaert https://dri.es/ and look into the source you will see very clean and minimal markup with no unnecessary tags and classes, eg: When I create a simple ...
0
votes
1answer
30 views

Do custom theme suggestions execute on every page load and does that impact performance?

I've been working with Drupal for a little while now and one nagging question I've had is about whether or not logic in my *.theme or *.module files have any impact on server load. Let's say I have ...
-1
votes
1answer
176 views

Create the FooTable functionality by using only views

I noticed by using FooTable display on one of my view on a Drupal 8 site, it is increasing the load time of the view by more than 2000 ms. The main idea i am using Footable is because of the ability ...
3
votes
0answers
199 views

Warming up dynamic page cache for authenticated users

We're currently working on a rather complex Drupal 8 based website. After clearing caches, the majority of pages/routes require about 30-60 seconds for being rendered/returning the desired results. ...
1
vote
1answer
144 views

How to make use of the render placeholder system for cacheablejsonresponse?

I have custom controllers which provide CacheableJsonResponse responses. Those responses are quite heavy to build (couple of seconds), so I want to build them better. I build those responses by ...
0
votes
1answer
608 views

Serve compressed JS and CSS with S3 as filesystem

We have a Drupal 8 site using S3 file system integrated via the S3 File System module. The aggregated CSS and JS are uploading on S3, however I am not seeing any configuration to serve compressed ...
-1
votes
2answers
104 views

Database Insert Slower On Production Server [closed]

I recently upgraded the PHP version to 7.1 on my production server. I also updated my local to 7.1 and staging to 7.1. Only on production, I am seeing a slow down when I import a csv file and insert ...
0
votes
0answers
68 views

Solr-based View, Row cache

Context: Drupal 8.5, Search API Solr 2.2 There's a Solr-based view with Field display mode, as the results are not just nodes, there are non-Drupal content too. Right now the dynamic page cache is ...
1
vote
1answer
197 views

How should I deal with a vocabulary with many terms?

I'm trying to use Drupal 8, but if Drupal 7 is better for that, I'm ready to go back to Drupal 7. I have a vocabulary that must contain at least 10,000 terms, but they can also become more than 100,...
1
vote
0answers
206 views

Diagnosing slow requests between Varnish and Nginx

I have been trying to diagnose slow page load time in my local Drupal 7 environment when using Varnish. My local environment runs in Docker using docker-compose. I have a containerised Varnish ...
0
votes
0answers
77 views

Very slow menu_tree_check_access query - how to debug

I have a Drupal System which is running fine in production and locally but the dev/cons Db seems to have a problem. After looking a bit deeper into it I found that menu_tree_check_access takes 3.8 Sec ...
0
votes
1answer
77 views

db_insert a lot of records

I am struggling to sort out how to insert a lot of records using db_insert Please see below for the code. I can't have a for loop in the array. It breaks but I am dealing with looping through a lot ...
1
vote
1answer
185 views

Increasing performance of cache_form on high traffic sites

I am noticing a significant performance increase in my load testing when this table is small, but due to a large traffic site this is growing very quickly. I have read that it is not a good idea to ...
2
votes
1answer
211 views

Serve Anonymous Pages when users are logged in for some pages

so essentially I have a Drupal website with great performance for anonymous users and terrible performance for logged in users. What I am looking for is a way to serve some pages that logged in users ...
1
vote
0answers
39 views

How can I drill down to find the culprit function? [closed]

I can see high CPU usage when I hit search URL of my Drupal application. I have enabled XHProf module and UProfiler extension on PHP5.6 to find the culprit function. But the report I am getting is ...
2
votes
1answer
1k views

remove link tags in head

I am working on a project involving migrating a site with many static pages to Drupal 8. Since a number of the pages are old blog posts, there's often broken links, broken images, etc. For quality ...
1
vote
0answers
44 views

Page not found errors for images

The site becomes painfully slow at times and when I look into "Recent Log Mesaages" logs such as this is frequently found. The Location shows: http://example.com/sites/default/files/styles/featured/...
1
vote
1answer
64 views

Is it better for performance to disable unused default core views?

I'm seeing 5 views on my site that I'm not using and want to disable to keep things clean and performant, but I worry it could cause a problem somewhere down the road. The views are: Frontpage (...
0
votes
4answers
5k views

Performance is notoriously slow

This feels like a repeat post but I can't find an actual answer. I just installed Drupal 8.4.4 on an Azure App Service (S3 Standard 4core 7GB RAM / PHP 7.0.6) and Azure Database for MySQL (Standard ...
0
votes
1answer
343 views

How to change URL images for CDN

I have a website in Drupal 7 with "N" images in Sites/default/files and I need move this images to CDN. Is this possible?
0
votes
1answer
68 views

Hundreds of unserialize requests

I have a large Drupal 7 website on my hands that is very large and has loads of modules (over 200). I am already seeing poor performance symptoms in the FPM logs with max_children limits reached on ...
0
votes
0answers
358 views

Performance hit from using the Statistics module?

For a site that we will have 99% of users seeing Varnish/Memcached layers, what is the general performance hit to enabling the core Statistics module? The site may have thousands of visitors daily. ...
4
votes
1answer
927 views

Improve D8 performance to access a custom REST controller

Context I'm currently upgrading a site from Drupal 7 to Drupal 8. In the D7 version, there was a custom "proxy" module which served back-end services. Requests starting with a /service prefix, such ...
-2
votes
3answers
3k views

Slow Drupal 7 Load Time [closed]

I have a 10 second page load time on Drupal 7.52. It has the approximately the same problem on localhost and my server. On my localhost (WAMP) Apache uses an insignificant amount of CPU (3% or less)....
3
votes
2answers
524 views

Rules: Load List of Entities by Object or Entity ID (Performance)

I'm looking to load a list of Users by an Entity Reference Property within Rules. There may be times when I need to load hundreds or thousands of Users that have a matching Property to update a ...
0
votes
1answer
92 views

Nightly truncating all cache_* tables? Good or bad?

I'm having some issues on various D7 sites with some cache tables growing stupidly large (e.g cache_metadata or cache_menu) which then makes drush cc all very slow (more than 1 minute). Do you think ...
1
vote
2answers
197 views

How do I setup Drupal/Varnish caching so Content Editors don't see browser-cached pages after logging in?

I've got a bit of a situation going on with our caching solution and would love some input. We use a solution of HAProxy -> Varnish -> Apache. HAProxy terminates SSL and sends that to Varnish which ...
0
votes
1answer
108 views

Most performant way to check if a user is referenced in any node of a specified type?

I need to get a list of all users that have a specific role. Those users can be referenced in a multivalue field of a specific content type; some users are referenced in multiple nodes of that content ...
1
vote
0answers
24 views

Site flashes intermediate 'Redirecting to …' page

On a local development site an intermediate 'Redirecting to ...' page flashes for a second before rendering the correct page. This seems to be happening at various places, even on cron run page. The ...
-1
votes
1answer
20 views

Image Optimaization

Dears, i have images with 2000 * 700 pixel and i have to render those images in two different places one with original diminution while the second is with 100 * 60 pixel so each time i have to load ...
3
votes
0answers
364 views

Forms get glitchy with too many nested paragraphs

We have built a complicated structure for building pages out of paragraph components, but are now quickly running into performance limitations. It seems that the node form is monolithic, and is built,...
0
votes
1answer
809 views

Data coming from entityTypeManager->getStorage is cached data?

I am working on one Drupal 8.3 site. I created my own custom Authentication provider for REST API authorisation. Following are the "authenticate" method sample code. /** * {@inheritdoc} */ ...

1
2 3 4 5
11