Return-Path: Delivered-To: apmail-geronimo-dev-archive@www.apache.org Received: (qmail 62389 invoked from network); 2 Oct 2006 17:00:15 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 2 Oct 2006 17:00:15 -0000 Received: (qmail 52586 invoked by uid 500); 2 Oct 2006 17:00:11 -0000 Delivered-To: apmail-geronimo-dev-archive@geronimo.apache.org Received: (qmail 52540 invoked by uid 500); 2 Oct 2006 17:00:11 -0000 Mailing-List: contact dev-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@geronimo.apache.org List-Id: Delivered-To: mailing list dev@geronimo.apache.org Received: (qmail 52529 invoked by uid 99); 2 Oct 2006 17:00:11 -0000 Received: from idunn.apache.osuosl.org (HELO idunn.apache.osuosl.org) (140.211.166.84) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 Oct 2006 10:00:11 -0700 X-ASF-Spam-Status: No, hits=0.0 required=5.0 tests= Received: from [208.42.156.2] ([208.42.156.2:40611] helo=conn.mc.mpls.visi.com) by idunn.apache.osuosl.org (ecelerity 2.1.1.8 r(12930)) with ESMTP id F2/91-24395-99541254 for ; Mon, 02 Oct 2006 10:00:10 -0700 Received: from [192.168.42.22] (68-171-58-68.vnnyca.adelphia.net [68.171.58.68]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (No client certificate requested) by conn.mc.mpls.visi.com (Postfix) with ESMTP id A1B0D827D; Mon, 2 Oct 2006 12:00:05 -0500 (CDT) In-Reply-To: <75194C6D-F1D6-45A4-B4F4-9FD4FBEBDA21@yahoo.com> References: <75194C6D-F1D6-45A4-B4F4-9FD4FBEBDA21@yahoo.com> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <7B5C0783-CFCA-4E0A-A2F4-A73640A1456C@visi.com> Cc: "Geronimo Dev List (JIRA)" Content-Transfer-Encoding: 7bit From: David Blevins Subject: Re: Binding into global (and other) jndi Date: Mon, 2 Oct 2006 10:00:01 -0700 To: openejb-dev@incubator.apache.org X-Mailer: Apple Mail (2.752.2) X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N On Oct 1, 2006, at 11:16 AM, David Jencks wrote: > Dain has been working on a global jndi implementation that looks > really nice. However the deployment of bindings part of it has > brought up some long-festering architectural worries and perhaps we > are now in a position to deal with them in a systematic manner. > > David Blevins pointed out to me a long time ago that one of the > core principles of openejb was that ejb containers should have > nothing transport specific attached to them. This was when I > installed a TSSBean reference in ejb containers to enable binding > ejbs into corba. I pointed out that letting the ejb container know > jndi-names and local-jndi-names had the same problem, and IIRC he > agreed that this was an architectural flaw. In any case, > intentionally or not, he convinced me that both the tssbean link > and the jndi names should not be attached to the ejb container. If > you install dain's global jndi stuff the jndi names now get > recycled up to 3 times: for the openejb proprietary jndi impl, > global jndi, and corba. The global jndi connector binding creates > a similar but worse problem for j2ca connectors, since it tries to > bind using only the "name" component of the abstract name, rather > than allowing a specific global jndi name, and AFAICT it doesn't > let you specify which connectors you want to bind. > > I think for all of these situations a cleaner runtime solution is a > component that links the thing you want to bind and the binding > context, and includes the name(s) you want to bind under. > Currently this would I think have to be a gbean. This is what Dain > implemented for gbean bindings. So, I'm proposing that bindings > for connectors in global jndi, and ejbs in global jndi, corba, and > the openejb jndi, each be set up by gbeans, each holding the name > (s) to bind under and a reference to the object to be bound. This > part is pretty easy to write. > > Slightly harder is deployment: setting up these gbeans. If we > modify our schemas this can be done using NamingBuilders: here they > won't be constructing the components jndi context but rather > exposing the component in various naming systems. I think the > really hard part is figuring out some xml that is manageable to > write and expresses the meaning clearly. > > For connectors it's pretty easy, we can just have a repeating element > foo > > For ejbs with the current 3 naming systems it's a bit harder. One > possibility would look something like this: > > > > > foo-tss > > > foo > bar > > > where the global, corba, and openejb elements indicate which naming > system to bind to and the names are supplied with remote-name and > local-name. A remote jndi would ignore the local-name elements. > You could have multiple jndi elements to get different bindings in > different naming systems. > > To make this extensible the naming system elements would have to be > in a substitution group and extend an abstract element. The ones > we know about now could all be in the same namespace. > > > Thoughts? There was a discussion on this in context of OpenEJB 3. It was short and no real conclusion was made, but let me see if I can't dig it up. -David > > thanks > david jencks >