0
votes

we're developing a drupal 8 site with several developers. Therefor, each one of us has his own drupal instance on the dev machine (to avoid getting errors with different template file states and stuff), and they are set up like this:

  • /srv/www/devDudeA/html (instance A root)
  • /srv/www/devDudeB/html (instance B root)
  • /srv/www/devDudeC/html (instance C root)
  • and so on...

These instances are all connected to the SAME database. After writing a twig extension module (delivering a necessary twig filter) and activating it, some of my colleagues are getting several exceptions (saying the module couldn't be found), though they definitely have the same module files like me.

Do you know of trouble using the same database from different hosts? I suspect the cache is causing trouble (because i found some paths entries containing "devDudeA" or "devDudeB" in the database.

In my opinion the requiredments should be satisfied:

  • same module files in the same directory on each instance
  • same module information from (same) DB

IMHO there is the opcache and also a memcache. The integrated twig engine also has his own cache. Could it be a problem that one of us has his caching enabled while the others don't?

Im just getting crazy about this (O.x). Do you have any relevant instructions for me?

Thanks in advance & kind regards!

1

1 Answers

0
votes

If you are going to have multiple devs actively working on multiple sites with a shared database odd bugs like this are going to come up. Likely a cache rebuild will resolve it, but a similar error may appear for another user. Basically you are doing something Drupal doesn't want to do.

Since you're in Drupal 8 the reasons people used for shared databases in Drupal 7 and before are largely gone. The Drupal 8 configuration management system is a vast improvement over the previous versions. You can now move site configuration using YML files between instances of the site. Those files can be managed with the rest of your code.

And you can look at using the deploy module (and supporting modules) to move content between instances.