Hello,
if someone needs a forward implementation (based on the servicemix3.0 impl.
for drools2) that works with servicemix3.1 and drools3, here is an
implementation that works for us.
Just put it in a subclass of org.apache.servicemix.drools.model.JbiHelper
public void forward(String globalpart, String localpart) throws
MessagingException {
QName service = new QName(globalpart, localpart);
DeliveryChannel channel = getChannel();
MessageExchangeFactory factory =
channel.createExchangeFactoryForService(service);
InOnly outExchange = factory.createInOnlyExchange();
String processCorrelationId =
(String)
getExchange().getProperty(JbiConstants.CORRELATION_ID);
if (processCorrelationId != null) {
outExchange.setProperty(JbiConstants.CORRELATION_ID,
processCorrelationId);
}
NormalizedMessage out = outExchange.createMessage();
outExchange.setInMessage(out);
CopyTransformer.getInstance().transform(getExchange().getInternalExchange(),
getExchange().getIn().getInternalMessage(), out);
getChannel().send(outExchange);
}
--
View this message in context:
http://www.nabble.com/servicemix-3.1---migration-from-drools2---%3E-drools---how-to-forward--tf3122041s12049.html#a9154974
Sent from the ServiceMix - User mailing list archive at Nabble.com.