Eclipselink多租户:TABLE_PER_TENANT单独架构
<entity class="mypackage.Foo" >
<multitenant type="TABLE_PER_TENANT" >
<tenant-table-discriminator type="SCHEMA" context-property="xxx"/>
</multitenant>
</entity>
出现以下错误:
[EL Warning]: 2014-10-23 21:55:47.406--UnitOfWork(32326774)--Exception [EclipseLink-6168] (Eclipse Persistence Services
- 2.5.1.v20130918-f2b9fc5): org.eclipse.persistence.exceptions.QueryException
Exception Description: Query failed to prepare, unexpected error occurred: [java.lang.NullPointerException].
Internal Exception: java.lang.NullPointerException
Query: ReadAllQuery(referenceClass=Foo )
context-property应该是什么?如何使用?感谢。
答案 0 :(得分:0)
我仍然无法发表评论,因此我将此建议作为答案发送给您。看看我的文章Multi tenancy with EclipseLink and inherited entities。也许你遇到了和我一样的问题。