[Design of JBoss ESB] - How to use FaultTo
by jaroslaw.kijanowski
Hi,
I've modified the exceptions_faults QS to verify the FaultTo element of a message works. I've added following lines of code to the causesException method in [1] , just before the ActionProcessingException is thrown.
[1] product/samples/quickstarts/exceptions_faults/src/org/jboss/soa/esb/samples/quickstart/exceptions/MyBasicAction.java
| PortReference pr = new PortReference();
| pr.setAddress("jms://localhost/queue/quickstart_FAULT_TO_Alert/");
| pr.addExtension("jbossesb:java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
| pr.addExtension("jbossesb:java.naming.provider.url", "localhost");
| pr.addExtension("jbossesb:specification-version", "1.1");
| pr.addExtension("jbossesb:connection-factory", "ConnectionFactory");
| pr.addExtension("jbossesb:message-selector", "serviceName='ExceptionCaughtService'");
| EPR epr = new EPR();
| epr.setAddr(pr);
| message.getHeader().getCall().setFaultTo(epr);
|
| throw new ActionProcessingException("BAD STUFF HAPPENED");
| }
|
I expected that an autgenerated (by the ESB) message was sent to the quickstart_FAULT_TO_Alert queue.
What I get is following warning in the ESB console:
16:39:36,343 INFO [STDOUT] &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
16:39:36,343 INFO [STDOUT] JustAnotherAction exceptionHandler:
Via Gateway |BASIC_ACTION| |JUST_ANOTHER_ACTION| |EXCEPTION_HANDLING|
16:39:36,343 INFO [STDOUT] &&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&
16:39:36,344 WARN [ActionProcessingPipeline] No fault address defined for fault message!
How do I define the fault address for the fault message if not via message.getHeader().getCall().setFaultTo(myEPR) ?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4077831#4077831
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4077831
18 years, 7 months
[Design of JBoss Build System] - Maven dependencies still not working properly.
by adrian@jboss.org
In the common project there is a jbossxb-builder project
http://anonsvn.jboss.org/repos/common/jbossxb-builder/trunk/
This specifies EXPLICITLY a dependency on jbossxb-2.0-snapshot,
but it is actually picking up jbossxb-2.0.0CR3 via dependency on jboss-container
| [DEBUG] Output directory: /home/ejort/common/jbossxb-builder/target/classes
| [DEBUG] Classpath:
| [DEBUG] /home/ejort/common/jbossxb-builder/target/classes
| [DEBUG] /home/ejort/.m2/repository/jboss/jboss-vfs/2.0.4.snapshot/jboss-vfs-2.0.4.snapshot.jar
|
| WRONG
|
| [DEBUG] /home/ejort/.m2/repository/jboss/jbossxb/2.0.0.CR3/jbossxb-2.0.0.CR3.jar
| [DEBUG] /home/ejort/.m2/repository/jboss/jboss-common-logging-spi/2.0.4.GA/jboss-common-logging-spi-2.0.4.GA.jar
| [DEBUG] /home/ejort/.m2/repository/sun-jaxb/jaxb-api/2.0.5/jaxb-api-2.0.5.jar
| [DEBUG] /home/ejort/.m2/repository/apache-xerces/xml-apis/2.7.1/xml-apis-2.7.1.jar
| [DEBUG] /home/ejort/.m2/repository/apache-slide/webdavlib/2.0/webdavlib-2.0.jar
|
| CORRECT BUT NOT USED
|
| [DEBUG] /home/ejort/.m2/repository/org/jboss/jbossxb/2.0.0-SNAPSHOT/jbossxb-2.0.0-SNAPSHOT.jar
|
This is causing it to fail to compile.
How do we fix this so it is not stupid?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4077818#4077818
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4077818
18 years, 7 months