The problems with config entity overrides

Fri, 2017-04-07 17:31 -- drunken monkey

Config overrides seem very handy, but can be pretty problematic when used for config entities. If you are using them in this way, you should make very sure that there aren't any unintended side effects. And if you maintain a contrib module that defines a config entity type, you should make sure they're safe to use with config overrides.

Fair warning: This blog post is mainly written for developers. While, ideally, site builders who want to use configuration overrides should also understand the inherent problems they come with, I don't feel it's possible to really explain those problems without getting pretty technical.

Search API in Drupal 8 is about to be stable!

Wed, 2017-04-05 13:09 -- drunken monkey

After more than three years of development (and several blog posts), the Drupal 8 port of the Search API module is finally getting a stable release! The current Beta 5 release will be the last Beta, and there should be a release candidate and the final, stable release within the next two weeks. So, test it now, if you haven't already, to help eliminate any remaining (major) bugs!

Create Git diffs with proper function context

Thu, 2016-02-11 13:37 -- drunken monkey

For years I have been annoyed (slightly, but still) that Git diffs for PHP classes always just contained the class header instead of the method header as the function context. I finally got round to doing a bit of research and it turns out that the solution is astonishingly easy: just one small and simple config file and it will magically work.

Large improvements for search field autocompletion

Sat, 2015-08-29 12:36 -- drunken monkey

The Search API Autocomplete module has for some years now been a popular way to add autocomplete suggestions to search fields while the user is typing. However, even though the module was popular, it had several problems and restrictions – primarily, the way the suggestions are computed only reflect the words that are indexed on the search server, not the keywords that users actually searched for. Changing this was possible (as is nearly everything else in Drupal, after all), but cumbersome, and not directly supported in any way by the module.

But, these days are now finally over with the release 1.4 of the module!

Updating the Search API to D8 – Part 5: Using plugin derivatives

Mon, 2014-08-11 14:42 -- drunken monkey

The greatest thing about all the refactoring in Drupal 8 is that, in general, a lot of those special Drupalisms used nowhere else were thrown out and replaced by sound design patterns, industry best practices and concepts that newcomers from other branches of programming will have an easy time of recognizing and using.
But, of course, this has already been discussed in a lot of other blog posts, podcasts, sessions, etc., by a lot of other people.

What I want to discuss today is one of the few instances where it seems this principle was violated and a new Drupalism, not known anywhere else, introduced: plugin derivatives.

Updating the Search API to D8 – Part 4: Creating plugin types

Fri, 2014-08-01 15:15 -- drunken monkey

The new plugin system is another large and important change in Drupal 8. While you were pretty much on your own if you wanted to provide some kind of plugin system in Drupal 7 (which a lot of modules do – think Views, Rules, etc.) there is now a very sophisticated framework to easily implement plugins and to define your own plugin types in a clean, extensible and very flexible way. And the good news for everyone familiar (code-wise) with the Search API in Drupal 7: the system is very much in line with how Search API implemented plugins itself, so the switch is pretty easy for us.

Updating the Search API to D8 – Part 3: Creating your own service

Thu, 2014-07-24 14:28 -- drunken monkey

Even though there was somewhat of a delay since my last post in this series, it seems no-one else has really covered any of the advanced use cases of Drupal 8 in tutorials yet. So, here is the next installment in my series. I initially wanted to cover creating a new plugin type, but since that already requires creating a new servive, I thought I'd cover that smaller part first and then move on to plugin types in the next post.
I realize that now already a lot more people have started on their Drupal 8 modules, but perhaps this will make this series all the more useful.

Pages

Subscribe to drunken monkey RSS