geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jdil...@apache.org
Subject cvs commit: incubator-geronimo/modules/core/src/conf boot-service.xml
Date Thu, 28 Aug 2003 11:19:17 GMT
jdillon     2003/08/28 04:19:17

  Modified:    modules/core/src/java/org/apache/geronimo/deployment/scanner
                        DeploymentScanner.java
               modules/core/src/conf boot-service.xml
  Log:
   o Using URLArrayEditor to handle parsing the list of initial urls for the
     DeploymentScanner
  
  Revision  Changes    Path
  1.13      +9 -10     incubator-geronimo/modules/core/src/java/org/apache/geronimo/deployment/scanner/DeploymentScanner.java
  
  Index: DeploymentScanner.java
  ===================================================================
  RCS file: /home/cvs/incubator-geronimo/modules/core/src/java/org/apache/geronimo/deployment/scanner/DeploymentScanner.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- DeploymentScanner.java	24 Aug 2003 22:40:24 -0000	1.12
  +++ DeploymentScanner.java	28 Aug 2003 11:19:17 -0000	1.13
  @@ -57,15 +57,17 @@
   
   import java.io.File;
   import java.io.IOException;
  +
   import java.net.MalformedURLException;
   import java.net.URL;
  +
   import java.util.Collections;
   import java.util.HashMap;
   import java.util.HashSet;
   import java.util.Iterator;
   import java.util.Map;
   import java.util.Set;
  -import java.util.StringTokenizer;
  +
   import javax.management.MBeanServer;
   import javax.management.ObjectName;
   import javax.management.relation.RelationServiceMBean;
  @@ -82,7 +84,6 @@
    * An MBean that maintains a list of URLs and periodically invokes a Scanner
    * to search them for deployments.
    *
  - *
    * @version $Revision$ $Date$
    */
   public class DeploymentScanner extends AbstractManagedObject implements DeploymentScannerMBean
{
  @@ -95,16 +96,14 @@
   
       public DeploymentScanner() {
       }
  -
  -    public DeploymentScanner(String initialURLs, boolean recurse) 
  -        throws MalformedURLException
  +    
  +    public DeploymentScanner(final URL[] urls, final boolean recurse) 
       {
  -        StringTokenizer tokenizer = new StringTokenizer(initialURLs, " \t\r\n,[]{}");
  -        while (tokenizer.hasMoreTokens()) {
  -            addURL(tokenizer.nextToken(), recurse);
  +        for (int i=0; i<urls.length; i++ ) {
  +            addURL(urls[i], recurse);
           }
       }
  -
  +    
       public ObjectName preRegister(MBeanServer server, ObjectName objectName) throws Exception
{
           relationService = JMXUtil.getRelationService(server);
           return super.preRegister(server, objectName);
  
  
  
  1.9       +23 -17    incubator-geronimo/modules/core/src/conf/boot-service.xml
  
  Index: boot-service.xml
  ===================================================================
  RCS file: /home/cvs/incubator-geronimo/modules/core/src/conf/boot-service.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- boot-service.xml	24 Aug 2003 22:40:24 -0000	1.8
  +++ boot-service.xml	28 Aug 2003 11:19:17 -0000	1.9
  @@ -1,20 +1,26 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<components>
  -    <!-- RMI adaptor to support MC4J -->
  -    <mbean code="mx4j.tools.naming.NamingService" name="Naming:type=rmiregistry">
  -    </mbean>
  -    <mbean code="mx4j.adaptor.rmi.jrmp.JRMPAdaptor" name="Adaptor:protocol=JRMP">
  -        <attribute name="JNDIName">jrmp</attribute>
  -    </mbean>
   
  -    <mbean code="org.apache.geronimo.deployment.scanner.DeploymentScanner" name="geronimo.deployment:role=DeploymentScanner">
  -        <constructor>
  -            <arg type="java.lang.String">
  -                ${geronimo.home}/deploy/
  -            </arg>
  -            <arg type="boolean">true</arg>
  -        </constructor>
  -        <attribute name="ScanInterval">5000</attribute>
  -        <relationship type="DeploymentController-DeploymentScanner" name="DeploymentController-DeploymentScanner"
role="DeploymentScanner"/>
  -    </mbean>
  +<!-- $Revision$ $Date$ -->
  +
  +<components>
  +  <!-- RMI adaptor to support MX4J -->
  +  <mbean code="mx4j.tools.naming.NamingService" name="Naming:type=rmiregistry">
  +  </mbean>
  +  <mbean code="mx4j.adaptor.rmi.jrmp.JRMPAdaptor" name="Adaptor:protocol=JRMP">
  +    <attribute name="JNDIName">jrmp</attribute>
  +  </mbean>
  +  
  +  <mbean code="org.apache.geronimo.deployment.scanner.DeploymentScanner"
  +         name="geronimo.deployment:role=DeploymentScanner">
  +    <constructor>
  +      <arg type="[Ljava.net.URL;">
  +        ${geronimo.home}/deploy/
  +      </arg>
  +      <arg type="boolean">true</arg>
  +    </constructor>
  +    <attribute name="ScanInterval">5000</attribute>
  +    <relationship type="DeploymentController-DeploymentScanner"
  +                  name="DeploymentController-DeploymentScanner"
  +                  role="DeploymentScanner"/>
  +  </mbean>
   </components>
  
  
  

Mime
View raw message