protected void forwardToExchange(MessageExchange exchange, InOnly outExchange, NormalizedMessage in, QName operationName) throws MessagingException { if (operationName != null) { exchange.setOperation(operationName); } forwardToExchange(exchange, outExchange, in); }
protected void forwardToExchange(MessageExchange exchange, InOnly outExchange, NormalizedMessage in, QName operationName) throws MessagingException { if (operationName != null) { exchange.setOperation(operationName); } forwardToExchange(exchange, outExchange, in); }
String[] parts = URIResolver.split3(uri2); exchange.setInterfaceName(new QName(parts[0], parts[1])); exchange.setOperation(new QName(parts[0], parts[2])); } else if (uri.startsWith("service:")) { String uri2 = uri.substring(8);
String[] parts = URIResolver.split3(uri2); exchange.setInterfaceName(new QName(parts[0], parts[1])); exchange.setOperation(new QName(parts[0], parts[2])); } else if (uri.startsWith("service:")) { String uri2 = uri.substring(8);
String[] parts = URIResolver.split3(uri2); exchange.setInterfaceName(new QName(parts[0], parts[1])); exchange.setOperation(new QName(parts[0], parts[2])); } else if (uri.startsWith("service:")) { String uri2 = uri.substring(8);
String[] parts = URIResolver.split3(value); MessageExchange exchange = message.getContent(MessageExchange.class); exchange.setOperation(new QName(parts[0], parts[2])); exchange.setInterfaceName(new QName(parts[0], parts[1]));
.getParts().get(0).getElementQName().equals(opeName)) { boi = op; exchange.setOperation(new QName(boi.getName().getNamespaceURI(), opeName.getLocalPart())); break;
exchange.setOperation(operationName);
private MessageExchange prepareMessageExchange(Exchange exchange) throws MessagingException, URISyntaxException { MessageExchange messageExchange = binding.makeJbiMessageExchange(exchange, getExchangeFactory(), jbiEndpoint.getMep()); if (jbiEndpoint.getOperation() != null) { messageExchange.setOperation(jbiEndpoint.getOperation()); } URIResolver.configureExchange(messageExchange, getContext(), jbiEndpoint.getDestinationUri()); return messageExchange; }
/** * Configures the target on the newly created exchange * @param exchange the exchange to configure * @throws MessagingException if the target could not be configured */ public void configureTarget(MessageExchange exchange, ComponentContext context) throws MessagingException { if (interf == null && service == null && uri == null) { throw new MessagingException("interface, service or uri should be specified"); } if (uri != null) { URIResolver.configureExchange(exchange, context, uri); } if (interf != null) { exchange.setInterfaceName(interf); } if (operation != null) { exchange.setOperation(operation); } if (service != null) { exchange.setService(service); if (endpoint != null) { ServiceEndpoint se = context.getEndpoint(service, endpoint); exchange.setEndpoint(se); } } }
/** * Configures the target on the newly created exchange * @param exchange the exchange to configure * @throws MessagingException if the target could not be configured */ public void configureTarget(MessageExchange exchange, ComponentContext context) throws MessagingException { if (interf == null && service == null && uri == null) { throw new MessagingException("interface, service or uri should be specified"); } if (uri != null) { URIResolver.configureExchange(exchange, context, uri); } if (interf != null) { exchange.setInterfaceName(interf); } if (operation != null) { exchange.setOperation(operation); } if (service != null) { exchange.setService(service); if (endpoint != null) { ServiceEndpoint se = context.getEndpoint(service, endpoint); exchange.setEndpoint(se); } } }
protected void configureExchangeTarget(MessageExchange exchange) { if (targetUri != null) { URIResolver.configureExchange(exchange, getContext(), targetUri); } if (exchange.getInterfaceName() == null && targetInterface != null) { exchange.setInterfaceName(targetInterface); } if (exchange.getOperation() == null && targetOperation != null) { exchange.setOperation(targetOperation); } if (exchange.getService() == null && targetService != null) { exchange.setService(targetService); if (targetEndpoint != null) { ServiceEndpoint se = getContext().getEndpoint(targetService, targetEndpoint); if (se != null) { exchange.setEndpoint(se); } else { logger.warn("Target service (" + targetService + ") and endpoint (" + targetEndpoint + ")" + " specified, but no matching endpoint found. Only the service will be used for routing."); } } } }
/** * Configures the target on the newly created exchange * @param exchange the exchange to configure * @throws MessagingException if the target could not be configured */ public void configureTarget(MessageExchange exchange, ComponentContext context) throws MessagingException { if (interf == null && service == null && uri == null) { throw new MessagingException("interface, service or uri should be specified"); } if (uri != null) { URIResolver.configureExchange(exchange, context, uri); } if (interf != null) { exchange.setInterfaceName(interf); } if (operation != null) { exchange.setOperation(operation); } if (service != null) { exchange.setService(service); if (endpoint != null) { ServiceEndpoint se = context.getEndpoint(service, endpoint); exchange.setEndpoint(se); } } }
protected MessageExchange createJbiMessageExchange(Exchange camelExchange, MessageExchangeFactory exchangeFactory, String defaultMep) throws MessagingException, URISyntaxException { // option 1 -- use the MEP that was configured on the endpoint URI ExchangePattern mep = ExchangePattern.fromWsdlUri(defaultMep); if (mep == null) { // option 2 -- use the MEP from the Camel Exchange mep = camelExchange.getPattern(); } MessageExchange answer = null; if (mep != null) { if (mep == ExchangePattern.InOnly) { answer = exchangeFactory.createInOnlyExchange(); } else if (mep == ExchangePattern.InOptionalOut) { answer = exchangeFactory.createInOptionalOutExchange(); } else if (mep == ExchangePattern.InOut) { answer = exchangeFactory.createInOutExchange(); } else if (mep == ExchangePattern.RobustInOnly) { answer = exchangeFactory.createRobustInOnlyExchange(); } else { answer = exchangeFactory.createExchange(new URI(mep.toString())); } } if (getOperation(camelExchange) != null) { answer.setOperation(getOperation(camelExchange)); } return answer; }
/** * Configures the target on the newly created exchange * @param exchange the exchange to configure * @throws MessagingException if the target could not be configured */ public void configureTarget(MessageExchange exchange) throws MessagingException { if (targetInterface == null && targetService == null && targetUri == null) { throw new MessagingException("target's interface, service or uri should be specified"); } if (targetUri != null) { URIResolver.configureExchange(exchange, getContext(), targetUri); } if (targetInterface != null) { exchange.setInterfaceName(targetInterface); } if (targetOperation != null) { exchange.setOperation(targetOperation); } if (targetService != null) { exchange.setService(targetService); if (targetEndpoint != null) { ServiceEndpoint se = getContext().getEndpoint(targetService, targetEndpoint); exchange.setEndpoint(se); } } }
me.setOperation(operation.getName()); return me;
me.setEndpoint(endpoint); if (operation != null) { me.setOperation(QNameUtil.parse(operation));
exchange.setOperation(opeName); } else { NormalizedMessage nm = exchange.getMessage("in"); exchange.setOperation(opeName);
exchange = createExchange(message); if (operation != null) { exchange.setOperation(operation.getName());
target.configureTarget(tme, getContext()); if (isForwardOperation() && tme.getOperation() == null) { tme.setOperation(exchange.getOperation());