Fixed exception handling bug in FlowMessageHandler
This commit is contained in:
2
pom.xml
2
pom.xml
@@ -22,7 +22,7 @@
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF8</project.build.sourceEncoding>
|
||||
<spring.framework.version>3.1.0.M2</spring.framework.version>
|
||||
<spring.integration.version>2.1.0.BUILD-SNAPSHOT</spring.integration.version>
|
||||
<spring.integration.version>2.1.0.M2</spring.integration.version>
|
||||
<maven.test.search.classdir>true</maven.test.search.classdir>
|
||||
</properties>
|
||||
|
||||
|
||||
@@ -17,11 +17,9 @@ import java.io.File;
|
||||
import java.io.FileNotFoundException;
|
||||
import java.io.FileReader;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
|
||||
import org.springframework.beans.factory.config.BeanDefinition;
|
||||
@@ -32,7 +30,6 @@ import org.springframework.integration.MessageChannel;
|
||||
import org.springframework.integration.core.SubscribableChannel;
|
||||
import org.springframework.integration.handler.BridgeHandler;
|
||||
import org.springframework.util.ResourceUtils;
|
||||
import org.springframework.util.StringUtils;
|
||||
|
||||
/**
|
||||
* Utility functions used by the flow parsers
|
||||
@@ -128,10 +125,11 @@ public class FlowUtils {
|
||||
int index = 0;
|
||||
for (String dependency : dependencies) {
|
||||
if (!dependency.equals(beans[i])) {
|
||||
|
||||
|
||||
depsArray[index++] = dependency;
|
||||
} else {
|
||||
System.out.println(indent(level+1) + beans[i]);
|
||||
}
|
||||
else {
|
||||
System.out.println(indent(level + 1) + beans[i]);
|
||||
}
|
||||
}
|
||||
if (depsArray.length > 0) {
|
||||
|
||||
@@ -110,9 +110,10 @@ public class FlowMessageHandler extends AbstractReplyProducingMessageHandler {
|
||||
errorChannel.send(new ErrorMessage(me, Collections.singletonMap(
|
||||
FlowConstants.FLOW_OUTPUT_PORT_HEADER,
|
||||
(Object) FlowConstants.FLOW_HANDLER_EXCEPTION_HEADER_VALUE)));
|
||||
} else {
|
||||
throw me;
|
||||
|
||||
}
|
||||
} else {
|
||||
throw me;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user