Drupal.

Troubleshooting Drupal Performance - Part II

Well, overnight the site went down, so I'm back at the drawing board to see (1) what is the specific bottleneck and (2 how to fix it.

I asked GPT what are the memory requirements for (1) mysql and (2) a drupal site, the two memory-intensive things I'm running in this system. It said, I should be okay with 4Gb of RAM. As I expected.

I adjusted mysql config but it didn't help: https://github.com/wasya-co/docker_drupal/blob/0.0.0/docker-compose.yml-template#L36 

Improving performance of Drupal Sites - Part O

I have some good news and some bad news. The good news is that my website(s) are bringing in traffic, the load is spiking. No thanks to google - I am still on their terrorist list or whatever, so even when I'm directly in front of their faces they don't see me. But my sites are gaining popularity anyway.

A first functional test in Drupal 9 (test a redirect in a controller)

...of course this took longer than anticipated, but I have achieved this milestone, writing and executing a complete functional test in Drupal. It was not an easy, trivial test - and the path I took in implementing it highlights the gotchas and difficulty of writing such tests. As well, my process is likely not be unique, and the challenges I faced appear common. It there appears valuable for me to put down a quick writeup on quirks and tricks I saw along the way. In this article, I assume the reader is an intermediate Drupal developer.

[FIXED]: Error: Call to a member function transformDimensions() on null in core/modules/ image/image.module

The issue stems from the preview being in an undefined style.

1. Go to configuration -> image styles and review the styles available. I have a style called "200x200 thumb".

2. After adding an image field to a content type, go to manage form display, expand the display of the image, and specify an existing style from step 1 as the preview style.

After taking these steps, the page for adding/editing this content type should render correctly.