[hibernate-dev] Multi-Tenancy and "shared" data

John Verhaeg jverhaeg at redhat.com
Tue May 15 13:23:26 EDT 2012


I'd agree.  It would seem strange to assume the lack of inheritance in this case and have to annotate multi-tenancy throughout the chain of associations.

On May 15, 2012, at 12:04 PM, Steve Ebersole wrote:

> Multi-tenant setups sometimes have data that is shared between the 
> tenants (codec tables, etc).
> 
> I think the first question is do we want to support this mixing?  I 
> think it is common enough that it is worthwhile to support it.  And I do 
> not think it is complicated enough to be painful to implement.  As long 
> as we assume that there is some form of database-level availability 
> between shared, non-shared data (even for the DATABASE and SCHEMA 
> strategies) I think we will be fine.
> 
> Assuming we do support it, there is a decision we need to make about how 
> we differentiate shared (tenant aware) and non-shared (non-tenant aware) 
> data, especially important when we talk about the DISCRIMINATOR approach 
> which touches on a more general outstanding decision with regard to 
> supporting DISCRIMINATOR multi-tenancy.  Basically whether entities are 
> inclusively considered multi-tenant when the user has specified 
> DISCRIMINATOR, or whether we expect some form of annotation stating the 
> entity is multi-tenant.  Personally, I think the inclusive approach (all 
> entities are assumed multi-tenant) is probably the better approach.  In 
> which case we need an annotation to say "this entity is not multi-tenant".
> 
> 
> -- 
> steve at hibernate.org
> http://hibernate.org
> _______________________________________________
> hibernate-dev mailing list
> hibernate-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/hibernate-dev

JPAV







More information about the hibernate-dev mailing list