Return-Path: Delivered-To: apmail-geronimo-dev-archive@www.apache.org Received: (qmail 44135 invoked from network); 14 Feb 2007 06:17:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 14 Feb 2007 06:17:16 -0000 Received: (qmail 35282 invoked by uid 500); 14 Feb 2007 06:17:22 -0000 Delivered-To: apmail-geronimo-dev-archive@geronimo.apache.org Received: (qmail 35233 invoked by uid 500); 14 Feb 2007 06:17:22 -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 35221 invoked by uid 99); 14 Feb 2007 06:17:22 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 13 Feb 2007 22:17:22 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of jason.dillon@gmail.com designates 64.233.166.178 as permitted sender) Received: from [64.233.166.178] (HELO py-out-1112.google.com) (64.233.166.178) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 13 Feb 2007 22:17:11 -0800 Received: by py-out-1112.google.com with SMTP id f47so47036pye for ; Tue, 13 Feb 2007 22:16:50 -0800 (PST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:mime-version:in-reply-to:references:content-type:message-id:content-transfer-encoding:from:subject:date:to:x-mailer:sender; b=ouL+DKi0yf+Dx4a5O6mc+y5eTBeNAcBhHKA2AF+o9UI3V3AvQoJ3idKodRA2w4mZZ4gtlqCeiRq8WGkCxeIodAP7ubNu117HjbLmYaYGQBwX4D8nQfH68SNYQTk9VVU0epRcNrvTrWQJg6BcFQtdYnMpRUolHmE2ulz/4xFGy3A= Received: by 10.35.89.10 with SMTP id r10mr18040959pyl.1171433810314; Tue, 13 Feb 2007 22:16:50 -0800 (PST) Received: from ?10.0.1.2? ( [24.7.69.241]) by mx.google.com with ESMTP id n27sm501551pyh.2007.02.13.22.16.48; Tue, 13 Feb 2007 22:16:49 -0800 (PST) Mime-Version: 1.0 (Apple Message framework v752.3) In-Reply-To: References: <20070214003423.1775D1A981A@eris.apache.org> <6D4116DE-2DC1-4F94-81C3-C768DA65DF1A@planet57.com> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <92CA441E-7DC2-45F2-8F91-75853396357D@planet57.com> Content-Transfer-Encoding: 7bit From: Jason Dillon Subject: Re: svn commit: r507336 - in /geronimo/server/trunk/modules/geronimo-yoko: pom.xml src/main/java/org/apache/geronimo/yoko/ORBConfigAdapter.java Date: Tue, 13 Feb 2007 22:16:50 -0800 To: dev@geronimo.apache.org X-Mailer: Apple Mail (2.752.3) Sender: Jason Dillon X-Virus-Checked: Checked by ClamAV on apache.org Its probably fine, though if moving the bits in the top-level pom to PM and adding extra config in children modules where needed works, then that is probably better, so there is less config to keep in sync. --jason On Feb 13, 2007, at 5:48 PM, David Jencks wrote: > I took the route of least resistance.... I'll see how much I can > leave out here. > > thanks > david jencks > > On Feb 13, 2007, at 4:43 PM, Jason Dillon wrote: > >> Does source/target not get picked up from the top-level pom when >> adding compilerArguments? >> >> We may need to put the top-level bits into a PM, so those common >> config params are propagated to children... assuming that works :-\ >> >> --jason >> >> >> On Feb 13, 2007, at 4:34 PM, djencks@apache.org wrote: >> >>> Author: djencks >>> Date: Tue Feb 13 16:34:22 2007 >>> New Revision: 507336 >>> >>> URL: http://svn.apache.org/viewvc?view=rev&rev=507336 >>> Log: >>> GERONIMO-2382 work harder to get our UtilDelegateImpl >>> registered. Also a little code cleanup >>> >>> Modified: >>> geronimo/server/trunk/modules/geronimo-yoko/pom.xml >>> geronimo/server/trunk/modules/geronimo-yoko/src/main/java/org/ >>> apache/geronimo/yoko/ORBConfigAdapter.java >>> >>> Modified: geronimo/server/trunk/modules/geronimo-yoko/pom.xml >>> URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/ >>> geronimo-yoko/pom.xml?view=diff&rev=507336&r1=507335&r2=507336 >>> ==================================================================== >>> ========== >>> --- geronimo/server/trunk/modules/geronimo-yoko/pom.xml (original) >>> +++ geronimo/server/trunk/modules/geronimo-yoko/pom.xml Tue Feb >>> 13 16:34:22 2007 >>> @@ -144,8 +144,8 @@ >>> >>> maven-compiler-plugin >>> >>> - 1.4 >>> - 1.4 >>> + 1.5 >>> + 1.5 >>> >>> ${project.build.directory}/ >>> endorsed >>> >>> >>> Modified: geronimo/server/trunk/modules/geronimo-yoko/src/main/ >>> java/org/apache/geronimo/yoko/ORBConfigAdapter.java >>> URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/ >>> geronimo-yoko/src/main/java/org/apache/geronimo/yoko/ >>> ORBConfigAdapter.java?view=diff&rev=507336&r1=507335&r2=507336 >>> ==================================================================== >>> ========== >>> --- geronimo/server/trunk/modules/geronimo-yoko/src/main/java/org/ >>> apache/geronimo/yoko/ORBConfigAdapter.java (original) >>> +++ geronimo/server/trunk/modules/geronimo-yoko/src/main/java/org/ >>> apache/geronimo/yoko/ORBConfigAdapter.java Tue Feb 13 16:34:22 2007 >>> @@ -16,19 +16,15 @@ >>> */ >>> package org.apache.geronimo.yoko; >>> >>> +import java.lang.reflect.Method; >>> import java.util.ArrayList; >>> import java.util.Enumeration; >>> import java.util.HashMap; >>> -import java.util.Iterator; >>> import java.util.List; >>> import java.util.Properties; >>> >>> import org.apache.commons.logging.Log; >>> import org.apache.commons.logging.LogFactory; >>> -import org.apache.geronimo.gbean.GBeanLifecycle; >>> -import org.apache.geronimo.security.deploy.DefaultDomainPrincipal; >>> -import org.apache.geronimo.security.deploy.DefaultPrincipal; >>> -import org.apache.geronimo.security.deploy.DefaultRealmPrincipal; >>> import org.apache.geronimo.corba.CORBABean; >>> import org.apache.geronimo.corba.CSSBean; >>> import org.apache.geronimo.corba.NameService; >>> @@ -38,9 +34,13 @@ >>> import org.apache.geronimo.corba.security.config.tss.TSSConfig; >>> import >>> org.apache.geronimo.corba.security.config.tss.TSSSSLTransportConfig; >>> import >>> org.apache.geronimo.corba.security.config.tss.TSSTransportMechConfig >>> ; >>> +import org.apache.geronimo.gbean.GBeanLifecycle; >>> +import org.apache.geronimo.security.deploy.DefaultDomainPrincipal; >>> +import org.apache.geronimo.security.deploy.DefaultPrincipal; >>> +import org.apache.geronimo.security.deploy.DefaultRealmPrincipal; >>> import org.apache.yoko.orb.CosNaming.tnaming.TransientNameService; >>> import >>> org.apache.yoko.orb.CosNaming.tnaming.TransientServiceException; >>> -import org.apache.yoko.orb.OB.ZERO_PORT_POLICY_ID; >>> +import org.apache.yoko.orb.OB.ZERO_PORT_POLICY_ID; >>> import org.omg.CORBA.Any; >>> import org.omg.CORBA.ORB; >>> import org.omg.CORBA.Policy; >>> @@ -88,7 +88,10 @@ >>> >>> // ok, now we have a potential classloading problem >>> because of where our util delegates are located. >>> // by forcing these classes to load now using our class >>> loader, we can ensure things are properly initialized >>> - this.getClass().getClassLoader().loadClass >>> ("javax.rmi.PortableRemoteObject"); >>> + Class clazz = this.getClass().getClassLoader().loadClass >>> ("javax.rmi.PortableRemoteObject"); >>> + Method m = clazz.getMethod("narrow", Object.class, >>> Class.class); >>> + m.invoke(null, new Object(), Object.class); >>> + >>> >>> log.debug("Started Yoko ORBConfigAdapter"); >>> } >>> @@ -112,7 +115,7 @@ >>> * @exception ConfigException >>> */ >>> public ORB createServerORB(CORBABean server) throws >>> ConfigException { >>> - ORB orb = createORB(server.getURI(), (ORBConfiguration) >>> server, translateToArgs(server), translateToProps(server)); >>> + ORB orb = createORB(server.getURI(), server, >>> translateToArgs(server), translateToProps(server)); >>> >>> // check the tss config for a transport mech >>> definition. If we have one, then >>> // the port information will be passed in that config, >>> and the port in the IIOP profile >>> @@ -147,7 +150,7 @@ >>> * @exception ConfigException >>> */ >>> public ORB createClientORB(CSSBean client) throws >>> ConfigException { >>> - return createORB(client.getURI(), (ORBConfiguration) >>> client, translateToArgs(client), translateToProps(client)); >>> + return createORB(client.getURI(), client, translateToArgs >>> (client), translateToProps(client)); >>> } >>> >>> /** >>> @@ -159,7 +162,7 @@ >>> * @exception ConfigException >>> */ >>> public ORB createNameServiceClientORB(CSSBean client) >>> throws ConfigException { >>> - return createORB(client.getURI(), (ORBConfiguration) >>> client, translateToArgs(client), translateToNameServiceProps >>> (client)); >>> + return createORB(client.getURI(), client, translateToArgs >>> (client), translateToNameServiceProps(client)); >>> } >>> >>> /** >>> @@ -248,10 +251,10 @@ >>> * >>> * @return A String{} array containing the initialization >>> * arguments. >>> - * @exception ConfigException >>> + * @exception ConfigException if configuration cannot be >>> interpreted >>> */ >>> private String[] translateToArgs(CORBABean server) throws >>> ConfigException { >>> - ArrayList list = new ArrayList(); >>> + ArrayList list = new ArrayList(); >>> >>> TSSConfig config = server.getTssConfig(); >>> >>> @@ -283,12 +286,12 @@ >>> } >>> >>> if (log.isDebugEnabled()) { >>> - for (Iterator iter = list.iterator(); iter.hasNext >>> ();) { >>> - log.debug(iter.next()); >>> + for (String configArg : list) { >>> + log.debug(configArg); >>> } >>> } >>> >>> - return (String[]) list.toArray(new String[list.size()]); >>> + return list.toArray(new String[list.size()]); >>> } >>> >>> private Properties translateToProps(CORBABean server) throws >>> ConfigException { >>> @@ -336,21 +339,21 @@ >>> * @param client The CSSBean holding the configuration. >>> * >>> * @return A String array to be passed to ORB.init(). >>> - * @exception ConfigException >>> + * @exception ConfigException if configuration cannot be >>> interpreted >>> */ >>> private String[] translateToArgs(CSSBean client) throws >>> ConfigException { >>> - ArrayList list = new ArrayList(); >>> + ArrayList list = new ArrayList(); >>> >>> // enable the connection plugin >>> enableSocketFactory(client.getURI(), list); >>> >>> if (log.isDebugEnabled()) { >>> - for (Iterator iter = list.iterator(); iter.hasNext >>> ();) { >>> - log.debug(iter.next()); >>> + for (String configArg : list) { >>> + log.debug(configArg); >>> } >>> } >>> >>> - return (String[]) list.toArray(new String[list.size()]); >>> + return list.toArray(new String[list.size()]); >>> } >>> >>> /** >>> @@ -360,9 +363,9 @@ >>> * >>> * @param uri The URI name of the configuration GBean >>> (either a >>> * CSSBean or a CORBABean). >>> - * @param args >>> + * @param args configuration arguments to add to >>> */ >>> - private void enableSocketFactory(String uri, List args) { >>> + private void enableSocketFactory(String uri, List >>> args) { >>> args.add("-IIOPconnectionHelper"); >>> args.add("org.apache.geronimo.yoko.SocketFactory"); >>> args.add("-IIOPconnectionHelperArgs"); >>> @@ -378,7 +381,7 @@ >>> * @param client The CSSBean holding the configuration. >>> * >>> * @return A property bundle that can be passed to ORB.init(); >>> - * @exception ConfigException >>> + * @exception ConfigException if configuration cannot be >>> interpreted >>> */ >>> private Properties translateToProps(CSSBean client) throws >>> ConfigException { >>> Properties result = new Properties(); >>> @@ -408,7 +411,7 @@ >>> * @param client The CSSBean holding the configuration. >>> * >>> * @return A property bundle that can be passed to ORB.init(); >>> - * @exception ConfigException >>> + * @exception ConfigException if configuration cannot be >>> interpreted >>> */ >>> private Properties translateToNameServiceProps(CSSBean >>> client) throws ConfigException { >>> Properties result = new Properties(); >>> >>> >> >