How are bundles related to the configuration entity?

How are bundles related to the configuration entity?

Bundles are a special variant of the Configuration Entity. They are Configuration Entities that enhance a content entity by providing mechanisms for having different Content Entity “Types”. A bundle configuration entity stores the different configurations for the various Content Entities, such as settings and custom fields.

Which is an example of a bundle entity in Drupal?

A bundle configuration entity stores the different configurations for the various Content Entities, such as settings and custom fields. The most notable example of Bundles in Drupal are Node Types (aka, Content Types).

Which is an example of an entity type?

Bundles are different variants of an entity type. For example, with the node entity type, the bundles are the different node types, such as ‘article’ and ‘page’. Typically, a bundle is represented by a Configuration Entity, though other models exist in contrib modules.

How to create a custom content entity in Drupal?

These various type-names can be used to group entity instances (think of Views filtering), or to support different data-storage uses of the entities. In Drupal, an entity that supports sub-types in this way does so by using ” bundles “, and to add bundles to an Entity, we need to do the following things:


With content nodes (an entity type), for example, you can generate bundles (subtypes) like articles, blog posts, or products. Not all entity types have bundles, however. For example, users do not have separate bundles (subtypes). For the entity types that do allow bundles, you can create as many bundles (subtypes) as you want.

How to configure a relationship from an entity type?

Configures a required relationship from this entity type. Instances of the entity type will not be able to be saved to the database unless this relationship is specified. The foreign key in the database will be non-nullable.

How is a student table an entity type?

So, we can define the above STUDENT table as an entity type because it is a collection of entities having the same attributes. So, an entity type in an ER diagram is defined by a name (here, STUDENT) and a set of attributes (here, Roll_no, Student_name, Age, Mobile_no).