[hibernate-dev] Multi-tenant roadmap

Steve Ebersole steve at hibernate.org
Mon Jun 20 19:25:29 EDT 2011


http://opensource.atlassian.com/projects/hibernate/browse/HHH-6336


On 06/20/2011 09:29 AM, Donnchadh Ó Donnabháin wrote:
> +1 for a CurrentTenantIdentifierResolver contract registered with the
> SessionFactory.
> This seems like a reasonably flexible approach.
>
>    Donnchadh
>
>
> On 20 June 2011 15:06, Steve Ebersole<steve at hibernate.org>  wrote:
>> If this were the direction, I'd rather suggest a
>> "CurrentTenantIdentifierResolver" contract registered with the
>> SessionFactory.
>>
>> Just brainstorming... this might also be usable from ConnectionProvider
>> and eliminate the need for
>> org.hibernate.service.jdbc.connections.spi.MultiTenantConnectionProvider
>>
> ...
>>>>
>>>> Not sure I much like overloading for getCurrentSession(String
>>>> tenantIdentifier)
>>>
>>> Doesn't make sense to me either. How about tenantId set on a
>>> ThreadLocal. That could work for JTASessionContext as well.
>>>
> _______________________________________________
> hibernate-dev mailing list
> hibernate-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/hibernate-dev

-- 
Steve Ebersole <steve at hibernate.org>
http://hibernate.org



More information about the hibernate-dev mailing list