db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Matthew T. Adams (Created) (JIRA)" <j...@apache.org>
Subject [jira] [Created] (JDO-703) Support datastore multitenancy
Date Fri, 03 Feb 2012 15:05:53 GMT
Support datastore multitenancy

                 Key: JDO-703
                 URL: https://issues.apache.org/jira/browse/JDO-703
             Project: JDO
          Issue Type: New Feature
          Components: api, tck
    Affects Versions: JDO 3 maintenance release 2 (3.2)
            Reporter: Matthew T. Adams

Support database multitenancy as an optional feature (using standard JDO option "javax.jdo.option.Multitenancy"),
where different customers' data can be stored in the same database and the implementation
amends all query filters to include a tenant identifier where instructed by the user via metadata.
 I forsee a minimal need for only two pieces of metadata information:  first, that & where
multitenancy should be used, and second, the multitenancy mapping information.

Multitenancy could be given by the developer at the PMF or PM level, where he specifies a
property, say "javax.jdo.multitenancy.discriminator" or similar, corresponding to new PMF
or PM property multitenantDiscriminator, whose value represents the tenant discriminator.
 Then, queries, loads via id, or dereferences including any entities identified via metadata
as multitenant would automatically include in the underlying datastore query filter a condition
that uses the tenant discriminator to include only those entities that have the given tenant

The entire persistence unit (PMF), persistence context (PM), individual packages, or individual
classes could be identified as multitenant via metadata (a @Multitenant annotation or external
metadata).  Similarly, discriminator mapping information could be defaulted or supplied in
a manner similar to existing mapping metadata.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message