| Commit in servicemix/base on MAIN | |||
| maven.xml | +18 | 1.10 -> 1.11 | |
| project.xml | +115 | -85 | 1.93 -> 1.94 |
| src/main/java/org/servicemix/jbi/container/ActivationSpec.java | +4 | -1 | 1.14 -> 1.15 |
| /SubscriptionSpec.java | +36 | -32 | 1.5 -> 1.6 |
| /SpringJBIContainer.java | +4 | -1 | 1.19 -> 1.20 |
| +177 | -119 | ||
Added support for XBean Spring to eventually replace the Spring XML configuration mechanism
servicemix/base
diff -u -r1.10 -r1.11 --- maven.xml 24 Aug 2005 12:21:12 -0000 1.10 +++ maven.xml 10 Oct 2005 12:59:33 -0000 1.11 @@ -7,6 +7,10 @@
<goal name="default" prereqs="clean, jar:install, dist:build-bin, dist:build-src"/>
+ <postGoal name="java:compile"> + <attainGoal name="xbean:generate" /> + </postGoal> +
<goal name="dc">
<attain>
<attainGoal name="clean"/>
@@ -30,7 +34,21 @@
<path refid="maven.dependency.classpath"/>
</path>
</goal>
+
+ <goal name="xbean:generate" description="Generates the XBean XSD, documentation and META-INF/services files.">
+ <path id="test.classpath">
+ <pathelement path="${maven.build.dest}" />
+ <pathelement path="target/classes" />
+ <pathelement path="target/test-classes" />
+ <path refid="maven.dependency.classpath" />
+ </path>
+ <taskdef name="xsdGenerate" classname="org.xbean.spring.task.SchemaGenerateTask"> + <classpath refid="test.classpath" /> + </taskdef> + <xsdGenerate destFile="target/servicemix.xsd" namespace="http://servicemix.org/config/1.0" + classpathref="test.classpath" srcdir="src/main/java" metaInfDir="target/generated/"/> + </goal>
<goal
name="dist:prepare-bin-filesystem"
servicemix/base
diff -u -r1.93 -r1.94 --- project.xml 10 Oct 2005 10:20:33 -0000 1.93 +++ project.xml 10 Oct 2005 12:59:33 -0000 1.94 @@ -9,7 +9,9 @@
<organization>
<name>ServiceMix.</name>
<url>http://www.servicemix.co.com</url>
- <logo>http://www.logicblaze.com/images/logos/products/ServiceMix/ServiceMix_logo_150.jpg</logo>
+ <logo> + http://www.logicblaze.com/images/logos/products/ServiceMix/ServiceMix_logo_150.jpg + </logo>
</organization> <logo></logo>
@@ -62,33 +64,39 @@
</packageGroup> </packageGroups>
- <shortDescription> - ServiceMix is an open source ESB - </shortDescription>
+ <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
+ ServiceMix is an open source ESB based on the Java Business + Integration framework - JSR-208
</description> <url>http://servicemix.codehaus.org/</url>
- <issueTrackingUrl>http://jira.codehaus.org/browse/SM</issueTrackingUrl>
+ <issueTrackingUrl> + http://jira.codehaus.org/browse/SM + </issueTrackingUrl>
<siteAddress>beaver.codehaus.org</siteAddress>
- <siteDirectory>/home/projects/servicemix/public_html/maven</siteDirectory> - <distributionDirectory>/home/projects/servicemix/dist</distributionDirectory>
+ <siteDirectory> + /home/projects/servicemix/public_html/maven + </siteDirectory> + <distributionDirectory> + /home/projects/servicemix/dist + </distributionDirectory>
<repository>
<connection>
- scm:cvs:pserver:[EMAIL PROTECTED]:/home/projects/servicemix/scm:servicemix</connection>
+ scm:cvs:pserver:[EMAIL PROTECTED]:/home/projects/servicemix/scm:servicemix + </connection>
<developerConnection>
- scm:cvs:ext:[EMAIL PROTECTED]:/home/projects/servicemix/scm:servicemix</developerConnection>
+ scm:cvs:ext:[EMAIL PROTECTED]:/home/projects/servicemix/scm:servicemix + </developerConnection>
<url>http://cvs.servicemix.codehaus.org/servicemix/</url> </repository>
- <mailingLists> - </mailingLists>
+ <mailingLists></mailingLists>
<versions>
@@ -145,41 +153,40 @@
<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>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>
</developers>
- <contributors> - </contributors>
+ <contributors></contributors>
<dependencies>
@@ -294,21 +301,21 @@
<!-- To use XPath using JAXP 1.3 (std in Java 5) -->
<!--
- <dependency>
+ <dependency>
<groupId>servicemix</groupId>
<artifactId>jaxp</artifactId>
<version>1.4-20050623</version>
- </dependency> - <dependency>
+ </dependency> + <dependency>
<groupId>servicemix</groupId>
<artifactId>jaxp-xercesImpl</artifactId>
<version>1.4-20050623</version>
- </dependency> - <dependency>
+ </dependency> + <dependency>
<groupId>servicemix</groupId>
<artifactId>jaxp-xalan</artifactId>
<version>1.4-20050623</version>
- </dependency>
+ </dependency>
-->
<dependency>
@@ -321,17 +328,17 @@
</dependency>
<!--
- <dependency>
+ <dependency>
<groupId>servicemix</groupId>
<artifactId>jaxp-xercesImpl</artifactId>
<version>1.3</version>
- </dependency> - <dependency>
+ </dependency> + <dependency>
<groupId>servicemix</groupId>
<artifactId>jaxp-xalan</artifactId>
<version>1.3</version>
- </dependency> -
+ </dependency> +
-->
<dependency>
@@ -368,13 +375,13 @@
<!-- reference implementation -->
<!--
- <dependency>
+ <dependency>
<id>stax</id>
<version>1.1.1-dev</version>
<properties>
- <lib>true</lib>
+ <lib>true</lib>
</properties>
- </dependency>
+ </dependency>
-->
<!-- possible StAX implementations: END -->
@@ -409,11 +416,11 @@
<!-- for spring integration -->
<!-- use our patched version for now
- <dependency>
+ <dependency>
<groupId>springframework</groupId>
<artifactId>spring</artifactId>
<version>1.2</version>
- </dependency>
+ </dependency>
-->
<dependency>
<groupId>servicemix</groupId>
@@ -437,7 +444,7 @@
<!--
- || Optional Components
+ || Optional Components
-->
<!-- http binding -->
@@ -618,6 +625,22 @@
</dependency>
+ <!-- for custom XML parsing --> + <dependency> + <groupId>xbean</groupId> + <artifactId>xbean-spring</artifactId> + <version>1.0-SNAPSHOT</version> + <url>http://www.gbean.org</url> + <properties> + <war.bundle>true</war.bundle> + </properties> + </dependency> + <dependency> + <groupId>annogen</groupId> + <artifactId>annogen</artifactId> + <version>0.1.0</version> + </dependency> +
<!-- JCA container and transaction manaqer -->
<dependency>
<id>jencks+all</id>
@@ -630,32 +653,32 @@
<!-- default JMS provider used for implementation -->
-
+
<!-- for ActiveMQ 4.x -->
<!--
- <dependency>
+ <dependency>
<id>activemq+core</id>
<version>4.0-SNAPSHOT</version>
<properties>
- <lib>true</lib>
+ <lib>true</lib>
</properties>
- </dependency> - <dependency>
+ </dependency> + <dependency>
<id>activemq+ra</id>
<version>4.0-SNAPSHOT</version>
<properties>
- <lib>true</lib>
+ <lib>true</lib>
</properties>
- </dependency> - <dependency>
+ </dependency> + <dependency>
<id>activeio</id>
<version>2.0-SNAPSHOT</version>
<properties>
- <lib>true</lib>
+ <lib>true</lib>
</properties>
- </dependency>
+ </dependency>
-->
-
+
<!-- for ActiveMQ 3.x -->
<dependency>
<id>activemq</id>
@@ -727,14 +750,14 @@
</properties>
</dependency>
<!--
- <dependency>
+ <dependency>
<groupId>xmlbeans</groupId>
<artifactId>xmlpublic</artifactId>
<version>2.0.0-beta1</version>
<properties>
- <optional>true</optional>
+ <optional>true</optional>
</properties>
- </dependency>
+ </dependency>
-->
<dependency>
<groupId>xmlbeans</groupId>
@@ -872,7 +895,7 @@
</dependency>
<!--
- || Dependencies for running test cases
+ || Dependencies for running test cases
-->
<!-- for pooling JMS and other resources -->
@@ -984,8 +1007,8 @@
<sourceDirectory>src/main/java</sourceDirectory>
<unitTestSourceDirectory>src/test/java</unitTestSourceDirectory>
- <integrationUnitTestSourceDirectory/> - <aspectSourceDirectory/>
+ <integrationUnitTestSourceDirectory /> + <aspectSourceDirectory />
<unitTest>
<resources>
@@ -1013,14 +1036,21 @@
<include>**/*.zip</include>
</includes>
</resource>
+ <resource> + <directory>target/generated</directory> + <includes> + <include>**/*</include> + </includes> + <filtering>false</filtering> + </resource>
</resources>
<includes>
<include>**/*Test.*</include>
</includes>
<excludes>
- <!-- exclude abstract tests --> - <exclude>**/Abstract*Test.*</exclude> -
+ <!-- exclude abstract tests --> + <exclude>**/Abstract*Test.*</exclude> +
<exclude>**/ScriptTest.*</exclude>
<exclude>**/ReflectionBindingTest.*</exclude>
@@ -1074,14 +1104,14 @@
<reports>
<report>maven-jdepend-plugin</report>
<!-- re-enable when we can get the warnings down to less than a few Mb!
- <report>maven-checkstyle-plugin</report> - <report>maven-simian-plugin</report> - <report>maven-faq-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-clover-plugin</report>
+ <report>maven-clover-plugin</report>
-->
<report>maven-changelog-plugin</report>
<report>maven-file-activity-plugin</report>
servicemix/base/src/main/java/org/servicemix/jbi/container
diff -u -r1.14 -r1.15 --- ActivationSpec.java 6 Oct 2005 12:05:50 -0000 1.14 +++ ActivationSpec.java 10 Oct 2005 12:59:33 -0000 1.15 @@ -31,7 +31,10 @@
/** * Represents the registration of a component with the [EMAIL PROTECTED] JBIContainer} *
- * @version $Revision: 1.14 $
+ * @org.xbean.XBean element="component" + * description="The Component configuration consisting of its container related properties such as its routing information" + * + * @version $Revision: 1.15 $
*/
public class ActivationSpec implements Serializable {
servicemix/base/src/main/java/org/servicemix/jbi/container
diff -u -r1.5 -r1.6 --- SubscriptionSpec.java 5 Oct 2005 08:44:52 -0000 1.5 +++ SubscriptionSpec.java 10 Oct 2005 12:59:33 -0000 1.6 @@ -33,14 +33,14 @@
/** * Represents a subscription to a JBI endpoint. *
+ * @org.xbean.XBean + *
* @version $Revision$
*/
public class SubscriptionSpec implements Serializable {
- /** - * - */
private static final long serialVersionUID = 8458586342841647313L;
+
private QName service;
private QName interfaceName;
private QName operation;
@@ -87,56 +87,61 @@
public void setService(QName service) {
this.service = service;
}
-
+
/**
* @return Returns the name.
*/
- public ComponentNameSpace getName(){
+ public ComponentNameSpace getName() {
return name;
}
/**
- * @param name The name to set.
+ * @org.xbean.XBean hide="true" + * + * @param name + * The name to set.
*/
- public void setName(ComponentNameSpace name){
- this.name=name;
+ public void setName(ComponentNameSpace name) {
+ this.name = name;
}
/**
* Returns true if this subscription matches the given message exchange
*
- * @param exchange the exchange to be matched
+ * @param exchange + * the exchange to be matched
* @return true if this subscription matches the exchange
*/
- public boolean matches(Registry registry,MessageExchangeImpl exchange){
+ public boolean matches(Registry registry, MessageExchangeImpl exchange) {
boolean result = false;
- if(filter != null){
+ if (filter != null) {
result = filter.matches(exchange);
- }else{
+ }
+ else {
ExchangePacket packet = exchange.getPacket();
ComponentNameSpace sourceId = packet.getSourceId();
- if(sourceId != null){
+ if (sourceId != null) {
// get the list of services
- if(service != null){
+ if (service != null) {
ServiceEndpoint[] ses = registry.getEndpointsForService(service);
- if(ses != null){
- for(int i = 0;i < ses.length;i++){
+ if (ses != null) {
+ for (int i = 0; i < ses.length; i++) {
ServiceEndpointImpl se = (ServiceEndpointImpl) ses[i];
- if(se.getComponentNameSpace() != null && se.getComponentNameSpace().equals(sourceId)){
+ if (se.getComponentNameSpace() != null && se.getComponentNameSpace().equals(sourceId)) {
result = true;
break;
}
}
}
}
- if(result && interfaceName != null){
+ if (result && interfaceName != null) {
ServiceEndpoint[] ses = registry.getEndpoints(interfaceName);
- if(ses != null){
+ if (ses != null) {
result = false;
- for(int i = 0;i < ses.length;i++){
+ for (int i = 0; i < ses.length; i++) {
ServiceEndpointImpl se = (ServiceEndpointImpl) ses[i];
- if(se.getComponentNameSpace() != null && se.getComponentNameSpace().equals(sourceId)){
+ if (se.getComponentNameSpace() != null && se.getComponentNameSpace().equals(sourceId)) {
result = true;
break;
}
@@ -149,16 +154,16 @@
}
return result;
}
-
+
/**
* @see java.lang.Object#equals(java.lang.Object)
*/
- public boolean equals(Object obj){
+ public boolean equals(Object obj) {
boolean result = false;
- if(obj instanceof SubscriptionSpec){
+ if (obj instanceof SubscriptionSpec) {
SubscriptionSpec other = (SubscriptionSpec) obj;
- result = (name == null && other.name == null || name.equals(other.name)) && - (service == null && other.service == null)
+ result = (name == null && other.name == null || name.equals(other.name)) + && (service == null && other.service == null)
|| (service != null && other.service != null && service.equals(other.service))
&& (interfaceName == null && other.interfaceName == null)
|| (interfaceName != null && other.interfaceName != null && interfaceName
@@ -168,15 +173,14 @@
}
return result;
}
-
+
/**
* @see java.lang.Object#hashCode()
*/
- public int hashCode(){
- return (name!=null?name.hashCode():0)
- ^(service!=null?service.hashCode():(interfaceName!=null?interfaceName.hashCode():super
- .hashCode()));
+ public int hashCode() {
+ return (name != null ? name.hashCode() : 0)
+ ^ (service != null ? service.hashCode() : (interfaceName != null ? interfaceName.hashCode() : super
+ .hashCode()));
}
-
}
servicemix/base/src/main/java/org/servicemix/jbi/container
diff -u -r1.19 -r1.20 --- SpringJBIContainer.java 3 Oct 2005 20:56:34 -0000 1.19 +++ SpringJBIContainer.java 10 Oct 2005 12:59:33 -0000 1.20 @@ -25,7 +25,10 @@
* An enhanced JBI container which adds some Spring helper methods for * easier configuration through spring's XML configuration file. *
- * @version $Revision: 1.19 $
+ * @org.xbean.XBean element="container" rootElement="true" + * description="The ServiceMix JBI Container" + * + * @version $Revision: 1.20 $
*/
public class SpringJBIContainer extends JBIContainer
implements InitializingBean, BeanFactoryAware, ApplicationContextAware {
