Return-Path: X-Original-To: apmail-db-jdo-dev-archive@www.apache.org Delivered-To: apmail-db-jdo-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2F4949F31 for ; Fri, 3 Feb 2012 15:06:16 +0000 (UTC) Received: (qmail 68674 invoked by uid 500); 3 Feb 2012 15:06:15 -0000 Mailing-List: contact jdo-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: jdo-dev@db.apache.org Delivered-To: mailing list jdo-dev@db.apache.org Received: (qmail 68666 invoked by uid 99); 3 Feb 2012 15:06:14 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 03 Feb 2012 15:06:14 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 03 Feb 2012 15:06:13 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 9A8AF18BADB for ; Fri, 3 Feb 2012 15:05:53 +0000 (UTC) Date: Fri, 3 Feb 2012 15:05:53 +0000 (UTC) From: "Matthew T. Adams (Created) (JIRA)" To: jdo-dev@db.apache.org Message-ID: <607932587.7576.1328281553634.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Created] (JDO-703) Support datastore multitenancy MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 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 discriminator. 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