Use the Multitenancy area in the JPA Details view to specify that a given entity is shared among multiple tenants of an application.
Property | Description | Default | Available for Entity Type |
---|---|---|---|
Multitenancy strategy |
Specify the multitenant strategy to use:
|
Single table |
|
Include criteria |
Specify if the database requires the tenant criteria to be added to the |
True |
|
Tenant descriptor columns |
Use to limit what a persistence context can access in single-table mulitenancy |
||
Override default |
|||
Name |
The name of column to be used for the tenant discriminator. |
eclipselink.tenant-id |
|
Table |
The name of the table that contains the column. |
||
Context property |
The name of the context property to apply to the tenant discriminator column. |
||
Discriminator type |
The type of object/column to use as a class discriminator:
|
String |
|
Length |
The column length for String-based discriminator types. |
||
Column definition |
The SQL fragment that is used when generating the DDL for the discriminator column. |
||
Primary key |
Specifies that the tenant discriminator column is part of the primary key of the tables. |
False |
Related reference
"Multitenant" in Java Persistence API (JPA) Extensions Reference for EclipseLink
http://www.eclipse.org/eclipselink/documentation/2.4/jpa/extensions/a_multitenant.htm