Skip to main content

Welcome to the Drupal Playground!

Hey there, Drupal enthusiasts! 🎉

We’re thrilled to welcome you to Drupal Playground, where creativity, innovation, and the power of Drupal come together. This is your space to explore, learn, and build amazing things using one of the most flexible CMS platforms out there.

Happy Drupaling!
— The Drupal Playground Team

Drupal Interview Questions

 How to Create a Drupal Multisite? 

In multisite, I create separate folders under /sites for each domain, configure individual settings.php with separate databases, and install Drupal per site while reusing the same codebase.

Ex : sites/site.domain1/settings.php

        sites/site.domain2/settings.php

In multisite, even though the codebase is shared, module enablement is stored in each site's configuration. So enable the module only on the required site via admin or drush, and it remains disabled on other sites because they have separate databases. Then you must maintain separate config sync folders per site.

$config_directories['sync'] = '../config/site1';

In multisite, apart from settings.php, we use services.yml for service overrides, separate files directories for uploads, private file paths, and most importantly separate config sync directories to isolate configuration per site.

How to Create a Multilingual Site ?

Step 1 — Enable modules

  • Language

  • Content Translation

  • Interface Translation

  • Configuration Translation

Step 2 — Add languages

Admin → Configuration → Languages → Add (e.g., French, German)

Step 3 — Enable translation for content types

For each content type → enable translation.

Step 4 — Configure URL language detection

Options:

  • URL prefix: /fr, /de

  • Domain-based

  • Session-based

Step 5 — Translate content

Each node will have translation tabs.

Note : Cache context languages ensures proper caching in multilingual sites.

What is Acquia Cloud? 

 Acquia Cloud is Drupal-optimized managed hosting with Git-based deployments, autoscaling, and monitoring tools like Insight and New Relic.

What is Acquia Content Hub ? 

One site publishes content → others automatically receive it.

How it works (very important)

Step-by-step:

1️⃣ Publisher site creates a node
2️⃣ Content Hub converts it to CDF (Content Data Format)
3️⃣ Sent to Acquia cloud
4️⃣ Subscriber sites pull it
5️⃣ Node recreated using UUID

Every Drupal entity has a: UUID = Universally Unique Identifier

Content Hub synchronizes entities using UUID rather than node IDs, ensuring consistent content mapping across independent Drupal sites.

During Content Hub setup, each site is configured with Acquia credentials and assigned a role as Publisher or Subscriber. The publisher pushes selected entities to the hub, and subscribers pull and recreate them using UUID mapping.

The role of publisher or subscriber is not guessed; it is explicitly configured in the Content Hub settings using Acquia API credentials.

What is CDF and How it works ? 

Content Hub does not act as a shared database. The publisher sends content in CDF format to the Acquia Content Hub cloud, and subscriber sites pull that data and recreate the entities in their own local databases using UUID mapping. Content Hub is a content distribution system, not a content storage system.

Step 1 — Publisher site

  • A node is created/updated
  • Content Hub module converts it to CDF (JSON format)
  • Sends it to Acquia Content Hub Cloud

Step 2 — Content Hub Cloud

  •  Temporarily holds this CDF
  •  Acts like a message broker / distribution system
  •  Does NOT behave like a Drupal database

Step3 - Subscriber Site

  • Polls/pulls from Hub
  • Receives CDF
  • Recreates the entity in its own database using UUID

Subscriber sites pull content from the hub using Drupal’s queue system triggered by cron. The Content Hub module processes queued CDF items and recreates entities locally using UUID mapping.

Hub retains CDF data for a retention period.

Content Hub maintains:

  • Message history

  • Delivery tracking per subscriber

  • Retry mechanism

Each subscriber has its own sync state with Hub.

Hub knows:

  • Subscriber A received item X
  • Subscriber B not yet
  • Subscriber C failed, retry later 

Content Hub maintains delivery state per subscriber and retains CDF data for a retention period. It ensures all subscribers successfully pull the content before eventually purging old messages. This makes it reliable even if some sites are temporarily down. 

What is Acquia DAM ? 

DAM = Digital Asset Management

Instead of uploading media to Drupal, assets are managed centrally in Acquia DAM and referenced in Drupal via API, ensuring governance and reuse across sites.

Acquia DAM is not just storage like S3; it is a digital asset governance platform with metadata, versioning, and workflows. Drupal consumes assets from DAM via API instead of storing them locally.

DAM maintains version history of assets, so when an image is updated, all Drupal sites referencing it automatically use the latest approved version without re-uploading.

Governance = who can upload, approve, use assets

DAM provides:

  1. Roles & permissions - Who can upload /edit
  2. Approval Workflow - Asset must be approved before use
  3. Metadata rules - Tags, Categories mandatory
  4. Expiry dates - Old asset auto-expire
  5. Usage tracking - Where asset is used

Governance in DAM means controlling who can upload, approve, tag, and publish assets with proper workflows and metadata. Versioning ensures assets can be updated without breaking references, and all Drupal sites automatically use the latest approved version.

Summary :

Multilingual: Language modules + URL prefix
Cache: languages context
Multisite: Same code, different DB


Comments

Popular posts from this blog

Integrating ChatGPT with Drupal 10: A Step-by-Step Guide

  In this blog post, we will guide you through the process of integrating OpenAI’s powerful language model, ChatGPT, into your Drupal 10 website using the OpenAI Contrib module. We'll walk you through the steps of downloading the OpenAI Contrib module (using beta4), setting up an API key from OpenAI, and configuring your Drupal site to use this key for seamless integration. Before you begin, make sure you have an active OpenAI account and have generated your API key from the OpenAI platform. This key will be used to authenticate and allow your Drupal site to interact with the OpenAI service. Steps : 1. Get the latest version of  Open AI  module from the Drupal website and install it on your site.    2.  After installing and enabling the module, navigate to the OpenAI configuration settings and enter your API key.   Generate your OpenAI API key by visiting https://openai.com/api/ .       3.  After configuring the API keys, go to the ...

Drupal Acquia Cloud , DAM and Cloud Hub Interview questions

  What is Acquia Cloud and how is deployment handled there? Acquia Cloud is a managed Drupal hosting platform built on AWS that provides autoscaling, security, CI/CD pipelines, and monitoring tools like Insight and New Relic. Code deployment is Git-based — we push code to the repository, and Acquia pipelines promote the branch to Dev, Stage, or Prod environments. Production is read-only, ensuring controlled deployments.