Return-Path: X-Original-To: apmail-openjpa-users-archive@minotaur.apache.org Delivered-To: apmail-openjpa-users-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 0D5CF17D4A for ; Mon, 29 Sep 2014 13:16:20 +0000 (UTC) Received: (qmail 59864 invoked by uid 500); 29 Sep 2014 13:16:19 -0000 Delivered-To: apmail-openjpa-users-archive@openjpa.apache.org Received: (qmail 59816 invoked by uid 500); 29 Sep 2014 13:16:19 -0000 Mailing-List: contact users-help@openjpa.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@openjpa.apache.org Delivered-To: mailing list users@openjpa.apache.org Received: (qmail 59803 invoked by uid 99); 29 Sep 2014 13:16:19 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 29 Sep 2014 13:16:19 +0000 X-ASF-Spam-Status: No, hits=1.7 required=5.0 tests=FREEMAIL_ENVFROM_END_DIGIT,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of curtisr7@gmail.com designates 209.85.218.46 as permitted sender) Received: from [209.85.218.46] (HELO mail-oi0-f46.google.com) (209.85.218.46) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 29 Sep 2014 13:15:53 +0000 Received: by mail-oi0-f46.google.com with SMTP id h136so2055129oig.5 for ; Mon, 29 Sep 2014 06:15:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=VxSblA+tYh9a8ogk9EYXgPvKJCzWr+xoCaugDGpXZ6o=; b=ABW4tbRbQG+NYeYq2T/EpvWYReM4NDrQP+9ZGfdBol/EHkPc+yqiBbUgsewNN4bURi GQimfdMaP8GBu3BuY9U4y28LkPVVBku4rAL/nMzXGzy8iMB3U8GhpZJXKG/4+/bY3Yeo AYRG0u2FJQMA9m9Q/f0lbX6lCJ13iGNhf3uxdN+RzNhHHLk9P4MeG2vR6tYXrIz9ykWd Vpt3wX4cyJ1jz3aLe23MzAyiTeukEx37WZQh2lZNA/CvYZ8ixIKJaLVDLQVfAXMiakxx DDenWd6EaC0Yx6g4QIs97mh2gNtN0gW1wzUMU/tWDOqTSn/vhk+U9AIWsSWw8rSFI6tf +ZsQ== MIME-Version: 1.0 X-Received: by 10.60.35.6 with SMTP id d6mr2109356oej.77.1411996551747; Mon, 29 Sep 2014 06:15:51 -0700 (PDT) Received: by 10.60.52.46 with HTTP; Mon, 29 Sep 2014 06:15:51 -0700 (PDT) In-Reply-To: References: Date: Mon, 29 Sep 2014 08:15:51 -0500 Message-ID: Subject: Re: exclude-unlisted-classes ignored From: Rick Curtis To: users Content-Type: multipart/alternative; boundary=089e01228b1ae41e860504341056 X-Virus-Checked: Checked by ClamAV on apache.org --089e01228b1ae41e860504341056 Content-Type: text/plain; charset=ISO-8859-1 It sounds like this is working as expected. Excerpt from the spec : When set to true then only listed classes and jars will be scanned for persistent classes, otherwise the enclosing jar or directory will also be scanned. Not applicable to Java SE persistence units. On Fri, Sep 26, 2014 at 11:08 PM, Mansour Al Akeel < mansour.alakeel@gmail.com> wrote: > When creating EntityManagerFactory using OpenEJB, > exclude-unlisted-classes works as expected. However, when creating it > directly as in: > > > props.setProperty("javax.persistence.jdbc.driver", this.driver); > props.setProperty("javax.persistence.jdbc.url", this.url); > props.setProperty("javax.persistence.jdbc.user", this.username); > props.setProperty("javax.persistence.jdbc.password", this.password); > > props.setProperty("javax.persistence.transactionType", > PersistenceUnitTransactionType.RESOURCE_LOCAL.name()); > > EntityManagerFactory emf = > Persistence.createEntityManagerFactory(null, props); > > > The classes are not scanned. The only classes that are loaded and > created tables into the DB are those listed in the persistence.xml > > I noticed that openejb and openjpa has their own implementation of > PersistenceUnitInfoImpl. > > I just need to confirm if this is a bug, or I am missing something. > > > Thank you. > -- *Rick Curtis* --089e01228b1ae41e860504341056--