Title: [776] branches/servicemix-2.0/trunk: Fix classpath problems on linux/mac

Diff

Modified: branches/servicemix-2.0/trunk/assembly/project.xml (775 => 776)

--- branches/servicemix-2.0/trunk/assembly/project.xml	2005-11-10 00:45:16 UTC (rev 775)
+++ branches/servicemix-2.0/trunk/assembly/project.xml	2005-11-10 01:11:56 UTC (rev 776)
@@ -485,6 +485,14 @@
       </properties>
     </dependency>
     <dependency>
+      <groupId>axis</groupId>
+      <artifactId>axis-jaxrpc</artifactId>
+      <version>${axis_version}</version>
+      <properties>
+        <optional>true</optional>
+      </properties>
+    </dependency>
+    <dependency>
       <id>commons-httpclient</id>
       <version>${commons_httpclient_version}</version>
       <properties>
@@ -726,6 +734,14 @@
         <optional>true</optional>
       </properties>
     </dependency>
+    <dependency>
+      <groupId>xml-apis</groupId>
+      <artifactId>xml-apis</artifactId>
+      <version>${xml_apis_version}</version>
+      <properties>
+        <optional>true</optional>
+      </properties>
+    </dependency>
   </dependencies>
 
 </project>

Modified: branches/servicemix-2.0/trunk/assembly/src/release/bin/servicemix (775 => 776)

--- branches/servicemix-2.0/trunk/assembly/src/release/bin/servicemix	2005-11-10 00:45:16 UTC (rev 775)
+++ branches/servicemix-2.0/trunk/assembly/src/release/bin/servicemix	2005-11-10 01:11:56 UTC (rev 776)
@@ -121,7 +121,7 @@
     if [ -z "$LOCALCLASSPATH" ] ; then
       LOCALCLASSPATH="$i"
     else
-      LOCALCLASSPATH="$i":"$LOCALCLASSPATH"
+      LOCALCLASSPATH="$LOCALCLASSPATH":"$i"
     fi
   fi
 done
@@ -135,7 +135,7 @@
     if [ -z "$LOCALCLASSPATH" ] ; then
       LOCALCLASSPATH="$i"
     else
-      LOCALCLASSPATH="$i":"$LOCALCLASSPATH"
+      LOCALCLASSPATH="$LOCALCLASSPATH":"$i"
     fi
   fi
 done
@@ -149,7 +149,7 @@
     if [ -z "$LOCALCLASSPATH" ] ; then
       LOCALCLASSPATH="$i"
     else
-      LOCALCLASSPATH="$i":"$LOCALCLASSPATH"
+      LOCALCLASSPATH="$LOCALCLASSPATH":"$i"
     fi
   fi
 done

Modified: branches/servicemix-2.0/trunk/core/src/main/java/org/servicemix/jbi/config/XmlWebApplicationContext.java (775 => 776)

--- branches/servicemix-2.0/trunk/core/src/main/java/org/servicemix/jbi/config/XmlWebApplicationContext.java	2005-11-10 00:45:16 UTC (rev 775)
+++ branches/servicemix-2.0/trunk/core/src/main/java/org/servicemix/jbi/config/XmlWebApplicationContext.java	2005-11-10 01:11:56 UTC (rev 776)
@@ -17,32 +17,16 @@
  **/
 package org.servicemix.jbi.config;
 
-import org.springframework.beans.factory.support.DefaultListableBeanFactory;
-import org.springframework.beans.factory.xml.ResourceEntityResolver;
-import org.springframework.beans.factory.xml.XmlBeanDefinitionReader;
+import java.util.Arrays;
+import org.servicemix.jbi.config.spring.XBeanProcessor;
 
