版权声明:本文为博主汪子熙原创文章,未经博主允许不得转载。 https://cloud.tencent.com/developer/article/1439842
http://stackoverflow.com/questions/20128166/what-is-tenant-scope-in-hybris
The core-spring.xml file of the core extension adds a special scope named tenant to the global ApplicationContext. The tenant scope makes sure that the bean is instantiated individually for each individual tenant of the hybris, whereas singleton would create only one instance for all tenants to use.
If you reference tenant-specific classes like services or DAOs inside your implementation, you have to use the tenant scope instead of the default Spring singleton scope. In case of doubt, use tenant instead of singleton.
It is useful when you want to host your online shops for several individual customers on one hybris Multichannel Suite. In Multi-tenancy, each customer is called a tenant. According to their requirement they can customize your shops.