-import java.io.IOException;
-
 /**
- * A modified version of the Spring class which supports ApplicationContext without validation.
- * 
- * @version $Revision$
- */
-public class XmlWebApplicationContext extends org.springframework.web.context.support.XmlWebApplicationContext {
+ * Application context for ServiceMix 1.x xml syntax compatibility
+ */ 
+public class XmlWebApplicationContext
+    extends org.xbean.spring.context.XmlWebApplicationContext {
 
-    /**
-     * Loads the bean definitions via an XmlBeanDefinitionReader.
-     * 
-     * @see org.springframework.beans.factory.xml.XmlBeanDefinitionReader
-     * @see #initBeanDefinitionReader
-     * @see #loadBeanDefinitions
-     */
-    protected void loadBeanDefinitions(DefaultListableBeanFactory beanFactory) throws IOException {
-        XmlBeanDefinitionReader beanDefinitionReader = new XmlBeanDefinitionReader(beanFactory);
-        beanDefinitionReader.setEntityResolver(new ResourceEntityResolver(this));
-        beanDefinitionReader.setValidating(false);
-        initBeanDefinitionReader(beanDefinitionReader);
-        loadBeanDefinitions(beanDefinitionReader);
-    }
-
+  public XmlWebApplicationContext() {
+    super(Arrays.asList(new Object[] {new XBeanProcessor()}));
+  }
 }

Modified: branches/servicemix-2.0/trunk/etc/project.properties (775 => 776)

--- branches/servicemix-2.0/trunk/etc/project.properties	2005-11-10 00:45:16 UTC (rev 775)
+++ branches/servicemix-2.0/trunk/etc/project.properties	2005-11-10 01:11:56 UTC (rev 776)
@@ -148,8 +148,8 @@
 maven_itest_plugin_version=1.0
 mina_version=0.7.3
 mule_version=1.0
-mx4j_version=3.0.1
-mx4j_remote_version=3.0.1
+mx4j_version=2.1.1
+mx4j_remote_version=2.1.1
 mx4j_tools_version=2.1.1
 openejb_core_version=2.0-SNAPSHOT
 org.mortbay.jetty_version=4.2.20RC0

Modified: branches/servicemix-2.0/trunk/etc/project.xml (775 => 776)

--- branches/servicemix-2.0/trunk/etc/project.xml	2005-11-10 00:45:16 UTC (rev 775)
+++ branches/servicemix-2.0/trunk/etc/project.xml	2005-11-10 01:11:56 UTC (rev 776)
@@ -5,7 +5,7 @@
   <name>ServiceMix</name>
   <id>servicemix</id>
   <groupId>servicemix</groupId>
-  <currentVersion>2.0.1</currentVersion>
+  <currentVersion>2.0.2-SNAPSHOT</currentVersion>
 
   <organization>
     <name>LogicBlaze, Inc.</name>

Modified: branches/servicemix-2.0/trunk/project.xml (775 => 776)

--- branches/servicemix-2.0/trunk/project.xml	2005-11-10 00:45:16 UTC (rev 775)
+++ branches/servicemix-2.0/trunk/project.xml	2005-11-10 01:11:56 UTC (rev 776)
@@ -2,271 +2,8 @@
 
 <project>
   <pomVersion>3</pomVersion>
-  <name>ServiceMix</name>
+  <extend>${basedir}/etc/project.xml</extend>
+
   <id>servicemix</id>
   <groupId>servicemix</groupId>
-  <currentVersion>2.0.1</currentVersion>
-
-  <organization>
-    <name>LogicBlaze, Inc.</name>
-    <url>http://logicblaze.com</url>
-    <logo>http://logicblaze.com/images/logo.jpg</logo>
-  </organization>
-
-  <inceptionYear>2005</inceptionYear>
-
-  <package>org.servicemix</package>
-  <packageGroups>
-    <packageGroup>
-      <title>ServiceMix Core APIs</title>
-      <packages>org.servicemix</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>JBI Client API</title>
-      <packages>org.servicemix.client</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>JBI Components</title>
-      <packages>org.servicemix.components.*</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>JBI Container</title>
-      <packages>org.servicemix.jbi.container</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>Normalized Message Router</title>
-      <packages>org.servicemix.jbi.nmr</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>Message Router Dispatching</title>
-      <packages>org.servicemix.jbi.nmr.flow.*</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>Normalized Message Service implementation</title>
-      <packages>org.servicemix.jbi.messaging</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>Endpoint resolving and choosing strategies</title>
-      <packages>org.servicemix.jbi.resolver</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>JAXP utilities</title>
-      <packages>org.servicemix.jbi.jaxp</packages>
-    </packageGroup>
-    <packageGroup>
-      <title>JBI Container implementation</title>
-      <packages>org.servicemix.jbi:org.servicemix.jbi.*</packages>
-    </packageGroup>
-  </packageGroups>
-
-  <shortDescription>ServiceMix is an open source ESB</shortDescription>
-
-  <gumpRepositoryId>servicemix</gumpRepositoryId>
-
-  <description>
-    ServiceMix is an open source ESB based on the Java Business
-    Integration framework - JSR-208
-  </description>
-
-  <url>http://www.servicemix.org/</url>
-  <issueTrackingUrl>http://jira.logicblaze.com/browse/SM</issueTrackingUrl>
-
-  <siteAddress>beaver.codehaus.org</siteAddress>
-  <siteDirectory>/home/projects/servicemix/public_html/maven</siteDirectory>
-  <distributionDirectory>/home/projects/servicemix/dist</distributionDirectory>
-
-  <repository>
-    <connection>scm:svn:svn://svn.servicemix.org/servicemix/scm/trunk/</connection>
-    <developerConnection>scm:svn:svn+ssh://svn.servicemix.org/servicemix/scm/servicemix/trunk</developerConnection>
-    <url>http://svn.servicemix.codehaus.org/trunk/</url>
-  </repository>
-
-  <mailingLists>
-    <mailingList>
-      <name>ServiceMix Developer List</name>
-      <subscribe>[EMAIL PROTECTED]</subscribe>
-      <unsubscribe>[EMAIL PROTECTED]</unsubscribe>
-      <!--
-      <archive>http://archive.servicemix.codehaus.org/dev/</archive>
-      -->
-      <archive>http://dir.gmane.org/gmane.comp.java.servicemix.devel</archive>
-    </mailingList>
-    <mailingList>
-      <name>ServiceMix User List</name>
-      <subscribe>[EMAIL PROTECTED]</subscribe>
-      <unsubscribe>[EMAIL PROTECTED]</unsubscribe>
-      <!--
-      <archive>http://archive.servicemix.codehaus.org/user/</archive>
-      -->
-      <archive>http://dir.gmane.org/gmane.comp.java.servicemix.user</archive>
-    </mailingList>
-    <mailingList>
-      <name>ServiceMix SCM List</name>
-      <subscribe>[EMAIL PROTECTED]</subscribe>
-      <unsubscribe>[EMAIL PROTECTED]</unsubscribe>
-      <archive>http://archive.servicemix.codehaus.org/scm/</archive>
-    </mailingList>
-  </mailingLists>
-
-
-  <versions>
-    <version>
-      <id>1.0-M1</id>
-      <name>1.0-M1</name>
-      <tag>SERVICEMIX_1_0_M1</tag>
-    </version>
-    <version>
-      <id>1.0-M2</id>
-      <name>1.0-M2</name>
-      <tag>SERVICEMIX_1_0_M2</tag>
-    </version>
-    <version>
-      <id>1.0</id>
-      <name>1.0</name>
-      <tag>SERVICEMIX_1_0</tag>
-    </version>
-    <version>
-      <id>1.0.1</id>
-      <name>1.0.1</name>
-      <tag>SERVICEMIX_1_0_1</tag>
-    </version>
-  </versions>
-  <branches>
-  </branches>
-
-  <developers>
-    <developer>
-      <name>Rob Davies</name>
-      <id>rajdavies</id>
-      <email>[EMAIL PROTECTED]</email>
-      <organization>Exist Labs</organization>
-    </developer>
-    <developer>
-      <name>James Strachan</name>
-      <id>jstrachan</id>
-      <email>[EMAIL PROTECTED]</email>
-      <organization>LogicBlaze</organization>
-    </developer>
-    <developer>
-      <name>Hiram Chirino</name>
-      <id>chirino</id>
-      <email>[EMAIL PROTECTED]</email>
-      <organization>LogicBlaze</organization>
-    </developer>
-    <developer>
-      <name>Dan Diephouse</name>
-      <id>dandiep</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-    <developer>
-      <name>Philip Dodds</name>
-      <id>pdodds</id>
-      <email>[EMAIL PROTECTED]</email>
-      <organization>Unity Systems</organization>
-    </developer>
-    <developer>
-      <name>Jonas Lim</name>
-      <id>jlim</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-    <developer>
-      <name>Fritz Oconer</name>
-      <id>foconer</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-    <developer>
-      <name>Joseph Gapuz</name>
-      <id>jgapuz</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-    <developer>
-      <name>Patrick Villacorta</name>
-      <id>pvillacorta</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-    <developer>
-      <name>Darwin Flores</name>
-      <id>dflores</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-    <developer>
-      <name>Merwin Yap</name>
-      <id>myap</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-    <developer>
-      <name>Guillaume Nodet</name>
-      <id>gnt</id>
-      <email>[EMAIL PROTECTED]</email>
-    </developer>
-  </developers>
-
-  <contributors>
-    <contributor>
-      <name>George Gastaldi</name>
-    </contributor>
-  </contributors>
-
-  <dependencies>
-  </dependencies>
-
-  <build>
-    <nagEmailAddress>[email protected]</nagEmailAddress>
-    <sourceDirectory>src/main/java</sourceDirectory>
-    <unitTestSourceDirectory>src/test/java</unitTestSourceDirectory>
-
-    <integrationUnitTestSourceDirectory/>
-    <aspectSourceDirectory/>
-
-    <unitTest>
-      <resources>
-        <resource>
-            <directory>src/test/resources</directory>
-          <includes>
-            <include>**/*.properties</include>
-            <include>**/*.xml</include>
-          </includes>
-        </resource>
-      </resources>
-      <includes>
-        <include>**/*Test.*</include>
-      </includes>
-      <excludes>
-        <!--  exclude abstract tests -->
-        <exclude>**/Abstract*Test.*</exclude>
-      </excludes>
-    </unitTest>
-
-    <resources>
-      <resource>
-          <directory>src/main/resources</directory>
-        <includes>
-          <include>**/*.properties</include>
-          <include>**/*.xml</include>
-        </includes>
-      </resource>
-    </resources>
-  </build>
-
-  <reports>
-    <report>maven-jdepend-plugin</report>
-    <report>maven-checkstyle-plugin</report>
-    <report>maven-simian-plugin</report>
-    <report>maven-faq-plugin</report>
-    <report>maven-changes-plugin</report>
-
-    <!-- clover seems to break the CI tool
-      <report>maven-cobertura-plugin</report>
-    -->
-    <report>maven-changelog-plugin</report>
-    <report>maven-file-activity-plugin</report>
-    <report>maven-developer-activity-plugin</report>
-    <report>maven-javadoc-plugin</report>
-    <report>maven-jxr-plugin</report>
-    <report>maven-junit-report-plugin</report>
-    <report>maven-tasklist-plugin</report>
-    <report>maven-pmd-plugin</report>
-
-  </reports>
-  
 </project>

Modified: branches/servicemix-2.0/trunk/tooling/servicemix-client/src/main/java/org/servicemix/client/DescriptorFactory.java (775 => 776)

--- branches/servicemix-2.0/trunk/tooling/servicemix-client/src/main/java/org/servicemix/client/DescriptorFactory.java	2005-11-10 00:45:16 UTC (rev 775)
+++ branches/servicemix-2.0/trunk/tooling/servicemix-client/src/main/java/org/servicemix/client/DescriptorFactory.java	2005-11-10 01:11:56 UTC (rev 776)
@@ -21,9 +21,12 @@
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
+import org.servicemix.jbi.config.spring.XBeanProcessor;
 import org.servicemix.jbi.deployment.Descriptor;
-import org.springframework.context.support.FileSystemXmlApplicationContext;
+import org.xbean.spring.context.FileSystemXmlApplicationContext;
 
+import java.util.Arrays;
+
 /**
  * 
  * Factory that be used to build a POJO representation of the JBI descriptor
@@ -47,25 +50,26 @@
 	 *            The root of the installation
 	 * @return The deployment descriptor
 	 */
-	public static Descriptor getDescriptor(String installRoot) {
-		Descriptor root = null;
-		File descriptor = new File(installRoot + META_INF, DESCRIPTOR_FILE);
-		log.debug("Checking for descriptor "+descriptor.getAbsolutePath());
-		if (descriptor.exists()) {
-			try {
-				FileSystemXmlApplicationContext context = new FileSystemXmlApplicationContext(
-						"file:///" + descriptor.getAbsolutePath());
-				root = (Descriptor) context.getBean("jbi");
-				log.debug("Parsed descriptor "+root);
-			} catch (Throwable e) {
-				throw new RuntimeException("Unable to parse the jbi.xml", e);
-			}
-		} else {
-			throw new RuntimeException("Descriptor file: " + descriptor
-					+ " doesn't exist");
-		}
-		return root;
-	}
+   public static Descriptor getDescriptor(String installRoot) {
+       Descriptor root = null;
+       File descriptor = new File(installRoot + META_INF, DESCRIPTOR_FILE);
+       log.debug("Checking for descriptor " + descriptor.getAbsolutePath());
+       if (descriptor.exists()) {
+           try {
+               Thread.currentThread().setContextClassLoader(Descriptor.class.getClassLoader());
+               FileSystemXmlApplicationContext context = new FileSystemXmlApplicationContext("file:///"
+                       + descriptor.getAbsolutePath(),
+                       Arrays.asList(new Object[] { new XBeanProcessor()}));
+               root = (Descriptor) context.getBean("jbi");
+               log.debug("Parsed descriptor " + root);
+           } catch (Throwable e) {
+               throw new RuntimeException("Unable to parse the jbi.xml", e);
+           }
+       } else {
+           throw new RuntimeException("Descriptor file: " + descriptor + " doesn't exist");
+       }
+       return root;
+   }
 
 	/**
 	 * Returns true if a JBI descriptor exists in this installation root

Reply via email to